Repository navigation
fix: one header for JavaScript files with a leading directive - #12299
Merged
Merged
Conversation
…the file The JavaScript header writer stopped at a `//#` directive on line 1 and prepended the new header above it, so every file that followed the prompts' "directive at the very top" advice kept its old header below the directive. The writer now lives in automation/scripts/impl_header.py (saved at the workflow's ref like the regen tools): the header goes on line 1, directives that sat above it move directly below it, and a stale second header block among the leading lines is dropped. The five JavaScript library prompts now place the directive directly below the header block. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0175hA62juZoajMcqKxWFGza
The old header writer prepended the new header above a `//#` directive on line 1 and left the generator's header below it, with its old score, date and library line. Each extra `// anyplot.ai` block was checked to be stale (Quality pending, or a date not later than the first header's) and removed with the blank lines directly above it; nothing else changed. Owner-authorized manual correction of pipeline-written catalogue files (2026-10-23). chartjs 1, d3 9, echarts 14, highcharts 19, muix 139. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0175hA62juZoajMcqKxWFGza
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0175hA62juZoajMcqKxWFGza
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0175hA62juZoajMcqKxWFGza
Contributor
There was a problem hiding this comment.
🔵 Needs a closer look
Moderate issues remain around preserving required license lines and placing directives immediately below headers when leading blank lines are present.
No open issues 🎉
What changed in this PR
This pull request fixes duplicate JavaScript implementation headers caused by leading orientation directives. It centralizes header rewriting, updates JavaScript library guidance and workflow wiring, adds focused tests, and removes stale duplicate headers from 182 catalogue implementations.
Changes:
- Added and integrated
replace_js_headerfor canonical JavaScript header replacement. - Updated prompts, render documentation, workflow tests, and write-back documentation.
- Removed stale duplicate header blocks from the affected JavaScript catalogue files.
| File | Reviewed change |
|---|---|
tests/unit/workflows/test_impl_header_step.py |
Tests workflow wiring and end-to-end header updates. |
tests/unit/automation/scripts/test_regen_writeback.py |
Updates stale-header regression coverage. |
tests/unit/automation/scripts/test_impl_header.py |
Tests replacement, cleanup, directive preservation, comments, line endings, and idempotence. |
prompts/library/muix.md |
Updates MUI X header and directive guidance. |
prompts/library/highcharts.md |
Updates Highcharts header and directive guidance. |
prompts/library/echarts.md |
Updates ECharts header and directive guidance. |
prompts/library/d3.md |
Updates D3 header and directive guidance. |
prompts/library/chartjs.md |
Updates Chart.js header and directive guidance. |
plots/wireframe-3d-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/windrose-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/windbarb-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/waterfall-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/voronoi-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/voronoi-basic/implementations/javascript/echarts.js |
Removes the stale duplicate header. |
plots/venn-labeled-items/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/venn-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/venn-basic/implementations/javascript/highcharts.js |
Removes the stale duplicate header. |
plots/tree-phylogenetic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/ternary-density/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/ternary-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/swarm-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/surface-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/sunburst-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/sudoku-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/subplot-grid/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/stereonet-equal-area/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/stereonet-equal-area/implementations/javascript/highcharts.js |
Removes the stale duplicate header. |
plots/stereonet-equal-area/implementations/javascript/echarts.js |
Removes the stale duplicate header. |
plots/stereonet-equal-area/implementations/javascript/d3.js |
Removes the stale duplicate header. |
plots/stem-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/star-chart-constellation/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/star-chart-constellation/implementations/javascript/d3.js |
Removes the stale duplicate header. |
plots/spirometry-flow-volume/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/spirometry-flow-volume/implementations/javascript/d3.js |
Removes the stale duplicate header. |
plots/spiral-timeseries/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/spectrum-nmr/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/spectrum-nmr/implementations/javascript/highcharts.js |
Removes the stale duplicate header. |
plots/sparkline-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/smith-chart-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/skewt-logp-atmospheric/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/silhouette-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/scatter-text/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/scatter-shot-chart/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/scatter-shot-chart/implementations/javascript/echarts.js |
Removes the stale duplicate header. |
plots/scatter-matrix/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/scatter-marginal/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/scatter-marginal/implementations/javascript/highcharts.js |
Removes the stale duplicate header. |
plots/scatter-lag/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/scatter-embedding/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/scatter-embedding/implementations/javascript/highcharts.js |
Removes the stale duplicate header. |
plots/scatter-constellation-diagram/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/scatter-constellation-diagram/implementations/javascript/highcharts.js |
Removes the stale duplicate header. |
plots/scatter-constellation-diagram/implementations/javascript/echarts.js |
Removes the stale duplicate header. |
plots/scatter-complex-plane/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/scatter-complex-plane/implementations/javascript/highcharts.js |
Removes the stale duplicate header. |
plots/scatter-categorical/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/scatter-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/scatter-ashby-material/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/scatter-3d/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/rose-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/root-locus-basic/implementations/javascript/echarts.js |
Removes the stale duplicate header. |
plots/roc-curve/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/radar-multi/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/radar-multi/implementations/javascript/echarts.js |
Removes the stale duplicate header. |
plots/radar-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/quiver-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/qrcode-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/psychrometric-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/psychrometric-basic/implementations/javascript/highcharts.js |
Removes the stale duplicate header. |
plots/psychrometric-basic/implementations/javascript/d3.js |
Removes the stale duplicate header. |
plots/probability-weibull/implementations/javascript/echarts.js |
Removes the stale duplicate header. |
plots/precision-recall/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/pp-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/polar-scatter/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/polar-line/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/polar-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/polar-bar/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/point-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/pie-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/pictogram-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/nyquist-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/network-weighted/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/network-transport-static/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/network-force-directed/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/network-bipartite/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/network-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/mohr-circle/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/maze-printable/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/marimekko-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/marimekko-basic/implementations/javascript/echarts.js |
Removes the stale duplicate header. |
plots/map-projections/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/map-marker-clustered/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/map-connection-lines/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/ma-differential-expression/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/lollipop-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/line-yield-curve/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/line-win-probability/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/line-tanabe-sugano/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/line-retention-cohort/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/line-reaction-coordinate/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/line-multi/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/line-growth-percentile/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/line-growth-percentile/implementations/javascript/highcharts.js |
Removes the stale duplicate header. |
plots/line-cycle-seasonal/implementations/javascript/d3.js |
Removes the stale duplicate header. |
plots/line-basic/implementations/javascript/echarts.js |
Removes the stale duplicate header. |
plots/line-arrhenius/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/line-3d-trajectory/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/lightcurve-transit/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/lift-curve/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/indicator-ichimoku/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/ice-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/hive-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/hive-basic/implementations/javascript/highcharts.js |
Removes the stale duplicate header. |
plots/histogram-capability/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/hexbin-map-geographic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/heatmap-stripes-climate/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/heatmap-risk-matrix/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/heatmap-polar/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/heatmap-periodic-table/implementations/javascript/muix.tsx |
Removes stale duplicate headers, including the extra middle block. |
plots/heatmap-periodic-table/implementations/javascript/echarts.js |
Removes the stale duplicate header. |
plots/heatmap-periodic-table/implementations/javascript/chartjs.js |
Removes the stale duplicate header. |
plots/heatmap-mandelbrot/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/heatmap-loss-triangle/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/heatmap-correlation/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/heatmap-cohort-retention/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/heatmap-cohort-retention/implementations/javascript/highcharts.js |
Removes the stale duplicate header. |
plots/heatmap-clustered/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/heatmap-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/heatmap-basic/implementations/javascript/echarts.js |
Removes the stale duplicate header. |
plots/heatmap-annotated/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/heatmap-adjacency/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/gauge-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/gauge-basic/implementations/javascript/highcharts.js |
Removes the stale duplicate header. |
plots/gauge-basic/implementations/javascript/d3.js |
Removes the stale duplicate header. |
plots/gauge-activity-rings/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/gauge-activity-rings/implementations/javascript/highcharts.js |
Removes the stale duplicate header. |
plots/gain-curve/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/frontier-efficient/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/forest-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/facet-grid/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/eye-diagram-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/errorbar-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/errorbar-asymmetric/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/ecg-twelve-lead/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/ecg-twelve-lead/implementations/javascript/echarts.js |
Removes the stale duplicate header. |
plots/ecg-twelve-lead/implementations/javascript/d3.js |
Removes the stale duplicate header. |
plots/ecdf-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/dumbbell-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/dot-matrix-proportional/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/donut-nested/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/donut-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/donut-basic/implementations/javascript/highcharts.js |
Removes the stale duplicate header. |
plots/donut-basic/implementations/javascript/echarts.js |
Removes the stale duplicate header. |
plots/diagnostic-regression-panel/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/depth-order-book/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/dendrogram-radial/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/dendrogram-radial/implementations/javascript/highcharts.js |
Removes the stale duplicate header. |
plots/dendrogram-basic/implementations/javascript/highcharts.js |
Removes the stale duplicate header. |
plots/datamatrix-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/curve-oc/implementations/javascript/echarts.js |
Removes the stale duplicate header. |
plots/curve-dose-response/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/contour-filled/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/contour-density/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/contour-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/confusion-matrix/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/column-stratigraphic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/coefficient-confidence/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/circos-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/circos-basic/implementations/javascript/highcharts.js |
Removes the stale duplicate header. |
plots/circlepacking-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/chord-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header while retaining explanatory comments. |
plots/chord-basic/implementations/javascript/d3.js |
Removes the stale duplicate header. |
plots/chessboard-pieces/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/chessboard-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/chessboard-basic/implementations/javascript/highcharts.js |
Removes the stale duplicate header. |
plots/cat-box-strip/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/candlestick-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/bubble-packed/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/biplot-pca/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/bifurcation-basic/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/bar-permutation-importance/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/bar-pareto/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/bar-heart-rate-zones/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/bar-error/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/bar-3d-categorical/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/audiogram-clinical/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/area-mountain-panorama/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/area-elevation-profile/implementations/javascript/muix.tsx |
Removes the stale duplicate header. |
plots/arc-basic/implementations/javascript/highcharts.js |
Removes the stale duplicate header. |
plots/alluvial-opinion-flow/implementations/javascript/d3.js |
Removes the stale duplicate header. |
changelog.d/js-header-directive.md |
Documents the JavaScript header correction. |
automation/scripts/regen_gate.py |
Updates header write-back documentation. |
automation/scripts/README.md |
Documents the centralized header writer. |
automation/scripts/impl_header.py |
Implements canonical JavaScript header replacement and stale-block removal. |
automation/js-render/render.mjs |
Documents directive discovery and placement. |
.github/workflows/impl-review.yml |
Copies and invokes the workflow-ref JavaScript header writer. |
Review effort: Lite
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
//# anyplot-orientation:directive on line 1 and prepended the new header above it, so the generator's header stayed below the directive with its old score, date and library line, and the site's code view showed both. The logic moved out of the workflow's inline Python intoautomation/scripts/impl_header.py(replace_js_header), which "Checkout PR code" saves at the workflow's ref next to the regen tools, so a PR branched off an oldermainstill gets the new writer.Canonical shape
The header goes on line 1. Directives that sat above the old header move directly below the new one. Directives and blank lines below the header keep their place. Any further
// anyplot.aiblock among the leading lines (blank lines, directives and header blocks before the first other line) is dropped together with the blank lines directly above it.Header first, because:
anyplot.aiheader.mainalready has its header on line 1, so the cleanup is a pure deletion and no file changes shape.A header block runs from its first line to its first
// Quality:line, or over the whole//run when it has none. Comment lines after theQuality:line are code comments and now stay. Before, the writer replaced the whole leading//run, so comments attached to a freshly generated header were dropped. The stale-block removal needs this bound anyway: inchord-basicmuix, explanatory comments follow the stale block directly.Cleanup method
A one-off script, kept outside the repository, listed every JavaScript implementation whose first 12 lines hold two
// anyplot.ailines. For each file it checked that the first block is the canonical four-line header and that every later block is stale: itsQuality:ispending, or its date is not later than the first block's. It removed the stale blocks by deleting lines and asserted that the result equalsreplace_js_headerapplied with the file's own first header. No file failed a check. One file,heatmap-periodic-tablemuix, carried three header blocks. Its middle block reads 78/100 with the same date as the first block, so it is stale by the rule.Workflow YAML has no verification loop
I reasoned through the following and covered what can be run locally:
reviewjob. The copy step has noif:, and the header step has noalways(), so the copy always exists when the import runs.RUNNER_TEMPis a default runner environment variable, and the heredoc already reads its inputs from the environment.import sys.tests/unit/workflows/test_impl_header_step.pyextracts the step's heredoc from the YAML and runs it as the runner would: from an empty directory, with the helper only under a fakeRUNNER_TEMP. It covers the three shapes for JavaScript and checks that the Python header still comes out right.Side effect on review provenance
review_provenance.pyhashes the whole library prompt into the rules version, so thelib-part changes for these five libraries. The edits touch only header and directive placement, not any review rule, so noreview-retestarm was dispatched.Observed, not changed
// License:line in the header "so it ships in every generated snippet". The writer has always replaced the whole header with four lines, so no Highcharts file onmainkeeps that line except inside the stale blocks this PR removes. Keeping it would change the header format, which is the owner's call.chord-basicmuix does not build against@mui/x-charts9.16.0. It imports@mui/x-charts/ChartContainer. Theorigin/maincopy fails the same way, so the break predates this PR.surface-basicggplot2, where the generator wrote#instead of#'. The other three are letsplot files (indicator-bollinger,parliament-basic,probability-weibull) with a docstring below a# ruff: noqaline. The R, Python and Julia writers stay unchanged here, as briefed.Plan
N/A
Test plan
tests/unit/automation/scripts/test_impl_header.py: 51 cases, one per catalogue shape (directive first, header then directive, a stale block with and without blank lines, two stale blocks, no header), plus idempotence, directive order, kept comments, CRLF, and a comment that mentions anyplot.ai.tests/unit/workflows/test_impl_header_step.py: the step's heredoc run end to end, plus wiring guards for the copy and the import.gauge-basicd3 and muix files anddonut-basicHighcharts in both themes withautomation/js-render/render.mjsunder Node 24.core.canvas.check_pngreads 2400x2400 for all six renders.uv run ruff check .,ruff format --check .,mypy api core agentsandmypy automation/scripts/impl_header.py.uv run pytest tests/unit -n autopassed (13305 passed, 3 skipped), as didtests/integration(87 passed).tools.changelog check --base origin/mainpassed.