Skip to content

Pins sphinx<9 to fix sphinx-multiversion compatibility#5211

Merged
AntoineRichard merged 2 commits intoisaac-sim:developfrom
kellyguo11:fix/pin-sphinx-below-9
Apr 9, 2026
Merged

Pins sphinx<9 to fix sphinx-multiversion compatibility#5211
AntoineRichard merged 2 commits intoisaac-sim:developfrom
kellyguo11:fix/pin-sphinx-below-9

Conversation

@kellyguo11
Copy link
Copy Markdown
Contributor

Description

Sphinx 9.0 changed Config.read() to use keyword-only parameters (overrides and tags), breaking sphinx-multiversion==0.2.4 which passes arguments positionally. This causes the multi-version docs CI build to fail with:

TypeError: Config.read() takes 2 positional arguments but 3 were given

The develop branch has sphinx>=7.0 with no upper bound, so CI (Python 3.12) resolves to Sphinx 9.1.0 which introduced the breaking API change.

Fix

Pin sphinx>=7.0,<9 in docs/requirements.txt to keep Sphinx on the 8.x line until sphinx-multiversion is updated or replaced with a maintained fork.

Type of change

  • Bug fix (non-breaking change which fixes an issue)

Sphinx 9.0 changed Config.read() to use keyword-only parameters,
breaking sphinx-multiversion==0.2.4 which passes arguments positionally.
This causes the multi-version docs build to fail with:
  TypeError: Config.read() takes 2 positional arguments but 3 were given

Pin sphinx<9 until sphinx-multiversion is updated or replaced.
@github-actions github-actions bot added bug Something isn't working documentation Improvements or additions to documentation labels Apr 9, 2026
@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps bot commented Apr 9, 2026

Greptile Summary

This PR pins sphinx to >=7.0,<9 in docs/requirements.txt to prevent sphinx-multiversion==0.2.4 from breaking on Sphinx 9.x, which changed Config.read() to keyword-only parameters. The fix is minimal and correct for the stated issue.

Confidence Score: 5/5

Safe to merge — single-line constraint tightening with no logic changes.

The change is a minimal, well-scoped version pin that directly addresses a documented CI breakage. No logic, API, or behavioral changes are involved, and all remaining considerations are informational.

No files require special attention.

Vulnerabilities

No security concerns identified.

Important Files Changed

Filename Overview
docs/requirements.txt Pins sphinx to >=7.0,<9 to keep the multi-version docs build on the 8.x line, avoiding the Sphinx 9.0 breaking API change that broke sphinx-multiversion==0.2.4.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[CI Docs Build] --> B{Resolve sphinx version}
    B -->|Before fix: sphinx>=7.0| C[Resolves to Sphinx 9.1.0]
    B -->|After fix: sphinx>=7.0,<9| D[Resolves to Sphinx 8.x]
    C --> E["sphinx-multiversion calls\nConfig.read(app, config, overrides)\npositionally"]
    D --> F["sphinx-multiversion calls\nConfig.read(app, config, overrides)\npositionally"]
    E --> G["TypeError: Config.read() takes\n2 positional arguments but 3 were given"]
    F --> H["Build succeeds ✓"]
    style G fill:#f66,color:#fff
    style H fill:#6a6,color:#fff
Loading

Reviews (1): Last reviewed commit: "fix(docs): pin sphinx<9 to fix sphinx-mu..." | Re-trigger Greptile

@kellyguo11 kellyguo11 changed the title fix(docs): pin sphinx<9 to fix sphinx-multiversion compatibility Pins sphinx<9 to fix sphinx-multiversion compatibility Apr 9, 2026
Copy link
Copy Markdown

@isaaclab-review-bot isaaclab-review-bot bot left a comment

Choose a reason for hiding this comment

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

LGTM — minimal, well-scoped fix for a clear CI breakage.

What it does: Pins sphinx>=7.0,<9 to keep the docs build on the 8.x line, avoiding the Sphinx 9.0 breaking change where Config.read() switched to keyword-only parameters (breaking the positional call in sphinx-multiversion==0.2.4).

One note for the maintainers: sphinx-multiversion last released in August 2020 and appears unmaintained. This pin is the right short-term fix, but it'd be worth tracking a migration to a maintained fork (e.g., sphinx-multiversion-contrib or sphinxcontrib-versioning) before you need Sphinx 9+ features. A tracking issue would help make sure this doesn't get forgotten.

@AntoineRichard AntoineRichard merged commit 78e765b into isaac-sim:develop Apr 9, 2026
8 checks passed
AntoineRichard added a commit that referenced this pull request Apr 10, 2026
sphinx-multiversion 0.2.4 passes positional arguments to Config.read()
which became keyword-only in Sphinx 9.0, breaking multi-version doc
builds. This is the same fix as #5211 on develop, applied to main.
mmichelis pushed a commit to mmichelis/IsaacLab that referenced this pull request Apr 10, 2026
## Description

Sphinx 9.0 changed `Config.read()` to use keyword-only parameters
(`overrides` and `tags`), breaking `sphinx-multiversion==0.2.4` which
passes arguments positionally. This causes the multi-version docs CI
build to fail with:

```
TypeError: Config.read() takes 2 positional arguments but 3 were given
```

The `develop` branch has `sphinx>=7.0` with no upper bound, so CI
(Python 3.12) resolves to Sphinx 9.1.0 which introduced the breaking API
change.

## Fix

Pin `sphinx>=7.0,<9` in `docs/requirements.txt` to keep Sphinx on the
8.x line until `sphinx-multiversion` is updated or replaced with a
maintained fork.

## Type of change

- [x] Bug fix (non-breaking change which fixes an issue)

Co-authored-by: Kelly Guo <kellyguo11@users.noreply.github.com>
Co-authored-by: Antoine RICHARD <antoiner@nvidia.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants