chore(comments): drop epic, sprint and review-round ids from the code
The code cited its plan instead of saying why: `E28 review J4`, `(R6 S3b)`, `S1 justified…`,
`deep-review round 5`. That plan lives in the private ops repo, so for every reader of this one the
citation was noise, and a sentence whose subject was the plan step ("round 2 showed…") hid its
lesson behind an id. Each one is gone and the "why" kept: a bare citation is deleted, a sentence
carrying a lesson is reworded around it ("a later attempt showed…").
Measured (`scripts/audit_metrics.py`, product code): 652 lines in 270 files carried an epic code by
the definition the next commit holds (507 / 241 by the old, two-digit-only one) -> 0. Across all
code, tests, scripts and configs: ~1100 epic-code lines plus ~320 sprint/round ids.
Behaviour unchanged, checked mechanically: every changed .py file has the same AST once docstrings
are blanked; css/sh/toml/yml/json files are identical once comments are stripped; the only
non-comment changes in TS/JS are test titles, one description string in a contract table, and five
ESLint messages, whose text is all the gates snapshot diff holds. Not touched: Markdown (docs and
the changelog keep their history), Alembic migrations, TV episode notation (`S2 · E5`), DESIGN.md
ids (`C1`, `B4`, `S3h`), tracker ids (`SEC-16`, `DX-17`).
One stale claim fixed on the way: test_hls_reaper's docstring said the player checkpoints "every
10 s whether or not it is playing", which plex/stream.py calls wrong; it now says what the code does.
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
// @vitest-environment jsdom
|
||||
//
|
||||
// E22 S5: a clicked control's label is logged only when it is the app's own copy — as its English
|
||||
// A clicked control's label is logged only when it is the app's own copy — as its English
|
||||
// wording — so nothing a user wrote (a title, a tag, a channel name) can come out of the click log.
|
||||
import { describe, expect, it } from "vitest";
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import i18n from "./index";
|
||||
|
||||
// The translation KEY a piece of on-screen text is, or null (E22 S5 click capture).
|
||||
// The translation KEY a piece of on-screen text is, or null (for click capture).
|
||||
//
|
||||
// A click is logged by what the control IS, and its visible label is the most telling part — but a
|
||||
// label can be the user's own content (a video title, a tag, a channel name), which the log must not
|
||||
|
||||
@@ -6,7 +6,7 @@ import { vocabKey } from "../lib/vocab";
|
||||
// up with the raw id as the fallback — `t(\`config.fields.${key}.label\`, key)` — so a missing key never
|
||||
// fails loudly: the admin Configuration page showed `maintenance`, `tmdb`, `tmdb_api_key`,
|
||||
// `plex_overlay_map`… as bare identifiers, for months, and the i18n parity test stayed green because EN
|
||||
// and HU were missing the SAME keys (owner report, E11 S5). The ids live in Python, so the check reads
|
||||
// and HU were missing the SAME keys (owner report). The ids live in Python, so the check reads
|
||||
// the registries straight from the backend sources:
|
||||
// - `sysconfig.SPECS` → `config.groups.<group>`, `config.fields.<key>.label` + `.hint`, and for a
|
||||
// "choice" key `config.choices.<key>.<option>` — the options read from its Literal in config.py
|
||||
@@ -171,7 +171,7 @@ const youtubeReasons = [
|
||||
).matchAll(/"(\w+)"/g),
|
||||
].map((m) => m[1]!);
|
||||
|
||||
// E30: the closed English vocabularies the backend WRITES into data, named through `vocab.<group>`
|
||||
// The closed English vocabularies the backend WRITES into data, named through `vocab.<group>`
|
||||
// (lib/vocab) by their letters-and-digits key. A word the backend adds shows in English until named —
|
||||
// so each list is read from its source here: the TMDB crew jobs kept, every auto-tag the tagger can
|
||||
// create, and the built-in download profiles of the latest migration that seeds them.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { describe, expect, it } from "vitest";
|
||||
|
||||
// docs/DESIGN.md "Copy" (E28 S3g): the parts of the copy rule a machine can read, held over every
|
||||
// docs/DESIGN.md "Copy": the parts of the copy rule a machine can read, held over every
|
||||
// value in both languages. The rest (one name per feature, one verb per meaning, "…" when a command
|
||||
// asks first) needs a reader and is checked by the DESIGN conformance step.
|
||||
|
||||
@@ -46,7 +46,7 @@ describe("the copy rule", () => {
|
||||
|
||||
describe("one name per thing", () => {
|
||||
// The options of one choice are told apart by their names alone: two playback classes once shared
|
||||
// "Közvetlen lejátszás" in the HU filter (E30 review). A set = a `…Opt` object, or one choice key's
|
||||
// "Közvetlen lejátszás" in the HU filter. A set = a `…Opt` object, or one choice key's
|
||||
// options under config.choices.
|
||||
const sets = (): [string, Record<string, unknown>][] => {
|
||||
const out: [string, Record<string, unknown>][] = [];
|
||||
|
||||
@@ -67,8 +67,8 @@ export function setLanguage(code: LangCode): void {
|
||||
document.documentElement.lang = code;
|
||||
}
|
||||
|
||||
// The Plex overlay serves only EN or HU metadata (E5 S6). Collapse a UI language to one of those for
|
||||
// the `?lang=` param / query keys. It takes the language instead of reading the singleton (E30 S3):
|
||||
// The Plex overlay serves only EN or HU metadata. Collapse a UI language to one of those for
|
||||
// the `?lang=` param / query keys. It takes the language instead of reading the singleton:
|
||||
// under the React Compiler a component's `plexLang()` was a value with no reactive input, so it kept
|
||||
// the language the component first rendered in — a switch left every Plex query on the old language.
|
||||
// A component passes `i18n.language` from useTranslation; non-component code the singleton's.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// E5 S6: every locale namespace must carry the SAME key set in English and Hungarian. A key present
|
||||
// Every locale namespace must carry the SAME key set in English and Hungarian. A key present
|
||||
// in one language but not the other renders the raw key string (missing translation) or is dead
|
||||
// weight (orphaned translation); this test fails loudly on either, per namespace.
|
||||
import { describe, expect, it } from "vitest";
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// @vitest-environment jsdom
|
||||
//
|
||||
// E28 review J5: a count in copy goes through i18next's plural forms (`count`), never a bare `n` —
|
||||
// A count in copy goes through i18next's plural forms (`count`), never a bare `n` —
|
||||
// the share dialog's expiry read "1 days".
|
||||
import { describe, expect, it } from "vitest";
|
||||
|
||||
@@ -37,7 +37,7 @@ describe("counted copy", () => {
|
||||
});
|
||||
});
|
||||
|
||||
// E31: "1 seasons", "Synced 1 subscriptions" — a counted string written as one plain key reads plural at
|
||||
// "1 seasons", "Synced 1 subscriptions" — a counted string written as one plain key reads plural at
|
||||
// one. So the rule is held for every string, not key by key: a value that carries {{count}} is a plural
|
||||
// pair (`_one` / `_other`), even where the two read the same today, so the next wording is a plural too.
|
||||
describe("every counted string is a plural pair", () => {
|
||||
|
||||
Reference in New Issue
Block a user