Prepare specs for no-url-suffix lint rule#43818
Conversation
Next Steps to MergeNext steps that must be taken to merge this PR:
Comment generated by summarize-checks workflow run. |
|
The Swagger Avocado failures are pre-existing
Our PR only modifies |
There was a problem hiding this comment.
I don't think this PR should be doing anything else but adding suppresions. This service for example doesn't define client emitter in its tspconfig so its probably not generating SDK we shouldn't have to apply those rules(why the separate ruleset)
There was a problem hiding this comment.
all violations are handled by #suppress now and no client.tsp is added by this PR. The errors in TSV check are caused by override-parameters-mismatch , not related to this PR.
There was a problem hiding this comment.
i think this just means you haven't pulled in the changes from main in the typespec-azure pr because I believe @tadelesh fixed those issues
There was a problem hiding this comment.
but at this point as this needs to be opt-int until we have the tsv enforcement this pr is not blocking the typespec-azure one from being merged, you'll just need to make sure the final one is green when upgrading the version to what is published
There was a problem hiding this comment.
I rebased the rule PR and repinned the latest build from the rule PR. TSV check still fails. It probably because the spec fix is still on typespec-next not yet synced to main yet.
There was a problem hiding this comment.
all TSV checks all pass now
Add #suppress directives and @@clientName URL-to-Uri customizations across affected TypeSpec specs in preparation for the no-url-suffix lint rule. Squashed rebase of PR #43818 onto latest main; resolved the liftrmongodb client.tsp conflict by keeping both the Project/Cluster renames from main and the redirectUrl->redirectUri rename. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Each flagged property had the identical #suppress line written twice. Collapse the 32 exact-duplicate suppressions (across 16 files) to a single suppression per property. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
6 properties (botservice x4, cost-management x2) had csharp-no-url-suffix suppressed twice with a pre-existing casing-style suppress between the two, so they were non-adjacent and missed by the first dedup pass. Collapse to a single csharp-no-url-suffix suppression per property. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…ecs, drop suppressions elsewhere Step 2 of the no-url-suffix rollout. The csharp-no-url-suffix rule now lives in the new client-sdk ruleset (typespec-azure #4541), so: (1) add the client-sdk ruleset to linter.extends in all 349 tspconfigs configured to emit a client SDK, (2) remove the 60 now-dead suppressions from 25 non-client projects, (3) refresh the @4541 lockfile pin to build .1516 which contains the moved rule. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The @4541 pkg.pr.new moving tag repacks with a new hash on each fetch, so npm ci fails with EINTEGRITY (lockfile integrity != freshly downloaded tarball). Pin both @azure-tools/typespec-azure-rulesets and @azure-tools/typespec-client-generator-core to the immutable commit-specific URL @97378df6, which serves a byte-stable tarball. Integrity values are unchanged (they already match the commit artifact). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…ents; fix cloudhealth tspconfig format Step 2 removed csharp-no-url-suffix suppressions from sub-projects whose own tspconfig is non-client, but whose models are compiled by a client-SDK parent (applicationinsights, compute/Compute, monitor/Insights, network/Network). With client-sdk added to those parents, the rule fired on the now-unsuppressed *Url properties (50 TSV errors). Restore the 25 suppressions in the 7 shared model files. Also convert cloudhealth linter.extends from inline array to block list (prettier/tsv Format rule). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…e fix) Repin to the immutable commit URL @30de6998 (build 0.70.0-pr-4541.1525), which includes tadelesh's #4730 @OverRide regression fix. With #4730, the override-parameters-mismatch errors drop to 37 (the genuine 'override param dropped @path' cases across 11 projects); the false-positive regressions are fixed. Demonstrates #4730 reduces but does not fully clear the override errors without spec-side @path additions. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…ew pin) Now that @azure-tools/typespec-client-generator-core, typespec-azure-rulesets, and typespec-azure-resource-manager 0.69.2 are published (with the client-sdk ruleset and the #4730 override fix), switch off the pkg.pr.new build pins. Also drop the legacy-peer-deps=true .npmrc workaround since 0.69.2 peers resolve cleanly. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
/azp run |
|
You have several pipelines (over 10) configured to build pull requests in this repository. Specify which pipelines you would like to run by using /azp run [pipelines] command. You can specify multiple pipelines using a comma separated list. |
|
/azp run SDK Validation - .NET, SDK Validation - Go, SDK Validation - JS, SDK Validation - Java, SDK Validation - Python, SDK Validation - Rust |
|
Azure Pipelines successfully started running 6 pipeline(s). |
…masked by 0.69.2 Revert typespec-azure-resource-manager to 0.69.1 (keep tcgc + rulesets at 0.69.2). resource-manager 0.69.2 changes CommonTypes emission (external \ -> inlined definitions), which regenerates swagger for RM projects (e.g. devcenter, maps) and is unrelated to the url-suffix rule. The rulesets 0.69.2 peer on resource-manager ^0.69.2 is only an npm warning. Add csharp-no-url-suffix suppressions for 11 properties in cognitiveservices, policyinsights, and security. These were previously hidden because those projects had compile-blocking override-parameters-mismatch errors; 0.69.2's override fix unmasked them. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
npm ci uses strict peer resolution and errored with ERESOLVE because typespec-azure-rulesets@0.69.2 has a peer of resource-manager@^0.69.2 while we deliberately keep resource-manager at 0.69.1 (to avoid CommonTypes swagger regeneration). A surgical overrides entry satisfies the peer without adding legacy-peer-deps to .npmrc. The resolved tree is unchanged (rm stays 0.69.1), so package-lock.json needs no update. Verified pm ci no longer ERESOLVEs. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
The required SDK Validation check fails with |
|
@timotheeguerin As yuchao pointed out in his tcgc version bump PR Azure/azure-sdk-for-python#47811, we need to wait 6 days to satisfy the new 7 days law for new npm package. |
| "superagent": "^10.2.3" | ||
| "superagent": "^10.2.3", | ||
| "@azure-tools/typespec-azure-rulesets": { | ||
| "@azure-tools/typespec-azure-resource-manager": "0.69.1" |
There was a problem hiding this comment.
What happened here? Why are we overriding this?
Summary
Prepares existing TypeSpec specs for Azure/typespec-azure#4541 (
@azure-tools/typespec-client-generator-core/no-url-suffix).@@clientName(..., "...Uri", "csharp")customizations in new minimalclient.tspfiles where doing so does not pull in existing client customizations.#suppressdirectives where aclientNamefix is not safe or not expressible, such as OAuth metadata fields, inline/aliased properties, or projects with existingclient.tspfiles whose import would apply unrelated SDK customizations.Validation
npx tsp compile . --no-emitfor all 154 affected TypeSpec projectsnpx tsp compile .for the 25 projects with new minimalclient.tspimportsgit diff --check -- specificationRelated to Azure/typespec-azure#4541.