Skip to content

Book CI builds without -W, so a broken cross-reference publishes silently #732

Closed

Description

@vyncint

.github/workflows/book.yml builds the site with:

sphinx-build -b html cuda-oxide-book cuda-oxide-book/_build/html

No -W, so every Sphinx warning is advisory and the job exits 0 regardless. The
book is the only documentation surface without warnings-as-errors — the Rust
docs gate builds under RUSTDOCFLAGS="-D warnings", and docs.yml says why:

Keeps broken intra-doc links and uncompilable doc examples from accumulating
silently.

The book has no equivalent, so a broken cross-reference, a malformed directive,
or a page dropped out of a toctree is published rather than reported.

Demonstrated by appending one dangling link to index.md:

$ sphinx-build -b html cuda-oxide-book _build          # what CI runs today
build succeeded.
exit 0                                                  # <- publishes

$ sphinx-build -W --keep-going -b html cuda-oxide-book _build
WARNING: 'myst' cross-reference target not found: 'does-not-exist.md' [myst.xref_missing]
exit 1

The book is currently clean, so turning this on costs nothing today:
sphinx-build -W --keep-going exits 0 on main with zero warnings (checked with
Sphinx 9.1.0 against cuda-oxide-book/requirements.txt).

One caveat worth stating: requirements.txt uses >= constraints, so CI floats
to the newest Sphinx. A future release that adds a deprecation warning would then
fail the book build. --keep-going at least surfaces all of them in one run. If
that trade is unwanted, pinning the Sphinx major would remove it.

Activity

  1. added
    build-related
    documentation
    on Aug 10, 2026
  2. added a commit that references this issue on Aug 10, 2026
    8e98dfd
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    build-relateddocumentation

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions