fix: resolve build.warnings gate fallout from #5891 migration#5960
Merged
Conversation
Allow the linker_messages rustc lint via [workspace.lints.rust] so plain cargo build/run succeeds on macOS/arm64, where build.warnings = "deny" (.cargo/config.toml, #5891) unconditionally denies Apple ld's eh_frame section-size warning. Fix 39 pre-existing rustdoc private_intra_doc_links/ redundant_explicit_links warnings across 11 crates, surfaced by the same migration widening the local rustdoc pre-commit gate beyond what it enforced pre-#5891. Tighten ci.yml's rustdoc job RUSTDOCFLAGS to deny both lint classes explicitly so the cleanup has a standing regression guardrail in CI and local dev, not just a one-time sweep. Closes #5894, #5895
bug-ops
enabled auto-merge (squash)
July 10, 2026 22:08
4 tasks
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.
Summary
linker_messagesrustc lint via[workspace.lints.rust]so a plaincargo build/cargo runsucceeds on macOS/arm64, where repo-widebuild.warnings = "deny"(.cargo/config.toml, ci: migrate lint-warning gate from RUSTFLAGS to build.warnings #5891) unconditionally denied Appleld's__eh_frame section too largewarning.private_intra_doc_links/redundant_explicit_linkswarnings across 11 crates, surfaced by the same migration widening the documented local rustdoc gate beyond what it enforced pre-ci: migrate lint-warning gate from RUSTFLAGS to build.warnings #5891 (the earlier count of 37/10 crates was masked by sccache;zeph-acp's 3 sites were missing)..github/workflows/ci.yml'srustdocjobRUSTDOCFLAGSto explicitly deny both fixed lint classes (previously onlyrustdoc::broken_intra_doc_linkswas denied, relying onbuild.warningsfor the other two — which the job's ownCARGO_BUILD_WARNINGS: allowoverride disabled), so the cleanup has a standing regression guardrail in CI and local dev instead of a one-time sweep.Root cause
.cargo/config.toml'sbuild.warnings = "deny"applies to everycargoinvocation and is wider than the oldRUSTFLAGS/RUSTDOCFLAGScombination it replaced — it independently denies all local-package rustdoc lints and all linker diagnostics, not just what the documented gate commands explicitly named. Cargo 1.97'sbuild.warningsis a plain string, not a table — no category-level granularity exists, so both fixes use Rust's own per-lint suppression/denial mechanism underneath it instead.Note on governance docs
.claude/rules/branching.mdand.claude/CLAUDE.mdwere also updated locally to prefix the rustdoc-gate command withCARGO_BUILD_WARNINGS=allowplus the two new--denyflags, matching this PR's CI change exactly. These files are not git-tracked in this repository (excluded via the repo owner's global~/.gitignore_global, confirmed never in this repo's git history), so they do not appear in this diff and will not ship to other clones via git. The repo owner should apply the equivalent change to their local copies (and to~/.claude/CLAUDE.md, their global config) manually.Test plan
cargo build --features fullsucceeds with zero env var overrides on macOS/arm64build.warnings=denystill fails the build (fix is scoped precisely tolinker_messages, not a blanket allow)RUSTFLAGS="-D warnings" RUSTDOCFLAGS="--deny rustdoc::broken_intra_doc_links --deny rustdoc::private_intra_doc_links --deny rustdoc::redundant_explicit_links" cargo doc --no-deps --workspace --features "desktop,ide,server,chat,pdf,scheduler"exits 0 with no env override, proving all 39 sites are genuinely fixed, not papered overRUSTDOCFLAGSguardrail actually catches the regression, then reverted cleanlycargo test --doc --workspace --features "desktop,ide,server,chat,pdf,scheduler"— doc-test pass count unchanged, all edits are narrative-onlycargo nextest run --config-file .github/nextest.toml --workspace --features "desktop,ide,server,chat,pdf,scheduler" --lib --bins— 12630 passed, 0 failedcargo +nightly fmt --checkandcargo clippy --profile ci --workspace --all-targets --features "desktop,ide,server,chat,pdf,scheduler,testing" -- -D warnings— cleanfy linton the modifiedci.ymlblock — 0 new errorsCloses #5894, closes #5895