Skip to content

Chore/translate legacy comments - #61

Merged
VeryComplexAndLongName merged 10 commits into
mainfrom
chore/translate-legacy-comments
Aug 25, 2026
Merged

VeryComplexAndLongName merged 10 commits into
mainfrom
chore/translate-legacy-comments

Conversation

@VeryComplexAndLongName

Copy link
Copy Markdown
Owner

No description provided.

VeryComplexAndLongName and others added 10 commits August 25, 2026 10:49
…agent, non-security)

Sets up the retranslate-legacy-comments-to-english OpenSpec change and
translates baselined Cyrillic comments/JSDoc/fixture text in
eslint.config.js and packages/core/src/{git,index,browser,default-runners,
change-state,change-state.test,openspec,openspec.test,protocol,
agent-runner,agent-runner.test}.ts to English, preserving meaning exactly.

agent-runner.ts's two fallback failure-reason strings and the
prompt-injection fixture text in agent-runner.test.ts (plus its matching
assertion) were also translated; no test asserted the fixture text
verbatim in the source language.
Translates comments/JSDoc in claude.ts, codex.ts, copilot.ts, gemini.ts,
local-llm.ts, registry.ts, shared.ts, and shared.test.ts.

shared.ts's commandInstruction() previously returned Russian text for the
plan/implement/review/status/cancel command kinds while list/show/validate
were already English; translated the remaining branches to match. This is
the literal instruction prefix sent to CLI agents as part of the real
prompt, so it is a small runtime-text change (flagged in proposal.md), not
a pure comment edit. No test asserts the exact string.
…ity.ts

Translates security.ts's 39 baselined lines (allowlist/cwd-sandbox
decision messages, the prepareAgentContext data/instructions header,
audit-log JSDoc) faithfully, preserving the security-invariant wording.
Updated security.test.ts's matching regex/assertions and its
prompt-injection fixture text to stay consistent with the translated
implementation strings it checks against.

Verified with `npm run test --workspace packages/core` (170 tests passed).
Translates comments/JSDoc in cli.ts, index.ts, websocket.ts, wire.ts,
rest.ts, static.ts, server.ts, static.test.ts, server.test.ts,
scripts/build-client.mjs, scripts/client-build-options.mjs.

No functional strings needed translation in this package; all changes are
comments/JSDoc. Verified with `npm run test --workspace packages/server`
(40 tests passed).
Translates comments/JSDoc across config.ts, commands.ts, extension.ts,
native/diff.ts, native/git.ts, native/open-doc.ts, run-controller.ts,
test-utils/vscode-mock.ts, webview/ai-panel.ts, test/suite/index.ts,
test/suite/extension.test.ts, test/run.mjs, vitest.config.ts, and
scripts/build-options.mjs.

No functional strings needed translation in this package; all changes are
comments/JSDoc. Verified with `npm run test --workspace packages/extension`
(101 tests passed).
Translates comments/JSDoc and one runtime error message in types.ts,
transport/types.ts, index.ts, transport/message-bridge-transport.ts,
transport/fetch-transport.ts, transport/fetch-transport.test.ts,
transport/contract.test.ts, extension-entry.tsx, and markdown.tsx.

standalone-entry.tsx's baselined lines were already replaced with English
text by an unrelated prior change (restore-standalone-workspace-fallback);
nothing remained to translate there.

markdown.test.tsx's Russian sample sentences were translated to English
and the matching assertion (checking the plain-text remainder around the
bold/code tokens) was updated to match — the test still verifies the same
inline-markdown parsing behavior.
Translates comments/JSDoc in TasksChecklist.tsx, SpecsTree.tsx,
SpecsSearch.tsx, RequirementView.tsx, ChangeDiff.tsx, ChangeRelations.tsx,
ChangesList.tsx, ArchiveList.tsx, and AiPanel.tsx.

Translated Russian fixture text (sample requirement/spec/proposal strings)
in SpecsTree.test.tsx, SpecsSearch.test.tsx, RequirementView.test.tsx, and
ChangeRelations.test.tsx, updating the few assertions/search queries that
depended on the fixture text's exact wording so each test keeps verifying
the same behavior (substring/shape checks, not byte-for-byte contracts).

Verified with `npm run test --workspace packages/webui` (112 tests passed).
Translates smoke-test-notes.md (standalone-app) and TEST-NOTES.md
(vscode-extension) in full, from Russian to English. Both are historical
live-test notes from already-archived changes with no functional content
(narrative documentation of manual smoke tests) — safe to translate
wholesale, preserving the exact same technical detail and structure.

A repo-wide grep for Cyrillic now finds only the two files that are
correctly meant to keep it: packages/core/src/openspec-fixtures/show.json
(explicitly exempt from the scanner, a captured real openspec CLI
response) and scripts/check-english.test.mjs (Cyrillic is the intentional
subject of the scanner's own tests, marked english-policy-allow).
Runs `node scripts/check-english.mjs --write-baseline` after all intended
translations are done: the baseline now has 0 entries (down from 635),
confirming no unintended Cyrillic remains in scanned files outside the
two files that are correctly exempt/allow-marked.

Verification results recorded in tasks.md:
- npm run lint:english: "English policy check passed."
- npm run typecheck: passes workspace-wide (cli/core/extension/server/webui).
- npm run test: 435 tests passed across all 5 workspaces.
- npm run lint: passes workspace-wide.
- openspec change validate --strict retranslate-legacy-comments-to-english:
  "Change is valid".
All tasks complete, npm run typecheck/lint/test all green, and openspec
change validate --strict passes.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@VeryComplexAndLongName
VeryComplexAndLongName merged commit 95358d9 into main Aug 25, 2026
6 checks passed
@VeryComplexAndLongName
VeryComplexAndLongName deleted the chore/translate-legacy-comments branch August 31, 2026 06:16
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.

1 participant