Repository navigation
chore: 分割で増えた scoria の指摘を直す(循環 import・重複・未使用 export) - #191
Conversation
…icate, an unused export EvaluatorContext moves to evaluatorContext.ts, so evaluator.ts and arrayEvaluation.ts no longer import each other; the editors read rows with the engine's normalizeData instead of a copy of it (sheetRows.ts); ensureSpillsCovering is no longer exported. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
CODEX VERDICT: LGTM\n\nRead SHA: 3eb7655.\n\n| Axis | Result |\n|---|---|\n| correctness and edge cases | none |\n| security (injection / path traversal / code evaluation) | none |\n| tests: does a test go red if the new behaviour breaks | none; yarn typecheck passes and yarn test:engine passes 2,216 tests. The requested Vitest command is blocked before test discovery by the existing vite.config.ts __dirname startup error. |\n| API / schema / wire / on-disk compatibility | none; the root engine export remains public, and the moved type is re-exported. |\n| consistency with the rest of the codebase | none |\n| i18n lockstep (src/lang has 8 locales) | none; no locale files are changed. |\n| TIER S→C (moves a public type; replaces a View helper with the engine's) | none |\n| the type move: EvaluatorContext identical to before; every importer updated; public export unchanged | confirmed; none |\n| normalizeSheetData → normalizeData in useMiniEditor.ts and editorSelection.ts: same result for every input (compare the two bodies in origin/main), the only difference the console.warn on an unknown shape | confirmed; none |\n| ensureSpillsCovering: unused outside rangeReading.ts | confirmed; none |\n\nFINDINGS COMPLETE: I read every hunk of the diff and this is every finding I have. |
Summary
Clears the three new findings that scoria reported after the splits (#188, #189, #190).
circular-dependency(evaluator.ts⇄arrayEvaluation.ts):EvaluatorContextmoves tosrc/engine/evaluatorContext.ts, so the two files no longer import each other.src/engine/index.tsaddsexport * from "./evaluatorContext", so the type stays public.jscpd(calculator.ts'snormalizeDataandsheetRows.ts'snormalizeSheetDatahad the same body): the editor side now uses the engine'snormalizeData, andsrc/vue/sheetRows.tsis removed.knip/unused-export:ensureSpillsCoveringinrangeReading.tsis no longer exported. Nothing outside the file used it.Items to Confirm
normalizeDataprints aconsole.warn.normalizeSheetDatadid not. In every other case the two return the same thing: the two functions had the same branches.npx madge --circular --extensions ts srcfinds the one cycle onorigin/mainand none on this branch.src/engine/index.ts,src/index.tsandsrc/core/index.tsare the same onorigin/mainand here.yarn lint,yarn typecheck,yarn build,yarn test,yarn test:engineandtest:evaluatorpass. The firsttest:enginerun had one failure, under a high machine load; running the whole suite again passed every test.User Prompt
🤖 Generated with Claude Code
work in GUIChatPluginSpreadsheet