Skip to content

Enable OneLoc localization pull requests - #21346

Merged
David Pine (IEvangelist) merged 1 commit into
mainfrom
joperezr-oneloc-pr-configuration
Oct 27, 2026
Merged

David Pine (IEvangelist) merged 1 commit into
mainfrom
joperezr-oneloc-pr-configuration

Conversation

@joperezr

Copy link
Copy Markdown
Member

Description

Allow the official OneLocBuild job to open or update localization pull requests against microsoft/aspire targeting main, instead of only producing localization artifacts.

Change CreatePr from false to true. Keep the existing non-PR, main-only job gate, localization package, GitHub App authentication, and mirror target unchanged. The shared template continues to reuse an existing localization PR (ReusePr: true) and does not automatically merge it (AutoCompletePr: false).

Arcade documents enabling PR creation after localization onboarding: https://github.com/dotnet/arcade/blob/main/Documentation/OneLocBuild.md#onboarding-to-onelocbuild-using-arcade.

Validation

  • git diff --check — passed before commit.
  • Inspected the timeline and task logs for official pipeline 1602, build 20261027.2 (3118276), revision b11685d93425e7938716bf22aa4fb67fb3d2eb03. The OneLocBuild job, Get GitHub App installation token task, and OneLocBuild task all succeeded. The token-acquisition log confirms an installation token was obtained for microsoft using the currently vendored authentication path, so this PR does not change Arcade authentication. The overall build failed outside OneLoc; it is not an end-to-end passing baseline for this change.
  • Attempted an isolated OneLoc YAML preview using Azure DevOps pipelines_write(action=run_pipeline, pipelineId=1602, previewRun=true, yamlOverride=...) — blocked: User not permitted to queue dry run for build pipeline 1602 with modified YAML. Permissions needed: EditBuild. No validation run was created and no localization PR was triggered.
  • Unit tests were not run: this changes only an existing template boolean. No test-selection map update is needed; the existing eng/pipelines/** routing is unchanged.
  • Production PR creation remains unvalidated. The OneLoc job is excluded from PR and personal-branch builds. After merge, inspect the next official main build, confirm token acquisition and OneLocBuild succeed, and verify that the localization App opens or updates the PR against main when translated changes are available. A successful build without translated changes may legitimately produce no PR.

Security considerations

This enables repository writes through the existing localization GitHub App installation. Repository access and pipeline service-connection authorization are reported as configured; the existing production token-acquisition path succeeds. It introduces no new credentials or permission configuration, retains the protected main-only/non-PR gate, and leaves automatic merging disabled.

Fixes # (issue)

Checklist

  • Is this feature complete?
    • Yes. Ready to ship.
    • No. Follow-up changes expected.
  • Are you including unit tests for the changes and scenario tests if relevant?
    • Yes
    • No
  • Did you add public API?
    • Yes
      • If yes, did you have an API Review for it?
        • Yes
        • No
      • Did you add <remarks /> and <code /> elements on your triple slash comments?
        • Yes
        • No
    • No
  • Does the change make any security assumptions or guarantees?
    • Yes
      • If yes, have you done a threat model and had a security review?
        • Yes
        • No
    • No

@github-actions

Copy link
Copy Markdown
Contributor

🚀 Dogfood this PR with:

⚠️ WARNING: Do not do this without first carefully reviewing the code of this PR to satisfy yourself it is safe.

curl -fsSL https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.sh | bash -s -- 21346

Or

  • Run remotely in PowerShell:
iex "& { $(irm https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.ps1) } 21346"

@aspire-repo-bot
aspire-repo-bot Bot requested a balanced review from Copilot October 27, 2026 16:59
@github-actions github-actions Bot added the area-engineering-systems infrastructure helix infra engineering repo stuff label Oct 27, 2026

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.

🔵 Needs a closer look

Production PR creation remains unvalidated, so enabling repository writes requires maintainer acceptance of the post-merge verification plan.

No open issues 🎉

What changed in this PR

Enables the official OneLocBuild job to open or update localization pull requests for microsoft/aspire targeting main, rather than only producing localization artifacts.

Changes:

  • Sets CreatePr to true in the existing localization template invocation.
  • Preserves the non-PR, main-only gate and existing authentication; PR reuse remains enabled and automatic merging remains disabled.
File Description
eng/​pipelines/​azure-pipelines.yml Enables localization PR creation through the existing OneLocBuild job.

Review effort: Balanced

@IEvangelist
David Pine (IEvangelist) merged commit ef092af into main Oct 27, 2026
18 checks passed
@microsoft-github-policy-service microsoft-github-policy-service Bot added this to the 17.0 milestone Oct 27, 2026
@aspire-repo-bot

Copy link
Copy Markdown
Contributor

✅ No documentation update needed.

Branch: docs_optional → build_or_ci_only (proven false positive of the only triggered signal).

  • Triggered signal: pr_body_has_cli_flag_mention. Evidence: the PR body mentions git diff --check in its validation notes, which is not an Aspire CLI flag.
  • The only changed file is eng/pipelines/azure-pipelines.yml, which matches eng/**. No user-facing surface changed.

Jose Perez Rodriguez (joperezr) added a commit that referenced this pull request Oct 28, 2026
## Description

Catch up the translations already produced by OneLoc while automatic
localization check-ins have been unavailable. This is a one-off import
for 13 languages across the CLI, dashboard, hosting resources, project
templates, and VS Code extension.

The translations come from the `Loc` artifact of [official build
20261027.3 /
3118448](https://dev.azure.com/dnceng/internal/_build/results?buildId=3118448),
using `LCL-JUNO-PROD-ASPIRE.2026.10.26.2-487e6ead`. That build's source
revision is `cd6c70ffe2467a3e95b3dee9239d66fe9613ec49`; the relevant
source files were unchanged on `main` when this import was prepared.

#21346 enabled automatic PR creation, but the next official OneLoc run
failed when the GitHub App attempted to create its localization branch.
[microsoft/github-operations#2023](microsoft/github-operations#2023)
separately requests access for the app. This PR checks in the available
translations without changing the app, pipeline, credentials, or
permissions.

### Changes

| Area | Updated files |
|---|---:|
| CLI | 521 |
| Dashboard | 157 |
| Hosting packages | 110 |
| Project templates | 117 |
| VS Code extension | 4 |
| Total | 909 |

Only localized XLF targets and localized template JSON files change.
English resources, source code, generated designers, package manifests,
dependencies, and OneLoc intermediate/report files are unchanged.

### Examples

Previously untranslated Spanish dashboard text now includes:

- `Configure your app to send telemetry to the dashboard.` -> `Configure
su aplicación para enviar telemetría al panel.`
- `Export as Mermaid` -> `Exportar como Mermaid`.
- `Terminal disconnected. The last output has been preserved.` ->
`Terminal desconectado. Se ha conservado la última salida.`

All 605 active dashboard source strings now have targets marked
translated in all 13 languages: 7,865 string/language pairs.

### Import safeguards and remaining work

- Validated all 85 OneLoc input mappings, 1,105 localized output files,
and 30,225 entries for source/key fidelity to checked-in localization
inputs, XML or JSON validity, and numeric format-placeholder
preservation before import.
- Preserved existing extension targets for 12 package updates whose
English source no longer matches `package.nls.json`. Only four
source-current extension corrections remain in this PR.
- The extension has a pre-existing extraction coverage gap: its
checked-in XLF inputs contain 62 keys, while `package.nls.json` has 433
keys. Repairing that extraction path is outside this resource-only
catch-up.
- Removed one trailing space from the generated Russian dashboard
translation to pass the whitespace check. Generated wording is otherwise
retained except for the 14 confirmed correctness fixes described below.
- The package's remaining 848 untranslated string/language pairs,
representing 66 CLI source strings, still require subsequent
localization updates. This PR does not claim complete product-wide
translation coverage or a linguistic review of every target.
- After merging `main` through `ee332f69cb` in `09a63ddd2e`, resolved
the agent-plugin localization conflicts from #20946 by resource ID. The
changed English strings `InitCommand_SelectSkills` and
`InitCommand_SkillsOptionDescription` are reset to their current English
source with `state="new"` in all 13 languages (26 targets). The 16 newly
added strings also remain English with `state="new"` (208 targets).
These are additional entries awaiting localization; no replacement
translations were authored. The other 1,014 targets in the affected
files and all 14 review corrections are preserved.

### Confirmed review corrections

Commit `2b1f3e7a4b` makes 14 one-line corrections after checking the
review comments against the English source and actual consumers:

- Twelve dashboard partial-result messages now preserve the
displayed/total relationship. In particular, Turkish trace text no
longer reports 100 out of 25 when displaying 25 of 100. Only the count
phrases change; the surrounding translated wording and `<strong>` markup
are preserved.
- The German `aspire wait` resource argument now describes waiting
rather than restarting a resource.
- The Italian React/C# starter template name uses `AppHost`, not
`AppHostt`.

These are concrete meaning/typo corrections, not stylistic rewrites of
the localization team's output.

### Validation

The following commands passed:

```powershell
.\restore.cmd

dotnet msbuild src\Aspire.Dashboard\Aspire.Dashboard.csproj -t:PrepareResources -p:ErrorOnOutOfDateXlf=true -p:UpdateXlfOnBuild=false -nologo -v:minimal
dotnet msbuild src\Aspire.Cli\Aspire.Cli.csproj -t:PrepareResources -p:TargetFramework=net11.0 -p:ErrorOnOutOfDateXlf=true -p:UpdateXlfOnBuild=false -nologo -v:minimal

foreach ($project in @('Aspire.Hosting','Aspire.Hosting.Azure','Aspire.Hosting.Browsers','Aspire.Hosting.DevTunnels')) {
    dotnet msbuild "src\$project\$project.csproj" -t:PrepareResources -p:ErrorOnOutOfDateXlf=true -p:UpdateXlfOnBuild=false -nologo -v:minimal
}
dotnet msbuild src\Aspire.Hosting.Testing\Aspire.Hosting.Testing.csproj -t:PrepareResources -p:TargetFramework=net10.0 -p:ErrorOnOutOfDateXlf=true -p:UpdateXlfOnBuild=false -nologo -v:minimal

git diff --check
```

From `extension`:

```powershell
node .\scripts\prepareCorepackYarn.mjs
corepack yarn install --frozen-lockfile --non-interactive
corepack yarn gulp localizationBundle
```

The actual MSBuild resource pipeline generated and compiled the
translated resources for all seven affected .NET projects. The
extension's production importer generated all 13 locale files; their 806
entries were compared with the XLF inputs and matched. All four changed
extension targets were separately checked against current English source
values.

After the 14 review corrections, the dashboard and CLI
`PrepareResources` commands above were rerun and passed. Each corrected
footer was formatted with displayed=25 and total=100 and checked for the
intended count relationship. XML comparison confirmed exactly one
translated target changed in each of the 13 corrected XLF files, with no
changes to sources or metadata; JSON comparison confirmed only the
Italian template name changed. `git diff --check` passed.

After the merge resolution, the CLI `PrepareResources` command above was
rerun and passed. XML checks verified all 96 agent-resource keys against
current English in all 13 locales, confirmed that changed/new targets
exactly equal English with `state="new"`, and confirmed preservation of
the 1,014 unchanged-source targets and all 14 review fixes. `git diff
origin/main --check` passed; the PR diff remains limited to the same 909
localized files. Incoming generated designer files were left identical
to `main`.

Restore succeeded with existing NuGet audit warnings in unrelated
playground/test dependencies. A full product build, native/AOT
publishing, runtime UI tests, and linguistic review were not run; this
change is limited to generated translation resources with the explicit
corrections above. No test-selection map change is needed because
resource files remain inputs to the existing projects.

Fixes # (issue)

## Checklist

- Is this feature complete?
  - [x] Yes. Ready to ship.
  - [ ] No. Follow-up changes expected.
- Are you including unit tests for the changes and scenario tests if
relevant?
  - [ ] Yes
  - [x] No
- Did you add public API?
  - [ ] Yes
    - If yes, did you have an API Review for it?
      - [ ] Yes
      - [ ] No
- Did you add `<remarks />` and `<code />` elements on your triple slash
comments?
      - [ ] Yes
      - [ ] No
  - [x] No
- Does the change make any security assumptions or guarantees?
  - [ ] Yes
    - If yes, have you done a threat model and had a security review?
      - [ ] Yes
      - [ ] No
  - [x] No

---------

Co-authored-by: Copilot App <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area-engineering-systems infrastructure helix infra engineering repo stuff

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants