Skip to content

[doc-only] Preserve shared docs inventories during release deploys - #3521

Merged
rwgk merged 5 commits into
mainfrom
rwgk/preserve-shared-docs-inventory
Nov 25, 2026
Merged

rwgk merged 5 commits into
mainfrom
rwgk/preserve-shared-docs-inventory

Conversation

@rwgk

@rwgk rwgk commented Nov 21, 2026 •

Copy link
Copy Markdown
Contributor

— codex on behalf of Ralf —

Description

The CUDA 12.9.11 bindings deployment replaced the shared objects.inv with the release inventory while the shared latest/ pages still described CUDA 13. This long-standing bug was easy to miss because a subsequent main deployment restores the shared inventories. This PR prevents that mismatch after a release.

The two shared inventories on gh-pages are:

  • docs/objects.inv for the cuda-python metapackage
  • docs/cuda-bindings/objects.inv for cuda-bindings

Both docs build paths stage their output under artifacts/docs/. After either path finishes, release staging omits latest/, the selector files, and objects.inv at each staged component root. Versioned pages and their inventories stay in the payload. The deployment overlays the staged files on gh-pages, preserving the shared files published by main.

Closes #3518.

While working on this fix, we identified opportunities to simplify how CI builds and stages docs. We’re tracking that refactoring separately in #3600 so this PR stays focused on the inventory fix.

Validation

  • Ran the inline Bash extracted from the final workflow against all four individual component layouts and the aggregate layout. Each staged payload matched the previous helper’s output byte for byte. Each simulated Pages overlay preserved the shared files and copied the versioned files. Removing the inventory exclusion reproduced the overwrite in all five cases.
  • Bash syntax, ShellCheck, and focused pre-commit passed on the inline change.
  • The earlier hosted 12.9.11 rehearsal exercised the same exclusions when they were implemented in the standalone helper. Hosted rehearsal

Checklist

  • I have read the Contributing Guidelines.
  • Existing checks and local overlay validation cover this change.
  • The documentation is up to date with these changes.

@copy-pr-bot

copy-pr-bot Bot commented Nov 21, 2026

Copy link
Copy Markdown
Contributor

This pull request requires additional validation before any workflows can run on NVIDIA's runners.

Pull request vetters can view their responsibilities here.

Contributors can view more details about this message here.

@github-actions github-actions Bot added the CI/CD CI/CD infrastructure label Nov 21, 2026
@rwgk rwgk self-assigned this Nov 21, 2026
@rwgk rwgk added documentation Improvements or additions to documentation bug Something isn't working labels Nov 21, 2026
@rwgk rwgk added this to the CI milestone Nov 21, 2026
@rwgk

rwgk commented Nov 21, 2026

Copy link
Copy Markdown
Contributor Author

/ok to test bfce548

@rwgk

rwgk commented Nov 21, 2026

Copy link
Copy Markdown
Contributor Author

— codex GPT-6 on behalf of Ralf —

The 12.9.11 bindings release dry run passed at PR head bfce548. It resolved the unchanged v12.9.11 tag and its successful tag CI run automatically. The Pages deployment branch input was blank.

I downloaded the docs artifact and checked the same overlay that previously clobbered the shared inventory. The payload contains the versioned release note and a readable versioned Sphinx inventory with 4,078 entries. The shared objects.inv, latest/, and both selector files are absent from the payload. A local overlay on the pre-release Pages snapshot installed the versioned note and inventory and preserved the shared inventory, selectors, redirect page, and sampled latest files byte for byte.

The focused regression fails on the shared inventory overwrite with the exclusion omitted and passes with it in place, for both component and aggregate payloads. All 429 CI-tool tests and all-files pre-commit passed locally.

@github-actions

github-actions Bot commented Nov 21, 2026 •

Copy link
Copy Markdown
Contributor
Doc Preview CI
Preview removed because the pull request was closed or merged.

@rwgk
rwgk marked this pull request as ready for review November 21, 2026 03:02
@coderabbitai

coderabbitai Bot commented Nov 21, 2026 •

Copy link
Copy Markdown

Explain Change →

Important

Review skipped

Review was skipped as selected files did not have any reviewable changes.

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 96de201 and 65376e8.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review

No actionable comments were generated in the recent review.

Summary

Summary by CodeRabbit

  • Chores
    • Release documentation builds now remove latest, version metadata, and search index files from the documentation output, including the CUDA Bindings, CUDA Core, and CUDA Pathfinder sections.

