Commit 4c092ed
Build strict: enable -W in ci.yml and publish.yml (#14)
* Build strict: enable -W in ci.yml and publish.yml
Both builds carried `# TODO: Re-enable -W flag once all lectures are
translated and warnings are resolved`. The precondition is already met:
this edition has 26 of 26 lectures with a `_toc.yml` identical to
source, so there are no untranslated lectures left to produce dangling
cross-references.
The case for strict is stronger than build hygiene. A translated
edition carries the same code as its English source, so a warning here
that does not appear upstream is evidence of a translation defect, not
noise — which makes -W a translation-quality signal.
It is also the last line of defence against a class of silent engine
corruption. QuantEcon/action-translation#118 (a resync wrapped an
entire 1,465-line document in a code fence and mis-derived its title
from a Python tuple-unpacking line) and #119 (a `{raw} jupyter`
directive argument stripped to `{raw}`) both reported success at run
time, looked plausible in review, and surfaced weeks later only
because a downstream repo built with -n -W. Without the flag this
edition would merge that class of damage green.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
* Add the missing _admonition/gpu.md shared include
Three lectures — autodiff, jax_intro and numpy_vs_numba_vs_jax — carry
`{include} _admonition/gpu.md`, but the file was never seeded into this
edition. Every other edition has it; this one did not:
lecture-python-programming lectures/_admonition/gpu.md
lecture-python-programming.fa lectures/_admonition/gpu.md
lecture-python-programming.zh-cn lectures/_admonition/gpu.md
lecture-python-programming.fr (absent)
So those three lectures have been building with a broken include and
publishing without the GPU admonition. The build reported success
throughout, because this repo built without -W.
Found by enabling -W in the same PR, which is the argument for the flag
in one example: three CRITICAL "file not found" directive errors that
had been live and invisible. This is the shared-asset class described in
QuantEcon/action-translation#117 — sync moves lecture files, so an asset
that lives outside that set is never carried across.
Translated per the French glossary (Lecture -> Cours) and typeset with
U+00A0 before the colon and inside the guillemets, matching the
convention applyTypography() enforces for prose directives — admonition
is on its PROSE_DIRECTIVES list, so the file is in scope for it.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>1 parent 40df73d commit 4c092ed
3 files changed
Lines changed: 14 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
42 | 42 | | |
43 | 43 | | |
44 | 44 | | |
45 | | - | |
46 | | - | |
| 45 | + | |
47 | 46 | | |
48 | 47 | | |
49 | 48 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
56 | 56 | | |
57 | 57 | | |
58 | 58 | | |
59 | | - | |
60 | | - | |
| 59 | + | |
61 | 60 | | |
62 | 61 | | |
63 | 62 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
0 commit comments