Skip to content

fix: Normalize terminology in sample updates#1397

Open
IEvangelist wants to merge 2 commits into
mainfrom
dapine/fix-sample-terminology
Open

fix: Normalize terminology in sample updates#1397
IEvangelist wants to merge 2 commits into
mainfrom
dapine/fix-sample-terminology

Conversation

@IEvangelist

Copy link
Copy Markdown
Member

Summary

  • centralize Aspire terminology normalization for generated data
  • normalize sample titles, descriptions, README content, and AppHost code before writing samples.json
  • prevent future generated catalogs from reintroducing .NET Aspire or app host

This fixes the sample-update regression visible in #1393.

Tests

  • pnpm --dir ./src/frontend exec vitest run --config vitest.config.ts tests/unit/update-samples.vitest.test.ts tests/unit/update-integrations.vitest.test.ts
  • replayed the samples.json content from chore: Update integration data and GitHub stats (7/23/26) #1393 through the normalizer (8 deprecated occurrences reduced to 0)

Copilot AI review requested due to automatic review settings July 23, 2026 01:56

@aspire-repo-bot aspire-repo-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Automated wording suggestions from the forbidden-words check. Apply the suggestions to resolve them.

Comment thread src/frontend/scripts/aspire-terminology.ts Outdated
Comment thread src/frontend/scripts/aspire-terminology.ts Outdated
Comment thread src/frontend/tests/unit/update-samples.vitest.test.ts Outdated
Comment thread src/frontend/tests/unit/update-samples.vitest.test.ts Outdated
Comment thread src/frontend/tests/unit/update-samples.vitest.test.ts Outdated
Comment thread src/frontend/tests/unit/update-samples.vitest.test.ts Outdated
Comment thread src/frontend/tests/unit/update-samples.vitest.test.ts Outdated
Comment thread src/frontend/tests/unit/update-samples.vitest.test.ts Outdated

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR centralizes terminology normalization (e.g., replacing “.NET Aspire” and “app host”) into a shared helper and applies it during data generation to keep samples.json and integration metadata consistent going forward, addressing the regression noted in #1393.

Changes:

  • Introduces normalizeAspireTerminology() and reuses it across generators.
  • Normalizes sample titles/descriptions/README text/AppHost code during update-samples generation and makes the script safe to import in tests by guarding the main() entrypoint.
  • Updates integration description normalization to use the shared helper and adds unit coverage (including asserting existing samples.json has no deprecated terms).

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/frontend/tests/unit/update-samples.vitest.test.ts Adds unit tests for sample terminology normalization and validates generated samples.json is clean.
src/frontend/src/utils/samples.ts Updates documentation comment to reflect that readmeRaw is terminology-normalized upstream content.
src/frontend/scripts/update-samples.ts Centralizes sample field normalization and guards main() so the module can be imported safely.
src/frontend/scripts/update-integrations.ts Replaces ad-hoc regex normalization with the shared terminology helper.
src/frontend/scripts/aspire-terminology.ts Adds a shared terminology normalizer used by generator scripts.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@aspire-repo-bot

Copy link
Copy Markdown
Contributor

Frontend HTML artifact ready

The latest frontend build uploaded the frontend-dist artifact for PR #1397. Use the VS Code button below to open this PR with GitHub Artifacts Explorer and browse the built HTML locally.

VS Code: Open PR #1397 artifacts

This comment updates automatically when a new frontend build artifact is uploaded.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Copilot-Session: febf329c-97d8-41aa-bd42-43273bc57fe7
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Copilot-Session: febf329c-97d8-41aa-bd42-43273bc57fe7
@IEvangelist
IEvangelist force-pushed the dapine/fix-sample-terminology branch from 9bbb307 to ec1ec43 Compare July 23, 2026 13:32
@IEvangelist IEvangelist added the ci:skip-forbidden-words Allows maintainers to bypass false positives in the forbidden-word check. label Jul 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci:skip-forbidden-words Allows maintainers to bypass false positives in the forbidden-word check.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants