← Back to Pull requests

Add shared localization automation #14

Closed
unknown closed this pull request without merging on Nov 11, 2026 18:59 UTC
View on GitHub
unknown unknown commented on Nov 11, 2026 00:29 UTC
Author

Summary

  • Add actions/localization to vscode-python-ci for English export/submission, preserving existing inputs, defaults, dependency pins, credentials and destination scope.

  • Port the standalone Python helper and original regression suite from microsoft/vscode-common-python-lsp@6b4a3573e7e7a9fe1e468e129544432278aec2d6. The composite action changes only its relative helper lookup for the new layout (apart from YAML formatting).

  • Keep the CLI at scripts/localization.py, so existing stable/pre-release Azure templates need no command/path rewrite.

  • Add credential-free real CLI export/import smoke coverage for manifest-only, standalone-runtime and shared-source consumers across all 14 locales, including English-identical targets, partially omitted targets and wholly omitted-target tables.

  • Document the action, Azure resource configuration, validation, rollout and coordinated GitHub/Azure rollback.
  • Review fixes

  • Resolve handback paths before invoking the CLI under a different extension root, including relative --translations-root values.

  • Accept generated {} only for a complete, validated locale/table where every target element is omitted. Invalid JSON, invalid/empty strings, incomplete handbacks and empty output for targeted tables still fail before copying any locale files.

  • On retry after a failed push, distinguish synchronized no-ops from unpublished local commits and run the existing rebase/push flow without creating a duplicate commit.

  • No action input changes: action.yml is byte-for-byte unchanged from the initial PR. Input names, defaults, required flags and CLI arguments remain identical.
  • Validation

  • Reproduced all three review findings with focused regression tests before fixing them.

  • python -m unittest discover -s scripts -p "*_test.py" -v with LOCALIZATION_CLI_SMOKE=1: 36 tests passed locally, including all three real CLI round-trip profiles with relative handback paths and wholly omitted French targets.

  • Compatibility checks verified byte-identical action YAML, matching inputs against the source action, unchanged CLI argument declarations and Python 3.10 syntax compatibility.

  • Prettier and git diff --check passed.

  • GitHub PR validation passed all four Linux/Windows + Python 3.10/3.13 jobs for review-fix commit bdd05935b118347273494e5ac2d5e59b22d1b637, running all 36 tests with pinned Node 22.21.1.
  • Rollout boundary

    This PR is destination-only. It does not change consumer pins, translation data, credentials, Azure templates or publishing/release behavior. No live localization submission or Azure pipeline was run; repository/service-connection access and a controlled consumer pilot remain rollout gates.

    Before migrating consumers, pin their GitHub action and stable/pre-release Azure tooling resources to the same reviewed destination SHA. Keep source extraction paths and runtime-library submodules unchanged. autopep8's older d1877b84bb10ff7caa6bd12ab4e75498ba760790 baseline has stricter untranslated-handback validation; review that alignment separately rather than hiding it in relocation. Do not remove old tooling until relevant callers and release branches have migrated.

    Diff: 400 lines (+300 / -100) across 5 files Reviewer: edvilme Review duration: 1110m
    All Vouch review confidence checks passed
    Residual risk 0.19 = Change Risk (0.45) × (1 − Review Confidence (0.57)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.45 · 400 lines diff across 5 files
    0.45
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.17 · 1 substantive comment(s)
    0.17
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    56%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.359
    Shallow Review Depth shallow_review_depth
    0.289
    Real PR Conversation Timeline
    1 comments
    "Review active on #14"
    general weight: 0.35
    Reviewers
    Assignees
    Unassigned
    Labels
    risk: low confidence: 56.8% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 44.7% (MEDIUM) · Higher = larger blast radius
    44.7%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 56.8% · Lower = rushed or shallow review
    56.8%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 19.3% · Safe to merge
    19.3%