Repository navigation
Conversation
engine: jb1, the default, builds with jb build as before. engine: mystmd runs mystmd's myst build from source-dir, the folder that holds myst.yml, with --html, --pdf or --ipynb (the QuantEcon/mystmd fork's) for the html, pdflatex and jupyter builders, --execute always, and --strict when extra-args is empty, which is now its default: the engine's own arguments, -W --keep-going on jb1. myst build exits 0 when it builds nothing, so after a build that exits 0 the step checks what was written: the site's index.html and its pages, or each export myst listed. For the myst command it prefers IPv4 in Node and, as root, lets jupyter_server start, which a QuantEcon container needs. Inputs with no mystmd meaning, and jb build's flags, are refused before the build. Only an html build fails on a cell that raises, and the error-output check has no mystmd version yet: both are #364. Harness: build-engine-inputs, against a stand-in myst, and build-mystmd, a real html build with upstream mystmd in the lean image as root. bjc-alert's test reads build-lectures' jb1 default from its check step. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WT8bMaCAew38BRvFFUUn3G
|
The first harness run, 46139725822, was red on four known flakes, not on this change. I've re-run all its jobs once.
I used "Re-run all jobs" rather than "Re-run failed jobs", because the setup-latex seed's cache key carries the run attempt. The two new jobs, Claude Code (on behalf of mmcky) |
|
Attempt 2 of 46139725822 was red on one job, the same flake, so I've re-run all jobs once more (attempt 3). The three artifact-race jobs and both new jobs passed. Claude Code (on behalf of mmcky) |
- The html check counts only "Error fetching" lines for myst's own content server (http://localhost:<port>), so a dead external link that --check-links reports no longer fails the build as a page not rendered. - html-copy-pdf and html-copy-notebooks are refused on mystmd whatever their case, as the stage steps' if: compares without case. - jb build's -v, -q, --verbose, --quiet, --freshenv and --individualpages are refused on mystmd too, with the fix named. - The CHANGELOG's Changed entry covers a whitespace-only extra-args, and says an empty one gave no flags beyond -n. - The chapter: source-dir is the folder that holds myst.yml, and build-path apart from where an export with its own output goes. Harness: build-engine-inputs adds an external address that failed to load, which passes, and html-copy-notebooks given as True, refused. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WT8bMaCAew38BRvFFUUn3G
Adds an
engineinput tobuild-lectures:jb1, the default, builds withjb buildas before, andmystmdruns mystmd'smyst build. This is the design agreed on #337, with the maintainer's seven decisions of 2026-11-28 recorded in the check comment.Why. QuantEcon/lectures builds its sites from one pool of lectures, and wants the engine as a matrix axis: Jupyter Book 1 publishes until the engine switch, and a mystmd leg runs beside it, non-publishing (QuantEcon/project-monorepo#77, the design note
.qe/dev/log/2026-11-16-product-builds-design.md). Itssite-build.ymlis Jupyter Book 1 only today, and puts mystmd in its second phase, after the cutovers.A
myst buildwith only the builder's flag passes where a jb1 build fails, so the input does more than swap the command. I checked with upstream mystmd 1.13.0, the QuantEcon/mystmd fork's base:--htmlbuilds of a two-page project, and the CLI's source at the fork's39cda14for the rest.--html--pdf,--ipynb--execute--strict--strict--strict--strictsite:, or noexportsError fetching <url>, exits 0-W, the oldextra-argsdefaultunknown option '-W'Changes
build-lectures/action.ymlengine,jb1by default. Empty meansjb1;mystand any other value are refused.extra-argsdefaults to empty, the engine's own:-W --keep-goingon jb1,--stricton mystmd, resolved in the first step with the other defaults. On a mystmd-based engine the first step refuses another builder, the two copy inputs, anoutput-dirother than., asource-dirwith nomyst.yml, andjb build's flags inextra-args, and logs thatnitpickanderror-outputsare not used. The jb1 build step is unchanged but for itsif:and the resolvedextra-args. A new step, "Build lectures with mystmd": fails early withoutmyst, logscommand -v mystandmyst --version, and forjupyterchecks for--ipynb; setsNODE_OPTIONS=…--dns-result-order=ipv4firstand, as root, Jupyter'sallow_rootthroughJUPYTER_CONFIG_PATHfrom$RUNNER_TEMP; runsmyst build <flag> --execute <extra-args>fromsource-dir; and after an exit 0 checks what was written. The failure summary names the engine, and a separate upload step takes mystmd'slogs,tempandexecute. The error-output check runs on jb1 onlybuild-lectures/check-myst-exports.pypdflatexandjupyteron mystmd: reads_build/logs/myst.build.json, which lists the exports myst collected before it ran them, and fails unless it lists one of the builder's formats (pdf,pdf+tex,typst; oripynb) and each one's output was written by this builddocs/user/actions/build-lectures.mdextra-argson mystmd; "Withengine: mystmd" under Behaviour, with the command table and a table of what applies on each engine, which cites #364; what fails the job; a Troubleshooting entry for each new error. Inputs and Outputs regeneratedbuild-lectures/README.md,docs/user/README.md.github/workflows/test-actions.ymlbuild-html-copy, and inharness-summary'sneeds:beside it:build-engine-inputsandbuild-mystmd(below).github/fixtures/mini-mystmd/myst.ymlwith asite:, an intro and an executed lecture.github/fixtures/myst-stand-in/mystandjbthatbuild-engine-inputsputs onPATH.github/fixtures/bjc-alert/test.cjsbuild-jupyter-cache'sextra-argsdefault isbuild-lectures' own now compares with build-lectures' jb1 default, read from the one line in its check step that sets it, when the declared default is emptybuild-jupyter-cache/action.ymlextra-argsdefault, which said an explicit''would drop-W. It now says why the default is spelled out: the failure issue's repro commands are written from itdocs/dev/TESTING.mdbuild-lectures' row covers the two jobsCHANGELOG.md### Addedfor the engine and### Changedforextra-args' default, under[Unreleased]Outside my usual scope, with the organiser's OK: the comment in
build-jupyter-cache/action.yml, which became false, andbjc-alert/test.cjs, whose check would otherwise go red: it compared the two actions' declaredextra-argsdefaults, and build-lectures' is now empty. Neither changes whatbuild-jupyter-cachedoes.The harness jobs
build-engine-inputsruns the action 21 times against a stand-inmystthat records its folder, arguments,NODE_OPTIONSandBASE_URL, and writes what a build would, or what a failure leaves:html,pdflatexandjupyterpass, each runningbuild <flag> --execute --strictinsource-dir, withNODE_OPTIONSset and a step'sBASE_URLreachingmyst, the rightbuild-path, and an emptyerror-output-count. The records show the command lines only:--strictdoes nothing on the exports (build-lectures on mystmd: fail on execution errors inpdflatexandjupyterbuilds, and on error outputs in every build #364);index.html(with thehtmlcase's still there), anError fetchingline for one of the site's own pages, no export, a listed export not written (with thejupytercase's still there), andmystexiting 1;Error fetchingline for an external address, as--check-linksgives for a dead link, passes: only myst's own content server,http://localhost:<port>, serves the site's pages;mystfor nomystonPATH, amystwith no--ipynb, another builder,html-copy-pdf,html-copy-notebooksgiven asTrue, anoutput-dir, asource-dirwith nomyst.yml,-W --keep-going,engine: mystandengine: bogus;jb,jb1by default, and withengineandextra-argsboth empty, runsjb build harness-jb --path-output . -n -W --keep-going, the command before this change.build-mystmdis a realhtmlbuild inghcr.io/quantecon/quantecon-build:latest, as root, with upstream[email protected]from npm (one package) and thebook-themetemplate pinned by commit and cached, somystfetches no template. The executed cell's output is on its page, and a copy with a cell that raises fails the step: its traceback is in the page's content, and no site was written. Running as root in the image exercises both container settings: without them Jupyter does not start, which--strictfails, and the pages fail to render. PDF and notebooks are covered by the stand-in only: a real--pdffetches a LaTeX template, and--ipynbneeds the fork.They fail on the code before this change.
scratch/337-engine-redheldmain'sbuild-lectures(3b70eda), these fixtures and a throwaway workflow with the two jobs as they are here, without the gate. In run 46139194026 both failed, each case for the expected reason:build-engine-inputs, the runner warnedUnexpected input(s) 'engine'and the action ranjb build, so 16 of the 17 mystmd cases failed, each showing the stand-injbran wheremystshould have, as inran with [build harness-myst --path-output . -n -W --keep-going], expected [build --html --execute --strict]. Every input that is now refused went through.no-mystfails either way;jb1passed: its command is the same;jb1-emptyfailed withran with [build harness-jb --path-output . -n]: onmainan explicitextra-args: ''drops-W, which is the### Changedentry;build-mystmdfailed in "Build the site", wherejb buildfound no_config.ymlin the mystmd project.scratch/337-engine-green, this branch plus the same workflow, passed both jobs in run 46139197018. There, in the lean image as root,myst1.13.0 built the site with the cell's output on its page, and the raising cell's build ended with "Site has 1 error and 0 warning, stopping build". An earlier pair, 46138604935 and 46138623247, gave the same verdicts. The red one also showed that the assertion step stopped at its first failing case underset -e, so it now reports each one. Both branches are deleted.What I checked
mainand QuantEcon/lectures, and the mystmd CLI's source at the fork's39cda14, upstream 1.13.0 and 1.14.0. It found the command alone was not enough (the table above), and that--ipynbis the fork's. Every caller ofbuild-lectures@in the QuantEcon organisation (lecture-dp, QuantEcon/lectures, the canary, test-lecture-theme-sphinx,build-jupyter-cache) passes neitherenginenorextra-args: '', so none changes.mystover 19 cases, and the first step on jb1 with an empty, explicit, whitespace-only and two-lineextra-args.bjc-alert's test, run locally with the harness's own Python: it passes against this branch and againstmain'sbuild-lectures, and fails, naming build-lectures' value, when the jb1 default in the check step is changed.generate-docs.py --check --check-examples --actionlint(actionlint 1.7.12): the generated docs are current (24 files), and the 21 complete workflows in the docs, the new mystmd example among them, pass actionlint with shellcheck.actionlintandscripts/lint-shell.py: clean. shellcheck on the stand-ins: clean.What to watch after merge
jb build lectures --path-output . -n -W --keep-going, for publish.yml's three builds and ci.yml's. That is the canary's whole part: there is no mystmd canary for now.build-mystmdpulls the lean image and installs mystmd from npm on each run. If npm or the image pull is unavailable, it goes red with no change here. It needsMYSTMD_VERSIONandBOOK_THEME_SHAbumped together, by hand.Not in this PR
pdflatexandjupyterbuilds on mystmd, and error outputs on every builder: build-lectures on mystmd: fail on execution errors inpdflatexandjupyterbuilds, and on error outputs in every build #364.engine == mystmd, so it adds its command, and itsjupyterbuilder would be refused, as upstream has no--ipynb.build-jupyter-cachebuilds with jb1 only. A mystmd cache comes with the design note's item 3, when a site wants the cache actions.link-stylefor the preview actions, which follows this (preview actions: a preview key, a link style and a toc, so several products can preview on one pull request #336).Closes #337
🤖 Generated with Claude Code
https://claude.ai/code/session_01WT8bMaCAew38BRvFFUUn3G