Changes

The release workflow now removes shared documentation paths after assembling release artifacts. It removes latest, nv-versions.json, versions.json, and objects.inv from the documentation root and three component roots.

Release documentation

Layer / File(s) Summary
Filter staged release payloads
.github/workflows/build-docs.yml
The all-docs and component-docs release branches no longer clean their build output before copying it. A release-only step removes shared paths from the assembled artifacts.

Assessment against linked issues

Objective Addressed Explanation
Preserve the shared root inventory and selectors in release deployments while retaining versioned inventories; allow main/latest deployments to update the shared inventory [#3518] ✅

Suggested reviewers: leofang, andy-jost

Change: Bug fix · Severity of issue fixed: Medium

Merge Risk: Minimal · previous review 96de2

Release deploys should no longer overwrite the shared docs inventory, selectors, or latest pages, while versioned pages and inventories are still published. No actionable merge-blocking risk was found.

Architecture risk: Low · up to 96de2

The changed surface does not map to a changed system, dependency edge, entrypoint, or external dependency.

Changed systems: None identified.

Architecture concerns
No architecture-level concerns identified.

Review details

Before / after behavior

  • observed — Modified behavior in .github/workflows/build-docs.yml: The all-docs release branch no longer removes build/html/latest, nv-versions.json, or versions.json before copying its output into the artifacts directory.
  • observed — Modified behavior in .github/workflows/build-docs.yml: The component-docs release branch no longer removes build/html/latest, nv-versions.json, or versions.json before copying its output into the artifacts directory.
  • observed — Modified behavior in .github/workflows/build-docs.yml: Adds a release-only cleanup step after docs are assembled in artifacts/docs: it removes latest and the three shared files nv-versions.json, versions.json, and objects.inv from the docs root and the cuda-bindings, cuda-core, and cuda-pathfinder roots.
- [ ] Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 21b9f33 and 96de201.

Files selected for processing: 1

  • .github/workflows/build-docs.yml

Included review availability: This review used your included allowance. Your plan provides up to 12 included reviews per hour; 11 remain after this review.

@rwgk

rwgk commented Nov 25, 2026

Copy link
Copy Markdown
Contributor Author

To understand the impact of the bug fixed by this PR, I asked codex "What would happen if we deleted docs/objects.inv from gh-pages?"

codex GPT-6.2-Sol ultra:

Deleting docs/objects.inv from gh-pages would make the top-level inventory URL return 404. The rendered docs and version pickers would keep working.

The potential breakage is in future Sphinx builds. If another project configures intersphinx with https://nvidia.github.io/cuda-python/ as its base and leaves the inventory unspecified, Sphinx fetches that exact file. Losing it could leave cross-references unresolved or fail a build that treats warnings as errors. Sphinx configuration

I found no confirmed consumer of that exact file in CUDA Python or the public configurations I checked. For example, trtutils uses the metapackage inventory under latest/, and RMM uses the bindings inventory under cuda-bindings/. Both would keep working. trtutils configuration · RMM configuration

With the current build script, the next successful main docs deployment would recreate the top-level copy. Build script

@rwgk

rwgk commented Nov 25, 2026

Copy link
Copy Markdown
Contributor Author

/ok to test 65376e8

@rwgk
rwgk requested a review from mdboom November 25, 2026 19:38
@rwgk
rwgk enabled auto-merge (squash) November 25, 2026 19:39

@juenglin juenglin left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor findings:

  • The PR description talks about "two shared inventories", but the cleanup also covers cuda-core and cuda-pathfinder. Those had the same latent bug, for example a patch release built from an older tag. Mentioning this would make the scope clearer.
  • The cleanup also runs for tag CI builds in ci.yml, which have is-release: true and deploy-docs: false. Those builds only upload an inspection artifact, so this is harmless.

@rwgk
rwgk merged commit d1fc8a8 into main Nov 25, 2026
39 checks passed
@rwgk
rwgk deleted the rwgk/preserve-shared-docs-inventory branch November 25, 2026 23:31
@rwgk rwgk mentioned this pull request Nov 26, 2026
3 tasks done
github-actions Bot pushed a commit that referenced this pull request Nov 26, 2026
Removed preview folders for the following PRs:
- PR #3521
- PR #3526
- PR #3547
- PR #3548
- PR #3549
- PR #3552
- PR #3589
- PR #3590
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working CI/CD CI/CD infrastructure documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[DOC]: Preserve shared Sphinx inventories during release deployments

2 participants