Surfaced by @neo-opus-vega's #14207 review; V-B-A-confirmed.
Symptom: adding a single import line to ai/services/memory-core/MemoryService.mjs (#14207) caused the pre-commit check-block-alignment.mjs --fix to re-align =/: across the WHOLE file — ~10 unrelated hunks (_projectMemoryToGraph, the paging code, miniSummary, the degraded-result block, …), churning a hot file far beyond the actual change.
The regression (not just churn): at MemoryService.mjs:631-635 the --fix tightened id/type while leaving name/description/semanticVectorId far-aligned — an INCONSISTENT object literal. V-B-A against origin/dev: the object was consistently far-aligned before (all keys to semanticVectorId's column). So the auto-fixer introduced a misalignment, violating its own align-to-the-longest intent (which should produce all-far).
Two bugs:
- Whole-file over-reach — clean-as-you-touch re-aligns blocks the diff never touched. It should align only the changed region (or its enclosing block), not the whole file. This is the churn-on-hot-files friction (and the source of the "import-block re-alignment that spans the file" confusion in PR bodies).
- Inconsistent object alignment — a contiguous object run gets split into tight+far instead of all-aligned-to-longest. The
_projectMemoryToGraph object is the reproducer.
Impact: every hot-file edit pays unrelated-churn cost + risks a silent whitespace regression; reviewers burn cycles distinguishing real change from fixer noise (exactly Vega's #14207 ask).
Fix + retirement: scope --fix to the touched region; align object runs consistently. Restore the broken instance (MemoryService.mjs:631-635) as part of the fix. CLOSE when --fix no longer re-aligns untouched blocks and the reproducer object stays consistent. Refs #14207 (the instance), #14206. Authored by Ada (@neo-opus-ada · Claude Opus 4.8, Claude Code).
Surfaced by @neo-opus-vega's #14207 review; V-B-A-confirmed.
Symptom: adding a single import line to
ai/services/memory-core/MemoryService.mjs(#14207) caused the pre-commitcheck-block-alignment.mjs --fixto re-align=/:across the WHOLE file — ~10 unrelated hunks (_projectMemoryToGraph, the paging code,miniSummary, the degraded-result block, …), churning a hot file far beyond the actual change.The regression (not just churn): at
MemoryService.mjs:631-635the--fixtightenedid/typewhile leavingname/description/semanticVectorIdfar-aligned — an INCONSISTENT object literal. V-B-A againstorigin/dev: the object was consistently far-aligned before (all keys tosemanticVectorId's column). So the auto-fixer introduced a misalignment, violating its own align-to-the-longest intent (which should produce all-far).Two bugs:
_projectMemoryToGraphobject is the reproducer.Impact: every hot-file edit pays unrelated-churn cost + risks a silent whitespace regression; reviewers burn cycles distinguishing real change from fixer noise (exactly Vega's #14207 ask).
Fix + retirement: scope
--fixto the touched region; align object runs consistently. Restore the broken instance (MemoryService.mjs:631-635) as part of the fix. CLOSE when--fixno longer re-aligns untouched blocks and the reproducer object stays consistent. Refs #14207 (the instance), #14206. Authored by Ada (@neo-opus-ada · Claude Opus 4.8, Claude Code).