fix: read JSON without schedules the same way everywhere (audit B5) #62

Merged
abiwab merged 6 commits from fix/audit-b5 into main 2026-09-30 18:01:34 +02:00
Owner

Audit B5. JSON compiled before 1.4.0 has no schedules. Measured on a stored 1.3.0-style result: renderer outputs fell back on the old total (2h 31m), diffRecipes read 0 (a fake '150 -> 0' delta), the Gantt is empty, the CLI commands always compile from source so never see it.

Decision (maintainer): unified fallback + document.

  • kitchen: new scheduleTimes(compiled, mode?) = the timeline's total/idle, else the deprecated metrics.totalTime/idleTime, else 0. The single place the fallback lives, dropped with the deprecated fields in 2.0
  • renderer (html/markdown/print), analyzer diff, language-server title hint, cli view/cook/scale all read through it; the renderer's own helper is gone
  • the diff of such JSON now shows the real delta (150 -> 151) instead of 150 -> 0
  • docs (EN/FR API reference, llms-full): note on JSON compiled before 1.4.0 (Gantt stays empty, recompile to get mise en place) and the new exports
  • kitchen changeset extended

New tests fail on the previous code (diff of stored JSON). ci and conformance 98/98 pass.

Audit B5. JSON compiled before 1.4.0 has no `schedules`. Measured on a stored 1.3.0-style result: renderer outputs fell back on the old total (2h 31m), `diffRecipes` read 0 (a fake '150 -> 0' delta), the Gantt is empty, the CLI commands always compile from source so never see it. Decision (maintainer): unified fallback + document. - kitchen: new `scheduleTimes(compiled, mode?)` = the timeline's total/idle, else the deprecated `metrics.totalTime/idleTime`, else 0. The single place the fallback lives, dropped with the deprecated fields in 2.0 - renderer (html/markdown/print), analyzer diff, language-server title hint, cli view/cook/scale all read through it; the renderer's own helper is gone - the diff of such JSON now shows the real delta (150 -> 151) instead of 150 -> 0 - docs (EN/FR API reference, llms-full): note on JSON compiled before 1.4.0 (Gantt stays empty, recompile to get mise en place) and the new exports - kitchen changeset extended New tests fail on the previous code (diff of stored JSON). ci and conformance 98/98 pass.
abiwab merged commit 1f6d6df1b8 into main 2026-09-30 18:01:34 +02:00
abiwab deleted branch fix/audit-b5 2026-09-30 18:01:34 +02:00
Sign in to join this conversation.
No description provided.