From 62eda91e0d0cae497713bc407dcce09dbf041a3b Mon Sep 17 00:00:00 2001 From: Daniel Jurek Date: Thu, 5 Aug 2021 22:51:01 -0700 Subject: [PATCH 01/12] Make public API spell checking opt-out, opt out services which have errors --- .vscode/cspell.json | 3 ++- eng/pipelines/templates/jobs/ci.yml | 2 +- eng/pipelines/templates/stages/archetype-sdk-client.yml | 2 +- sdk/agrifood/ci.yml | 1 + sdk/communication/ci.yml | 1 + sdk/compute/ci.yml | 1 + sdk/containerregistry/ci.yml | 1 + sdk/cosmosdb/ci.yml | 1 + sdk/digitaltwins/ci.yml | 1 + sdk/dns/ci.yml | 1 + sdk/eventgrid/ci.yml | 1 + sdk/eventhub/ci.yml | 1 + sdk/identity/ci.yml | 1 + sdk/insights/ci.yml | 1 + sdk/machinelearningservices/ci.yml | 1 + sdk/modelsrepository/ci.yml | 1 + sdk/monitor/ci.yml | 1 + sdk/network/ci.yml | 1 + sdk/objectanchors/ci.yml | 1 + sdk/personalizer/ci.yml | 1 + sdk/purview/ci.yml | 1 + sdk/remoterendering/ci.yml | 1 + sdk/sqlmanagement/ci.yml | 1 + sdk/synapse/ci.yml | 1 + sdk/videoanalyzer/ci.yml | 1 + 25 files changed, 26 insertions(+), 3 deletions(-) diff --git a/.vscode/cspell.json b/.vscode/cspell.json index e275304761f30..6944f84da5128 100644 --- a/.vscode/cspell.json +++ b/.vscode/cspell.json @@ -63,7 +63,8 @@ "unhold", "uninstrumented", "westus", - "xunit" + "xunit", + "vnet" ], "overrides": [ { diff --git a/eng/pipelines/templates/jobs/ci.yml b/eng/pipelines/templates/jobs/ci.yml index 57b59af52fe89..7b744227cba7f 100644 --- a/eng/pipelines/templates/jobs/ci.yml +++ b/eng/pipelines/templates/jobs/ci.yml @@ -35,7 +35,7 @@ parameters: default: [] - name: SpellCheckPublicApiSurface type: boolean - default: false + default: true jobs: - job: Build diff --git a/eng/pipelines/templates/stages/archetype-sdk-client.yml b/eng/pipelines/templates/stages/archetype-sdk-client.yml index b356d0fc7997a..7271f8eb5fea2 100644 --- a/eng/pipelines/templates/stages/archetype-sdk-client.yml +++ b/eng/pipelines/templates/stages/archetype-sdk-client.yml @@ -55,7 +55,7 @@ parameters: default: [] - name: SpellCheckPublicApiSurface type: boolean - default: false + default: true variables: - template: ../variables/globals.yml diff --git a/sdk/agrifood/ci.yml b/sdk/agrifood/ci.yml index 891387aca5cb2..e221571b322c4 100644 --- a/sdk/agrifood/ci.yml +++ b/sdk/agrifood/ci.yml @@ -24,6 +24,7 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: agrifood + SpellCheckPublicApiSurface: true ArtifactName: packages Artifacts: - name: Azure.Verticals.AgriFood.Farming diff --git a/sdk/communication/ci.yml b/sdk/communication/ci.yml index fd80f4dc7fa35..c83696083e3e8 100644 --- a/sdk/communication/ci.yml +++ b/sdk/communication/ci.yml @@ -24,6 +24,7 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: communication + SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.Communication.CallingServer diff --git a/sdk/compute/ci.yml b/sdk/compute/ci.yml index 8f1c71fc9c713..e010a3fbc96fa 100644 --- a/sdk/compute/ci.yml +++ b/sdk/compute/ci.yml @@ -27,6 +27,7 @@ extends: parameters: ServiceDirectory: compute ArtifactName: packages + SpellCheckPublicApiSurface: false Artifacts: - name: Azure.ResourceManager.Compute safeName: AzureResourceManagerCompute diff --git a/sdk/containerregistry/ci.yml b/sdk/containerregistry/ci.yml index b0a538d27929b..2600e698067da 100644 --- a/sdk/containerregistry/ci.yml +++ b/sdk/containerregistry/ci.yml @@ -31,6 +31,7 @@ extends: SDKType: client ServiceDirectory: containerregistry ArtifactName: packages + SpellCheckPublicApiSurface: false Artifacts: - name: Azure.Containers.ContainerRegistry safeName: AzureContainersContainerRegistry diff --git a/sdk/cosmosdb/ci.yml b/sdk/cosmosdb/ci.yml index 282b1cb5e7a61..68f4086608d73 100644 --- a/sdk/cosmosdb/ci.yml +++ b/sdk/cosmosdb/ci.yml @@ -26,6 +26,7 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: cosmosdb + SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.ResourceManager.CosmosDB diff --git a/sdk/digitaltwins/ci.yml b/sdk/digitaltwins/ci.yml index e03c69ef5fd96..a6cf04ef92445 100644 --- a/sdk/digitaltwins/ci.yml +++ b/sdk/digitaltwins/ci.yml @@ -25,6 +25,7 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: digitaltwins + SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.DigitalTwins.Core diff --git a/sdk/dns/ci.yml b/sdk/dns/ci.yml index 82417ae80e598..5aedfc67f8fa2 100644 --- a/sdk/dns/ci.yml +++ b/sdk/dns/ci.yml @@ -26,6 +26,7 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: dns + SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.ResourceManager.Dns diff --git a/sdk/eventgrid/ci.yml b/sdk/eventgrid/ci.yml index 418b51e9e39b1..451d3d6ba4ed4 100644 --- a/sdk/eventgrid/ci.yml +++ b/sdk/eventgrid/ci.yml @@ -25,6 +25,7 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: eventgrid + SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.Messaging.EventGrid diff --git a/sdk/eventhub/ci.yml b/sdk/eventhub/ci.yml index 8200cbf71e1b3..fbce862d0fbc7 100644 --- a/sdk/eventhub/ci.yml +++ b/sdk/eventhub/ci.yml @@ -36,6 +36,7 @@ extends: parameters: SDKType: client ServiceDirectory: eventhub + SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.Messaging.EventHubs diff --git a/sdk/identity/ci.yml b/sdk/identity/ci.yml index a15a57da549d4..95b38d4da8866 100644 --- a/sdk/identity/ci.yml +++ b/sdk/identity/ci.yml @@ -25,6 +25,7 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: identity + SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.Identity diff --git a/sdk/insights/ci.yml b/sdk/insights/ci.yml index 335bd586ece35..18a457cc317c6 100644 --- a/sdk/insights/ci.yml +++ b/sdk/insights/ci.yml @@ -26,6 +26,7 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: insights + SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.ResourceManager.Insights diff --git a/sdk/machinelearningservices/ci.yml b/sdk/machinelearningservices/ci.yml index b8a2932934847..a5a114bff6274 100644 --- a/sdk/machinelearningservices/ci.yml +++ b/sdk/machinelearningservices/ci.yml @@ -24,6 +24,7 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: machinelearningservices + SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.ResourceManager.MachineLearningServices diff --git a/sdk/modelsrepository/ci.yml b/sdk/modelsrepository/ci.yml index 3475d229bf2f9..4a68db224ac72 100644 --- a/sdk/modelsrepository/ci.yml +++ b/sdk/modelsrepository/ci.yml @@ -25,6 +25,7 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: modelsrepository + SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.IoT.ModelsRepository diff --git a/sdk/monitor/ci.yml b/sdk/monitor/ci.yml index aa62137a43a24..2461277039e02 100644 --- a/sdk/monitor/ci.yml +++ b/sdk/monitor/ci.yml @@ -26,6 +26,7 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: monitor + SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.Monitor.OpenTelemetry.Exporter diff --git a/sdk/network/ci.yml b/sdk/network/ci.yml index ad09d50a66741..ca6170fec84c7 100644 --- a/sdk/network/ci.yml +++ b/sdk/network/ci.yml @@ -26,6 +26,7 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: network + SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.ResourceManager.Network diff --git a/sdk/objectanchors/ci.yml b/sdk/objectanchors/ci.yml index 9631b890d0a87..cfe03ea302bca 100644 --- a/sdk/objectanchors/ci.yml +++ b/sdk/objectanchors/ci.yml @@ -24,6 +24,7 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: objectanchors + SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.MixedReality.ObjectAnchors.Conversion diff --git a/sdk/personalizer/ci.yml b/sdk/personalizer/ci.yml index 3fec60dc64e73..86f0ab6364597 100644 --- a/sdk/personalizer/ci.yml +++ b/sdk/personalizer/ci.yml @@ -25,6 +25,7 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: personalizer + SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.AI.Personalizer diff --git a/sdk/purview/ci.yml b/sdk/purview/ci.yml index 8421be6f7903b..9744ca099f39e 100644 --- a/sdk/purview/ci.yml +++ b/sdk/purview/ci.yml @@ -24,6 +24,7 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: purview + SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.Analytics.Purview.Catalog diff --git a/sdk/remoterendering/ci.yml b/sdk/remoterendering/ci.yml index 602701e139279..d659e54380263 100644 --- a/sdk/remoterendering/ci.yml +++ b/sdk/remoterendering/ci.yml @@ -24,6 +24,7 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: remoterendering + SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.MixedReality.RemoteRendering diff --git a/sdk/sqlmanagement/ci.yml b/sdk/sqlmanagement/ci.yml index 84bf64291c89a..a37fa2a6d5c04 100644 --- a/sdk/sqlmanagement/ci.yml +++ b/sdk/sqlmanagement/ci.yml @@ -26,6 +26,7 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: sqlmanagement + SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.ResourceManager.Sql diff --git a/sdk/synapse/ci.yml b/sdk/synapse/ci.yml index 92771640e39fb..a3489d9756f07 100644 --- a/sdk/synapse/ci.yml +++ b/sdk/synapse/ci.yml @@ -26,6 +26,7 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: synapse + SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.Analytics.Synapse.Spark diff --git a/sdk/videoanalyzer/ci.yml b/sdk/videoanalyzer/ci.yml index 016e0ff7f0cca..53993f865c870 100644 --- a/sdk/videoanalyzer/ci.yml +++ b/sdk/videoanalyzer/ci.yml @@ -25,6 +25,7 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: videoanalyzer + SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.Media.VideoAnalyzer.Edge From 3fb9070187bb5a3608e061b98512686b4ba34bcd Mon Sep 17 00:00:00 2001 From: Daniel Jurek Date: Thu, 5 Aug 2021 22:53:48 -0700 Subject: [PATCH 02/12] Opt eventhub in --- sdk/eventhub/ci.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/sdk/eventhub/ci.yml b/sdk/eventhub/ci.yml index fbce862d0fbc7..8200cbf71e1b3 100644 --- a/sdk/eventhub/ci.yml +++ b/sdk/eventhub/ci.yml @@ -36,7 +36,6 @@ extends: parameters: SDKType: client ServiceDirectory: eventhub - SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.Messaging.EventHubs From deab0c1a2b82670b6d119d679f74db688af4990e Mon Sep 17 00:00:00 2001 From: Daniel Jurek Date: Fri, 6 Aug 2021 08:53:08 -0700 Subject: [PATCH 03/12] Those with SpellCheckPublichApiSurface: true are already opted-in; remove. Opt out agrifood which has some false positives. --- sdk/agrifood/ci.yml | 2 +- sdk/formrecognizer/ci.yml | 1 - sdk/storage/ci.yml | 1 - sdk/textanalytics/ci.yml | 2 -- sdk/translation/ci.yml | 1 - 5 files changed, 1 insertion(+), 6 deletions(-) diff --git a/sdk/agrifood/ci.yml b/sdk/agrifood/ci.yml index e221571b322c4..042493ce7d5ae 100644 --- a/sdk/agrifood/ci.yml +++ b/sdk/agrifood/ci.yml @@ -24,7 +24,7 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: agrifood - SpellCheckPublicApiSurface: true + SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.Verticals.AgriFood.Farming diff --git a/sdk/formrecognizer/ci.yml b/sdk/formrecognizer/ci.yml index e806f5d7daa4e..dd76d576ba691 100644 --- a/sdk/formrecognizer/ci.yml +++ b/sdk/formrecognizer/ci.yml @@ -25,7 +25,6 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: formrecognizer - SpellCheckPublicApiSurface: true ArtifactName: packages Artifacts: - name: Azure.AI.FormRecognizer diff --git a/sdk/storage/ci.yml b/sdk/storage/ci.yml index a5794aad2ace8..ff6e382028616 100644 --- a/sdk/storage/ci.yml +++ b/sdk/storage/ci.yml @@ -25,7 +25,6 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: storage - SpellCheckPublicApiSurface: true ArtifactName: packages Artifacts: - name: Azure.Storage.Blobs diff --git a/sdk/textanalytics/ci.yml b/sdk/textanalytics/ci.yml index 2e9e691f803ab..66ee9bd5acaa2 100644 --- a/sdk/textanalytics/ci.yml +++ b/sdk/textanalytics/ci.yml @@ -24,8 +24,6 @@ pr: extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: - ServiceDirectory: textanalytics - SpellCheckPublicApiSurface: true ArtifactName: packages Artifacts: - name: Azure.AI.TextAnalytics diff --git a/sdk/translation/ci.yml b/sdk/translation/ci.yml index f8cbd2ae4c692..aebe750fd403a 100644 --- a/sdk/translation/ci.yml +++ b/sdk/translation/ci.yml @@ -25,7 +25,6 @@ extends: parameters: ServiceDirectory: translation ArtifactName: packages - SpellCheckPublicApiSurface: true Artifacts: - name: Azure.AI.Translation.Document safeName: AzureAITranslationDocument From 818f99c403cab69d4027907bce7a233222230e45 Mon Sep 17 00:00:00 2001 From: Daniel Jurek Date: Fri, 6 Aug 2021 08:58:44 -0700 Subject: [PATCH 04/12] re-add service directory --- sdk/textanalytics/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/sdk/textanalytics/ci.yml b/sdk/textanalytics/ci.yml index 66ee9bd5acaa2..315827e3e96a5 100644 --- a/sdk/textanalytics/ci.yml +++ b/sdk/textanalytics/ci.yml @@ -24,6 +24,7 @@ pr: extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: + ServiceDirectory: textanalytics ArtifactName: packages Artifacts: - name: Azure.AI.TextAnalytics From e6ac88bae04a6a0e75d627bc73d74143652f1bee Mon Sep 17 00:00:00 2001 From: Daniel Jurek Date: Fri, 6 Aug 2021 12:02:55 -0700 Subject: [PATCH 05/12] Opt core out --- sdk/core/ci.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/sdk/core/ci.yml b/sdk/core/ci.yml index 1d8e0a7e7a803..dd5b3126ca13a 100644 --- a/sdk/core/ci.yml +++ b/sdk/core/ci.yml @@ -35,6 +35,11 @@ extends: parameters: ServiceDirectory: core ServiceToTest: '*' + # Opt out of spell checking the public API surface because `ServiceToTest` + # forces the `CodeChecks.ps1` to check ALL public API surfaces (including + # those which have known spelling errors) by specifying `*` to the + # -ServiceDirectory parameter. + SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.Core From 5ffc9d5d143266358743c3ffe8fc7062e7f65f8b Mon Sep 17 00:00:00 2001 From: Daniel Jurek Date: Fri, 6 Aug 2021 14:25:24 -0700 Subject: [PATCH 06/12] Add personalizer and identity false positive exceptions and remove from the opt-out list --- .vscode/cspell.json | 4 +++- sdk/identity/ci.yml | 1 - sdk/personalizer/ci.yml | 1 - 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.vscode/cspell.json b/.vscode/cspell.json index 6944f84da5128..2ce11ed466a6c 100644 --- a/.vscode/cspell.json +++ b/.vscode/cspell.json @@ -64,7 +64,9 @@ "uninstrumented", "westus", "xunit", - "vnet" + "vnet", + "unencrypted", + "personalizer" ], "overrides": [ { diff --git a/sdk/identity/ci.yml b/sdk/identity/ci.yml index 95b38d4da8866..a15a57da549d4 100644 --- a/sdk/identity/ci.yml +++ b/sdk/identity/ci.yml @@ -25,7 +25,6 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: identity - SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.Identity diff --git a/sdk/personalizer/ci.yml b/sdk/personalizer/ci.yml index 86f0ab6364597..3fec60dc64e73 100644 --- a/sdk/personalizer/ci.yml +++ b/sdk/personalizer/ci.yml @@ -25,7 +25,6 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: personalizer - SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.AI.Personalizer From b1fb6e8109fb571b176416f503d0080189a77419 Mon Sep 17 00:00:00 2001 From: Daniel Jurek Date: Fri, 6 Aug 2021 14:27:40 -0700 Subject: [PATCH 07/12] Add use of `--no-must-find-files` to usages of npx. This is not strictly necessary in aggregate-reports.yml, in that case it is meant to make invocation of cspell consistent --- eng/pipelines/aggregate-reports.yml | 1 + eng/scripts/Export-API.ps1 | 1 + 2 files changed, 2 insertions(+) diff --git a/eng/pipelines/aggregate-reports.yml b/eng/pipelines/aggregate-reports.yml index 20dfef1641f1c..b705a6465c70f 100644 --- a/eng/pipelines/aggregate-reports.yml +++ b/eng/pipelines/aggregate-reports.yml @@ -35,6 +35,7 @@ jobs: - pwsh: | npx cspell lint ` --config ./.vscode/cspell.json ` + --no-must-find-files ` ./sdk/**/api/*.cs displayName: Check spelling of public API surface # Spelling errors in public api surface are not blockers yet but will diff --git a/eng/scripts/Export-API.ps1 b/eng/scripts/Export-API.ps1 index 688cddf438685..9855ce9428697 100644 --- a/eng/scripts/Export-API.ps1 +++ b/eng/scripts/Export-API.ps1 @@ -20,6 +20,7 @@ if ($SpellCheckPublicApiSurface) { Write-Host "Spell check public API surface" npx cspell lint ` --config "$PSScriptRoot/../../.vscode/cspell.json" ` + --no-must-find-files ` "$PSScriptRoot/../../sdk/$ServiceDirectory/*/api/*.cs" if ($LASTEXITCODE) { Write-Host "##vso[task.LogIssue type=error;]Spelling errors detected. To correct false positives or learn about spell checking see: https://aka.ms/azsdk/engsys/spellcheck" From 03344c5d012ffda6adeaca11eea425724e74a301 Mon Sep 17 00:00:00 2001 From: Daniel Jurek Date: Tue, 17 Aug 2021 14:04:54 -0700 Subject: [PATCH 08/12] Opt out of public API surface spell checking --- .vscode/cspell.json | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) diff --git a/.vscode/cspell.json b/.vscode/cspell.json index 2ce11ed466a6c..bb731d41a5887 100644 --- a/.vscode/cspell.json +++ b/.vscode/cspell.json @@ -26,7 +26,29 @@ "*.log", "*.sln", "*.user", - ".vscode/cspell.json" + ".vscode/cspell.json", + + // These packages are opted out of public API surface spell checking. + // Spelling issues must be addressed before adding these back in. + "sdk/agrifood/*/api/*.cs", + "sdk/communication/*/api/*.cs", + "sdk/compute/*/api/*.cs", + "sdk/containerregistry/*/api/*.cs", + "sdk/cosmosdb/*/api/*.cs", + "sdk/digitaltwins/*/api/*.cs", + "sdk/dns/*/api/*.cs", + "sdk/eventgrid/*/api/*.cs", + "sdk/insights/*/api/*.cs", + "sdk/machinelearningservices/*/api/*.cs", + "sdk/modelsrepository/*/api/*.cs", + "sdk/monitor/*/api/*.cs", + "sdk/network/*/api/*.cs", + "sdk/objectanchors/*/api/*.cs", + "sdk/purview/*/api/*.cs", + "sdk/remoterendering/*/api/*.cs", + "sdk/sqlmanagement/*/api/*.cs", + "sdk/synapse/*/api/*.cs", + "sdk/videoanalyzer/*/api/*.cs" ], // cspell is not case sensitive // Sort words alphabetically to make this list easier to use From ad25f3d935b5548b78b8f1952b1d80ff4115c101 Mon Sep 17 00:00:00 2001 From: Daniel Jurek Date: Tue, 17 Aug 2021 15:47:57 -0700 Subject: [PATCH 09/12] Update config: Opt out via cspell.json instead of ci.yml; Add 'dont' to the list of words so Core has zero spelling errors --- .vscode/cspell.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.vscode/cspell.json b/.vscode/cspell.json index bb731d41a5887..404d6e1621bc8 100644 --- a/.vscode/cspell.json +++ b/.vscode/cspell.json @@ -28,7 +28,7 @@ "*.user", ".vscode/cspell.json", - // These packages are opted out of public API surface spell checking. + // These services are opted out of public API surface spell checking. // Spelling issues must be addressed before adding these back in. "sdk/agrifood/*/api/*.cs", "sdk/communication/*/api/*.cs", @@ -60,6 +60,7 @@ "deserializable", "deserializes", "diagnoser", + "dont", "dtmf", "epsg", "expando", From 37d6e9620608fbbe83327a4611e2e35f80046a1d Mon Sep 17 00:00:00 2001 From: Daniel Jurek Date: Tue, 17 Aug 2021 15:49:15 -0700 Subject: [PATCH 10/12] Remove opt out from ci.yml --- sdk/agrifood/ci.yml | 1 - sdk/communication/ci.yml | 1 - sdk/compute/ci.yml | 1 - sdk/containerregistry/ci.yml | 1 - sdk/core/ci.yml | 5 ----- sdk/cosmosdb/ci.yml | 1 - sdk/digitaltwins/ci.yml | 1 - sdk/dns/ci.yml | 1 - sdk/eventgrid/ci.yml | 1 - sdk/insights/ci.yml | 1 - sdk/machinelearningservices/ci.yml | 1 - sdk/modelsrepository/ci.yml | 1 - sdk/monitor/ci.yml | 1 - sdk/network/ci.yml | 1 - sdk/objectanchors/ci.yml | 1 - sdk/purview/ci.yml | 1 - sdk/remoterendering/ci.yml | 1 - sdk/sqlmanagement/ci.yml | 1 - sdk/synapse/ci.yml | 1 - sdk/videoanalyzer/ci.yml | 1 - 20 files changed, 24 deletions(-) diff --git a/sdk/agrifood/ci.yml b/sdk/agrifood/ci.yml index 042493ce7d5ae..891387aca5cb2 100644 --- a/sdk/agrifood/ci.yml +++ b/sdk/agrifood/ci.yml @@ -24,7 +24,6 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: agrifood - SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.Verticals.AgriFood.Farming diff --git a/sdk/communication/ci.yml b/sdk/communication/ci.yml index c83696083e3e8..fd80f4dc7fa35 100644 --- a/sdk/communication/ci.yml +++ b/sdk/communication/ci.yml @@ -24,7 +24,6 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: communication - SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.Communication.CallingServer diff --git a/sdk/compute/ci.yml b/sdk/compute/ci.yml index e010a3fbc96fa..8f1c71fc9c713 100644 --- a/sdk/compute/ci.yml +++ b/sdk/compute/ci.yml @@ -27,7 +27,6 @@ extends: parameters: ServiceDirectory: compute ArtifactName: packages - SpellCheckPublicApiSurface: false Artifacts: - name: Azure.ResourceManager.Compute safeName: AzureResourceManagerCompute diff --git a/sdk/containerregistry/ci.yml b/sdk/containerregistry/ci.yml index 2600e698067da..b0a538d27929b 100644 --- a/sdk/containerregistry/ci.yml +++ b/sdk/containerregistry/ci.yml @@ -31,7 +31,6 @@ extends: SDKType: client ServiceDirectory: containerregistry ArtifactName: packages - SpellCheckPublicApiSurface: false Artifacts: - name: Azure.Containers.ContainerRegistry safeName: AzureContainersContainerRegistry diff --git a/sdk/core/ci.yml b/sdk/core/ci.yml index dd5b3126ca13a..1d8e0a7e7a803 100644 --- a/sdk/core/ci.yml +++ b/sdk/core/ci.yml @@ -35,11 +35,6 @@ extends: parameters: ServiceDirectory: core ServiceToTest: '*' - # Opt out of spell checking the public API surface because `ServiceToTest` - # forces the `CodeChecks.ps1` to check ALL public API surfaces (including - # those which have known spelling errors) by specifying `*` to the - # -ServiceDirectory parameter. - SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.Core diff --git a/sdk/cosmosdb/ci.yml b/sdk/cosmosdb/ci.yml index 68f4086608d73..282b1cb5e7a61 100644 --- a/sdk/cosmosdb/ci.yml +++ b/sdk/cosmosdb/ci.yml @@ -26,7 +26,6 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: cosmosdb - SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.ResourceManager.CosmosDB diff --git a/sdk/digitaltwins/ci.yml b/sdk/digitaltwins/ci.yml index a6cf04ef92445..e03c69ef5fd96 100644 --- a/sdk/digitaltwins/ci.yml +++ b/sdk/digitaltwins/ci.yml @@ -25,7 +25,6 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: digitaltwins - SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.DigitalTwins.Core diff --git a/sdk/dns/ci.yml b/sdk/dns/ci.yml index 5aedfc67f8fa2..82417ae80e598 100644 --- a/sdk/dns/ci.yml +++ b/sdk/dns/ci.yml @@ -26,7 +26,6 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: dns - SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.ResourceManager.Dns diff --git a/sdk/eventgrid/ci.yml b/sdk/eventgrid/ci.yml index 451d3d6ba4ed4..418b51e9e39b1 100644 --- a/sdk/eventgrid/ci.yml +++ b/sdk/eventgrid/ci.yml @@ -25,7 +25,6 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: eventgrid - SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.Messaging.EventGrid diff --git a/sdk/insights/ci.yml b/sdk/insights/ci.yml index 18a457cc317c6..335bd586ece35 100644 --- a/sdk/insights/ci.yml +++ b/sdk/insights/ci.yml @@ -26,7 +26,6 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: insights - SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.ResourceManager.Insights diff --git a/sdk/machinelearningservices/ci.yml b/sdk/machinelearningservices/ci.yml index a5a114bff6274..b8a2932934847 100644 --- a/sdk/machinelearningservices/ci.yml +++ b/sdk/machinelearningservices/ci.yml @@ -24,7 +24,6 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: machinelearningservices - SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.ResourceManager.MachineLearningServices diff --git a/sdk/modelsrepository/ci.yml b/sdk/modelsrepository/ci.yml index 4a68db224ac72..3475d229bf2f9 100644 --- a/sdk/modelsrepository/ci.yml +++ b/sdk/modelsrepository/ci.yml @@ -25,7 +25,6 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: modelsrepository - SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.IoT.ModelsRepository diff --git a/sdk/monitor/ci.yml b/sdk/monitor/ci.yml index 2461277039e02..aa62137a43a24 100644 --- a/sdk/monitor/ci.yml +++ b/sdk/monitor/ci.yml @@ -26,7 +26,6 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: monitor - SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.Monitor.OpenTelemetry.Exporter diff --git a/sdk/network/ci.yml b/sdk/network/ci.yml index ca6170fec84c7..ad09d50a66741 100644 --- a/sdk/network/ci.yml +++ b/sdk/network/ci.yml @@ -26,7 +26,6 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: network - SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.ResourceManager.Network diff --git a/sdk/objectanchors/ci.yml b/sdk/objectanchors/ci.yml index cfe03ea302bca..9631b890d0a87 100644 --- a/sdk/objectanchors/ci.yml +++ b/sdk/objectanchors/ci.yml @@ -24,7 +24,6 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: objectanchors - SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.MixedReality.ObjectAnchors.Conversion diff --git a/sdk/purview/ci.yml b/sdk/purview/ci.yml index 9744ca099f39e..8421be6f7903b 100644 --- a/sdk/purview/ci.yml +++ b/sdk/purview/ci.yml @@ -24,7 +24,6 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: purview - SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.Analytics.Purview.Catalog diff --git a/sdk/remoterendering/ci.yml b/sdk/remoterendering/ci.yml index d659e54380263..602701e139279 100644 --- a/sdk/remoterendering/ci.yml +++ b/sdk/remoterendering/ci.yml @@ -24,7 +24,6 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: remoterendering - SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.MixedReality.RemoteRendering diff --git a/sdk/sqlmanagement/ci.yml b/sdk/sqlmanagement/ci.yml index a37fa2a6d5c04..84bf64291c89a 100644 --- a/sdk/sqlmanagement/ci.yml +++ b/sdk/sqlmanagement/ci.yml @@ -26,7 +26,6 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: sqlmanagement - SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.ResourceManager.Sql diff --git a/sdk/synapse/ci.yml b/sdk/synapse/ci.yml index a3489d9756f07..92771640e39fb 100644 --- a/sdk/synapse/ci.yml +++ b/sdk/synapse/ci.yml @@ -26,7 +26,6 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: synapse - SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.Analytics.Synapse.Spark diff --git a/sdk/videoanalyzer/ci.yml b/sdk/videoanalyzer/ci.yml index 53993f865c870..016e0ff7f0cca 100644 --- a/sdk/videoanalyzer/ci.yml +++ b/sdk/videoanalyzer/ci.yml @@ -25,7 +25,6 @@ extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: videoanalyzer - SpellCheckPublicApiSurface: false ArtifactName: packages Artifacts: - name: Azure.Media.VideoAnalyzer.Edge From 7378903a5d1f50ab680d902253372befdd6cb6a7 Mon Sep 17 00:00:00 2001 From: Daniel Jurek Date: Tue, 17 Aug 2021 15:51:54 -0700 Subject: [PATCH 11/12] Remove SpellCheckPublicApiSurface parameter from ci.yml files, opt-out is handled in cspell.json --- eng/pipelines/aggregate-reports.yml | 3 --- eng/pipelines/templates/jobs/ci.yml | 5 +---- eng/pipelines/templates/stages/archetype-sdk-client.yml | 4 ---- 3 files changed, 1 insertion(+), 11 deletions(-) diff --git a/eng/pipelines/aggregate-reports.yml b/eng/pipelines/aggregate-reports.yml index b705a6465c70f..1413230de681d 100644 --- a/eng/pipelines/aggregate-reports.yml +++ b/eng/pipelines/aggregate-reports.yml @@ -41,9 +41,6 @@ jobs: # Spelling errors in public api surface are not blockers yet but will # become blockers when this is rolled out to all services. For now, turn # the pipeline yellow if spelling errors are detected but do not block. - # Individual services can be blocked on spelling errors using: - # `SpellCheckPublicApiSurface: true` - # in the archetype-sdk-client.yml template invocation continueOnError: true - template: /eng/common/pipelines/templates/steps/verify-links.yml diff --git a/eng/pipelines/templates/jobs/ci.yml b/eng/pipelines/templates/jobs/ci.yml index 7b744227cba7f..16e131b2ea9c9 100644 --- a/eng/pipelines/templates/jobs/ci.yml +++ b/eng/pipelines/templates/jobs/ci.yml @@ -33,9 +33,6 @@ parameters: - name: MatrixReplace type: object default: [] -- name: SpellCheckPublicApiSurface - type: boolean - default: true jobs: - job: Build @@ -140,7 +137,7 @@ jobs: arguments: > -ServiceDirectory ${{ parameters.ServiceToTest }} -SDKType ${{ parameters.SDKType }} - -SpellCheckPublicApiSurface:$${{ parameters.SpellCheckPublicApiSurface }} + -SpellCheckPublicApiSurface pwsh: true failOnStderr: false - task: ms.vss-governance-buildtask.governance-build-task-component-detection.ComponentGovernanceComponentDetection@0 diff --git a/eng/pipelines/templates/stages/archetype-sdk-client.yml b/eng/pipelines/templates/stages/archetype-sdk-client.yml index 7271f8eb5fea2..7bcd047ac55d7 100644 --- a/eng/pipelines/templates/stages/archetype-sdk-client.yml +++ b/eng/pipelines/templates/stages/archetype-sdk-client.yml @@ -53,9 +53,6 @@ parameters: - name: MatrixReplace type: object default: [] -- name: SpellCheckPublicApiSurface - type: boolean - default: true variables: - template: ../variables/globals.yml @@ -74,7 +71,6 @@ stages: ArtifactName: packages TestSetupSteps: ${{ parameters.TestSetupSteps }} TestTimeoutInMinutes: ${{ parameters.TestTimeoutInMinutes }} - SpellCheckPublicApiSurface: ${{ parameters.SpellCheckPublicApiSurface }} MatrixConfigs: - ${{ each config in parameters.MatrixConfigs }}: - ${{ config }} From 1b08897c172b317640dab2129c732e8e46748cda Mon Sep 17 00:00:00 2001 From: Daniel Jurek Date: Wed, 18 Aug 2021 09:39:01 -0700 Subject: [PATCH 12/12] Use more restrictive globbing pattern in aggregate-reports.yml for spell checking. The previous pattern was including tests folders unnecessarily --- eng/pipelines/aggregate-reports.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/eng/pipelines/aggregate-reports.yml b/eng/pipelines/aggregate-reports.yml index 1413230de681d..28edce4a2fa91 100644 --- a/eng/pipelines/aggregate-reports.yml +++ b/eng/pipelines/aggregate-reports.yml @@ -36,9 +36,9 @@ jobs: npx cspell lint ` --config ./.vscode/cspell.json ` --no-must-find-files ` - ./sdk/**/api/*.cs + 'sdk/*/*/api/*.cs' displayName: Check spelling of public API surface - # Spelling errors in public api surface are not blockers yet but will + # Spelling errors in public api surface are not blockers yet but will # become blockers when this is rolled out to all services. For now, turn # the pipeline yellow if spelling errors are detected but do not block. continueOnError: true