Repository navigation
ci(book): bump mdbook to 0.5.4 and mdbook-i18n-helpers to 0.4.0; drop the onig_sys GCC 15 workaround - #1725
Merged
Conversation
The 0.3.6 helper's lockfile pinned onig_sys 69.8.1, whose vendored oniguruma predates its GCC 15 / C23 fix (HISTORY 2024-11-18, #312) and stopped compiling on ubuntu-latest (26.04). 36a9dec covered it with CFLAGS=-std=gnu17 on the install step; this moves both pins to the current lines and drops the override. Helpers 0.4.0 is installed with `--features syntect/regex-onig`, and that flag is the substance of the change. 0.4.0 switched syntect to the pure-Rust fancy-regex engine (google/mdbook-i18n-helpers#267), under which the shell / YAML / TOML grammars mis-walk consecutive `#` comments: a two-line run keeps only its first line, a three-line run its first and third (google/mdbook-i18n-helpers#321). Measured on this book with `--locked` alone: the pot loses 90 translated entries and eleven /ja/ pages fall back to English. With Oniguruma the pot is byte-identical (modulo POT-Creation-Date) to the 0.4.40 + 0.3.6 one. The feature's onig / onig_sys crates are absent from the published lockfile, so they resolve fresh under --locked (69.9.3 today) while every other dependency stays pinned. The two builds report the same --version, so the new utils/check-xgettext-backend.sh tells them apart by behaviour on a four-line book; `make book-pot` and the Pages workflow both run it before extracting anything. The workflow also asserts the Japanese tree exists and carries a known translation, since a missing or mis-built gettext preprocessor is `optional` and yields English pages under lang="ja" with no error. mdbook 0.5 resolves `-d` against the cwd rather than the book root, so the Japanese build in both the workflow and `make book-ja` now names big-code-analysis-book/book/ja in full; the former `-d book/ja` would have written to ./book/ja and shipped an artifact with no /ja/. Rendered output otherwise differs in two visible ways — 0.5's smart-punctuation default, and `\|` inside a table code span now rendering as `|` on /ja/ — while heading ids, fragment links and every fenced code block are unchanged in both languages (~/bca-evidence/1724/). GCC 15 compilation of onig_sys 69.9.3 is inferred from the oniguruma HISTORY entry, not reproduced locally (aarch64 host); the Pages workflow run on this change is the first real test. Refs #1724
`make book-po-update` with the new toolchain. The English book moved in ten commits since the 2026-10-21 refresh (4,230 insertions under big-code-analysis-book/src), and this is that drift: 2613 translated, 990 fuzzy, 309 untranslated, 203 obsolete. None of it is the toolchain — msgmerge against the 0.4.40 + 0.3.6 pot gives a byte-identical file (modulo POT-Creation-Date) — and the rendered /ja/ site is unchanged by it, since every entry msgmerge marked fuzzy had already stopped matching its paragraph and was falling back to English. Refs #1724
Owner
Author
|
The one thing I could not verify locally is now verified in CI. The with no |
7 tasks done
This branch was successfully deployed
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.
Closes #1724.
What
mdBook 0.4.40 + mdbook-i18n-helpers 0.3.6 → 0.5.4 + 0.4.0, in
pages.yml, theMakefilebook targets, theDockerfile, the deploy script anddocs/development/translations.mdtogether. The-std=gnu17CFLAGS override from 36a9dec is gone.Two commits: the toolchain bump, and a separate
make book-po-updaterefresh ofja.po(990 fuzzy / 309 new / 203 obsolete — ten commits of English doc drift since 2026-10-21, not toolchain churn;msgmergeagainst the old toolchain's pot yields a byte-identical file).The part the issue did not anticipate
Helpers 0.4.0's lockfile has no
onig_sysat all: upstream switched syntect to the pure-Rustfancy-regex(google/mdbook-i18n-helpers#267). That removes the GCC 15 problem, but under fancy-regex the shell/YAML/TOML grammars drop lines from consecutive#comment runs (google/mdbook-i18n-helpers#321, open):```bash/# a1/# a2/# a3# a1\n# a2\n# a3\n--locked(issue's plan)# a1\n,# a3\n—# a2dropped--locked --features syntect/regex-onig# a1\n# a2\n# a3\nOn this book the
--locked-only pot loses 90 translated entries and eleven/ja/pages fall back to English. With Oniguruma the pot is byte-identical (moduloPOT-Creation-Date) to the previous toolchain's. So the helper is installed with--features syntect/regex-onig; the twoonigcrates resolve fresh under--locked(69.9.3, which carries oniguruma's GCC 15 fix) while everything else stays pinned.Both builds report the same
--version, so newutils/check-xgettext-backend.shtells them apart behaviourally on a four-line book;make book-potand thebuild-bookjob both run it before extracting anything. Verified to reject the fancy build, a stub emitting two split entries, and a missing helper; to accept both Oniguruma builds.Other things 0.5 exposed
-dis now cwd-relative. The workflow's-d book/jawould have written to./book/jaand shipped a Pages artifact with no/ja/tree, silently. Fixed in the workflow andmake book-ja; the workflow now also asserts the/ja/tree exists and carries a known translation across its pages (a missing/mis-built gettext preprocessor isoptionaland yields English underlang="ja"with no error).book.tomlunchanged. 0 heading-id changes in either language; fragment-link breakage unchanged (3 en / 8 ja, pre-existing); 0 non-punctuation text differences in English. Visible deltas: 0.5'ssmart-punctuationdefault (kept), and\|inside table code spans now renders correctly on/ja/.Not verified locally
GCC 15 / C23 compilation of
onig_sys69.9.3 — host is aarch64/GCC 11, x86 emulation of rustup crashed. Inferred from the onigurumaHISTORYentry in the vendored tree. Thebuild mdBookjob on this PR is the first real test. If it fails, the fallback is a scopedCFLAGSoverride again; a tooling lockfile is not available tocargo install.Review
Three astra-review rounds plus one independent review (8 findings total, all fixed; round three clean).
make pre-commitgreen. Evidence (pots, fixture, both toolchains' en/ja builds, probe scripts):~/bca-evidence/1724/.