Skip to content

Reject JavaScript and TypeScript files in service folders - #47826

Merged
Timothee Guerin (timotheeguerin) merged 5 commits into
mainfrom
timotheeguerin/block-specification-scripts
Nov 3, 2026
Merged

Timothee Guerin (timotheeguerin) merged 5 commits into
mainfrom
timotheeguerin/block-specification-scripts

Conversation

@timotheeguerin

@timotheeguerin Timothee Guerin (timotheeguerin) commented Nov 2, 2026 •

Copy link
Copy Markdown
Member

Service folders should contain API descriptions, not JavaScript or TypeScript implementations. For example, #47311 includes specification/webpubsub/data-plane/WebPubSubChat/client-customizations.mjs, which should fail TypeSpec Validation.

Add a normal TSV DisallowedFileTypes rule that recursively scans specification/<service>/, including shared files, sibling projects, and hidden files. It checks the current filesystem in single-project, --all, and --changed validation, without comparing Git revisions. Installed node_modules and .git directories are excluded. The initial extension denylist covers JavaScript and TypeScript variants and can be extended to other file types later.

Exact-file suppressions in specification/suppressions.yaml grandfather the five existing .mjs files: the Foundry voice-event emitter and its test, plus three Cognitive Services contract tests. New scripts in those services still fail; there are no blanket service exemptions. These exceptions can be removed as the existing tooling is relocated.

@github-actions

github-actions Bot commented Nov 2, 2026 •

Copy link
Copy Markdown

Next Steps to Merge

✅ All automated merging requirements have been met! To get your PR merged, see aka.ms/azsdk/specreview/merge.

Comment generated by summarize-checks workflow run.

@timotheeguerin Timothee Guerin (timotheeguerin) changed the title Block JavaScript and TypeScript additions under specification Reject JavaScript and TypeScript files in service folders Nov 2, 2026
@timotheeguerin
Timothee Guerin (timotheeguerin) marked this pull request as ready for review November 3, 2026 13:36
@timotheeguerin
Timothee Guerin (timotheeguerin) merged commit 98f1e43 into main Nov 3, 2026
78 of 79 checks passed
@timotheeguerin
Timothee Guerin (timotheeguerin) deleted the timotheeguerin/block-specification-scripts branch November 3, 2026 13:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant