Skip to content

test: record the locale files one per line in the codex STT message test - #37689

Merged
KiroCrewCaptain merged 1 commit into
mainfrom
crew/linuxflackyguard/codex-stt-locale-set
Nov 15, 2026
Merged

KiroCrewCaptain merged 1 commit into
mainfrom
crew/linuxflackyguard/codex-stt-locale-set

Conversation

@bolichen97

Copy link
Copy Markdown
Contributor

Problem / Motivation

Goal: test/test_codex_stt.py::test_extra_missing_message_names_no_install_command stays green on main when two pull requests that each add a locale both merge.

The test pins the number of locale catalogues with assert len(files) == 13. Two PRs that each add a locale both rewrite it to 14, git merges the identical edit cleanly, and main has 15 files. It is one of the sites the K21 shared-total guard in PR #37660 counts on main.

Why it matters

Locales are added rarely, but when two land close together this red main fails every open PR until someone re-pins the count.

Not a goal

  • No product code changes; one test file.
  • No loosening: the count becomes an exact list of file names, so a renamed or missing catalogue now fails too.

What changed (motivation → approach → change)

Before After
assert len(files) == 13 _LOCALE_FILES, one catalogue name per line, and assert [p.name for p in files] == list(_LOCALE_FILES)

The rule is the one in docs/system-specs/common/testing-conventions.md § Merge-safe ratchets and counts (PR #37660).

Backwards compatibility

Compatible: test file only.

Removes nothing: the list has 13 entries, the old count.

Tests

Two-branch merge simulation (scratch worktrees; A adds aa.json, B adds zz.json, each updating the record the way the test asks, then git merge):

Base git merge test
origin/main ace367b clean FAILED assert 15 == 14
this branch clean passed

Negative control on this branch (a locale file added, record not updated): FAILED.

test/test_codex_stt.py: 86 passed; black, isort and flake8 clean.

Proof: not provable -- test-only change

Manual verification

N/A — test only; the simulation above is the behavioral check.

Related Issues

Part of #37656

Checklist

  • At most two commits (one is the norm), with a Conventional Commits title
  • Existing tests pass and new tests added for new functionality
  • Self-review completed; code follows project style guidelines
  • Documentation updated (if applicable)
  • No secrets, credentials, or internal references in the diff

@bolichen97
bolichen97 requested review from a team and KiroCrewCaptain as code owners November 15, 2026 20:21
@bolichen97
bolichen97 requested a review from CrysisDeu November 15, 2026 20:21
@github-actions github-actions Bot added the readiness: checking Automated validation is still running label Nov 15, 2026
@github-actions

Copy link
Copy Markdown
Contributor

UX Review (Opus 5.5) — ⏭️ skipped

Revision 6cf326cfe82fa1cdcd6bff5109853b7d7cce9ef0 touches no user-facing surface (no changes under website/ or committed screenshots), so the UX review was skipped. Does not block merge.

@github-actions

Copy link
Copy Markdown
Contributor

First Principles Review (Opus 5.5) — ⏭️ skipped

Revision 6cf326cfe82fa1cdcd6bff5109853b7d7cce9ef0 ships no reviewable capability (docs, tests or generated files only), so there is nothing to inventory. Does not block merge.

@github-actions

Copy link
Copy Markdown
Contributor

Design Review (Opus 5.5) — ✅ PASS

Design-level review of 6cf326cfe82fa1cdcd6bff5109853b7d7cce9ef0 — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS does not.

Design-Verdict: PASS

Test-only change. An exact per-line record replaces the count, so concurrent locale additions now conflict or fail loudly instead of merging silently.

[DESIGN-REVIEWED] 6cf326c

Description read

[DESCRIPTION-READ] 76d9c2c204bcc61ddf10ad832d7581a39691317094aaaab540596b297a40f682

That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with .github/scripts/pr-description-capture.sh over the same inputs; if it differs, the description or that evidence changed after this verdict was formed and any finding drawn from either is unproven.

@github-actions

Copy link
Copy Markdown
Contributor

Opus 5.5 Review — ✅ no blocking findings

Reviewed 6cf326cfe82fa1cdcd6bff5109853b7d7cce9ef0 — this comment is updated in place on each push.

Review details

Candidate is a doc reference, not runtime defect; drop it.

No findings.

[OPUS-REVIEWED] 6cf326c

Verdict parsed from the review's SHA-scoped output markers for commit 6cf326cfe82fa1cdcd6bff5109853b7d7cce9ef0.

False positive or not applicable? A repository writer can comment:
/ai-review override fable 6cf326cfe82fa1cdcd6bff5109853b7d7cce9ef0 false-positive: <reason, 20 to 500 characters>

@github-actions

Copy link
Copy Markdown
Contributor

GPT 6.1 Review — ✅ no blocking findings

GPT 6.1 completed its review of 6cf326cfe82fa1cdcd6bff5109853b7d7cce9ef0 and found no blocking issues.

This comment is updated in place on each push.

Review details

No findings.
[GPT-REVIEWED] 6cf326c

False positive or not applicable? A repository writer can comment:
/ai-review override gpt 6cf326cfe82fa1cdcd6bff5109853b7d7cce9ef0 false-positive: <reason, 20 to 500 characters>

@github-actions github-actions Bot added readiness: passed Eligible automated validation passed for the current revision and removed readiness: checking Automated validation is still running labels Nov 15, 2026
@KiroCrewCaptain

Copy link
Copy Markdown
Collaborator

Code change approver recommendation: Approve

Why: the decider estimates a 4% chance that this change introduces a defect, within the 12% limit for approving on its own, and every check passes.

This PR changes one test file and no product code. It swaps assert len(files) == 13 for an exact, sorted list of locale file names, one name per line. I checked the list against website/src/i18n/locales/: it matches the 13 non-en.json files exactly. The sort order also comes out the same on POSIX and Windows. en-XA sorts before en.manual because '-' comes before '.', and Windows comparing names case-insensitively doesn't change that. The Windows backend tests passed on this head. The check is now stricter: a renamed or missing catalogue fails too. Two PRs that each add a locale now edit different lines, so the merged result fails until someone updates the list, or the two edits conflict when the names land next to each other. The loop over the files is unchanged.

An automated recommendation, not a review: a maintainer still decides. It approves on its own only when the estimated chance of a defect is at most 12% and the change has at most 400 changed lines. Decider v3c (217fe607) · commit 6cf326cfe8 · 22 changed lines. If this recommendation is wrong, reply here: replies are how the approver is evaluated.

@KiroCrewCaptain KiroCrewCaptain left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I reviewed head 6cf326c. The change swaps the hard-coded locale count in the codex STT message test for an exact list of catalogue file names, one per line. The 13 names match the locale directory on current main (excluding en.json), in the order the test's sort produces. I merged this head with current main and ran test/test_codex_stt.py: 86 passed. The new assertion is stricter than the old count, there is no product code change, and I found nothing that blocks.

@KiroCrewCaptain
KiroCrewCaptain merged commit e57d21b into main Nov 15, 2026
95 checks passed
@KiroCrewCaptain
KiroCrewCaptain deleted the crew/linuxflackyguard/codex-stt-locale-set branch November 15, 2026 21:49
@github-actions github-actions Bot removed the readiness: passed Eligible automated validation passed for the current revision label Nov 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants