You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
docs build does not catch nested inline RST markup (renders as literal backticks, sphinx exits 0) #30
Nested inline markup is invalid reStructuredText, renders as literal
backticks in the built HTML, and nothing in the docs build catches it. sphinx-build exits 0 with no warning, so the only thing standing between this
class and a published page is whoever happens to look at the rendered output.
It occurred three times in a single session while writing #29, each time in
prose that read perfectly in the source:
**Supplying ``sample_col`` multiplies the cost by the gene count.**
**The ``dask`` path wins on every instrument**
**The ``dask``-less path is a different bargain ...**
All three render with the backticks visible:
<p><strong>The ``dask`` path wins on every instrument</strong>, and that is ...
Three instances of one shape is a missing check rather than three mistakes.
Why it is easy to write and hard to see
The rule — inline markup cannot nest — is not one most people hold while
writing, and the source reads exactly as intended. A literal inside a bold span
is the natural way to write "the dask path wins" when the emphasis
belongs to the whole clause. Docutils does not warn: it simply stops treating
the inner markers as markup.
It is also invisible to every check we already run. sphinx-build -b html is
clean, the page builds, links resolve, and the only symptom is two stray
backticks in a paragraph nobody re-reads after the first review.
How it was caught, and the suggestion
By scanning the built HTML for markup that should never survive rendering —
unrendered literals, directive lines, unresolved roles:
Zero is the only acceptable count, and it found all three instances plus a :ref: accidentally written inside a code-block comment, where roles are not
interpreted.
Worth making a docs-build check rather than an agent's habit — a few lines in docs/ run after sphinx-build, failing on a non-zero count. It needs no
knowledge of the RST rules; it just asserts that nothing that is supposed to be
markup survived as text.
A source-side linter (doc8, rstcheck) is the other option, but the HTML scan
is strictly better here: it catches the code-block-comment case and anything
else that fails to render, without needing a rule per construct.
Scope
Documentation infrastructure only; no runtime effect. Filed separately from #29
rather than folded into it, since it is about the build rather than about that
change.
Activity
fix(docs,tests): remediate the skeptic pass on #29 (F1-F6)
docs: fail the build when RST markup survives into the HTML (#30)
docs(changelog): 0.9.0 entries for #23, #28/#33, #30, #31 and the 200…
test(docs): readable parametrize ids for the #30 leak cases
fix(#30, #28): catch code-in-link leaks; ignore a repository that is …
docs(changelog): correct the #30 counts; note the vendored-tree prove…