Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions docs/requirements-docs.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
sphinx==7.3.7
furo==2024.5.6
sphinx-autobuild==2024.4.16
sphinx==9.1.0

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Verify Sphinx configuration and check for other deprecated settings

# Check if autodoc_default_flags is still used
rg -n 'autodoc_default_flags' docs/

# Check for other common deprecated Sphinx settings removed in 9.0
rg -n 'add_stylesheet|add_javascript|autodoc_default_flags' docs/

# List all Sphinx configuration files for manual review
fd -e py -e rst conf docs/

Repository: DagsHub/client

Length of output: 215


🌐 Web query:

Sphinx 9.0 breaking changes migration guide

💡 Result:

Sphinx 9.0 (released Nov 30, 2025): breaking/incompatible changes & how to migrate

1) Extension API: create_source_parser() signature changed

  • Breaking change: SphinxComponentRegistry.create_source_parser() no longer receives app; it now takes config and env.
  • Migration: Update any custom source-parser registration code to match the new signature. (sphinx-doc.org)

2) Source file decoding is now strict

  • Breaking change: Non-decodable bytes in source files now raise an error (previously replaced with ? plus a warning).
  • Migration: Ensure sources are valid text (typically UTF-8) and fix/convert any files with invalid bytes. (sphinx-doc.org)

3) sphinx.ext.autodoc rewrite (edge-case incompatibilities)

  • Breaking change: autodoc was substantially rewritten, and extensions relying on autodoc internals may break in edge cases.
  • Migration options:
    • Prefer updating your extension(s) to current autodoc behavior.
    • If you need a temporary bridge, set autodoc_use_legacy_class_based = True to use the pre-9.0 implementation. (sphinx-doc.org)

Deprecations you should address during the upgrade (to avoid future breaks)

4) Remaining public .app attributes deprecated

  • Includes builder.app, env.app, events.app, SphinxTransform.app.
  • Migration: Stop accessing *.app on these objects; use supported APIs/objects instead. (sphinx-doc.org)

5) Parser API deprecations

  • Parser.set_application() deprecated
  • Parser.config and Parser.env attributes deprecated
  • Migration: Update custom parsers to avoid these and follow the newer parser integration patterns. (sphinx-doc.org)

6) Non‑UTF‑8 source encodings deprecated (planned removal in Sphinx 10)

  • Migration: Move projects to UTF‑8 source files now. (sphinx-doc.org)

7) sphinx.io deprecated (planned removal in Sphinx 10)

  • Sphinx has moved to standard Python I/O internally.
  • Migration: Stop importing/depending on sphinx.io classes. (sphinx-doc.org)

8) “tags” kwarg will be required in Sphinx 11 for certain environment methods

  • From Sphinx 9 onward it can be passed optionally; Sphinx 11 will require it for:
    • sphinx.environment.adapters.toctree.global_toctree_for_doc()
    • sphinx.environment.BuildEnvironment.get_and_resolve_doctree()
  • Migration: Start passing tags= where you call these methods. (sphinx-doc.org)

If you share your current Sphinx version (8.x? earlier?) and any custom extensions you use, I can turn this into a step-by-step upgrade checklist for your specific project.

Citations:


🌐 Web query:

autodoc_default_flags Sphinx removed deprecated when

💡 Result:

autodoc_default_flags was deprecated in Sphinx 1.8 (released Sep 13, 2018) in favor of autodoc_default_options.[1]

It was slated to be removed in Sphinx 4.0 (the Sphinx autodoc code notes “this option will be removed in Sphinx-4.0”).[2] Sphinx 4.0.0 was released May 9, 2021, so that’s when the removal happened.[3]

Sources: [1] (sphinx-doc.org) [2] (jinjaapidoc.readthedocs.io) [3] (sphinx-doc.org)

Citations:


🏁 Script executed:

# Get the previous version of Sphinx from the requirements file
git diff HEAD~1 docs/requirements-docs.txt | head -20

Repository: DagsHub/client

Length of output: 244


CRITICAL: autodoc_default_flags is incompatible with Sphinx 9.1.0 — documentation build will fail.

The upgrade to Sphinx 9.1.0 requires fixing a deprecated configuration. The setting autodoc_default_flags was removed in Sphinx 4.0 and has been non-functional for years. The configuration file docs/source/conf.py (line 68) still uses this setting, which will cause the documentation build to fail with Sphinx 9.1.0.

Replace autodoc_default_flags with autodoc_default_options (a dictionary):

# In docs/source/conf.py, replace line 68:
- autodoc_default_flags = ["inherited-members"]
+ autodoc_default_options = {
+     "inherited-members": True,
+ }

Verify the documentation builds successfully after this change.

furo==2025.12.19
sphinx-autobuild==2025.8.25
sphinx-copybutton==0.5.2
sphinx-sitemap==2.6.0
sphinx-click==5.0.1
sphinx-autodoc-typehints==2.3.0
sphinx-sitemap==2.9.0
sphinx-click==6.2.0
sphinx-autodoc-typehints==3.9.8
14 changes: 7 additions & 7 deletions requirements-dev.txt
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
setuptools==80.9.0
pytest==8.3.5
setuptools==82.0.1
pytest==9.0.2

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Check for pytest configuration and common patterns that may break

# Check pytest configuration files for deprecated settings
fd -e ini -e cfg -e toml setup.cfg pytest.ini pyproject.toml tox.ini | xargs cat

# Search for deprecated pytest imports or patterns
rg -n 'pytest\.(yield_fixture|fixture.*\(scope.*\)|warns.*None)' --type py -g '!venv' -g '!.tox'

# Check for --strict usage (removed in pytest 9)
rg -n '\-\-strict[^-]' --type py --type toml --type ini

Repository: DagsHub/client

Length of output: 298


🌐 Web query:

pytest 9.0 breaking changes migration guide

💡 Result:

pytest 9.0: breaking changes + migration checklist

1) Python support

  • Python 3.9 is no longer supported → upgrade to Python ≥ 3.10. [1]

2) “Removed-in-9” deprecations now fail

  • PytestRemovedIn9Warning is now an error by default in pytest 9.0, so code/plugins still using APIs slated for removal will start failing. [2]
    • Temporary stopgap (only for the 9.0.x series): add to pytest.ini:
      • filterwarnings = ignore::pytest.PytestRemovedIn9Warning [2]

3) Plugin hook signature updates (py.path.local → pathlib.Path)

If you implement these hooks, update signatures to the new pathlib.Path params (old py.path.local params were deprecated and are now effectively enforced by the “RemovedIn9” errors): [3]

  • pytest_ignore_collect(collection_path: pathlib.Path) (replaces old path)
  • pytest_collect_file(file_path: pathlib.Path)
  • pytest_pycollect_makemodule(module_path: pathlib.Path)
  • pytest_report_header(start_path: pathlib.Path) (replaces old startdir)
  • pytest_report_collectionfinish(start_path: pathlib.Path) (replaces old startdir) [3]

4) pytest.importorskip() behavior tightening

  • In pytest 9.0, the previous warning about ImportError vs ModuleNotFoundError becomes an error unless you pass exc_type explicitly.
    • Fix: pass exc_type=ImportError if you really want to treat any ImportError as “skip”. [4]

5) Command-line collection semantics changed for overlapping/duplicate paths

  • pytest a/ a/b and pytest a/b a/ now behave like pytest a (prefix wins).
  • pytest x.py x.py now behaves like pytest x.py (no longer runs twice).
  • Use --keep-duplicates if you relied on the old behavior. [1]

6) Smaller but potentially breaking internals/behavior

  • config.args (non-public) now contains only strings (no pathlib.Path instances). [1]
  • If you rely on the private config.inicfg, it was broken in 9.0.0 and later restored via a compatibility shim in 9.0.2—but it’s slated for deprecation/removal (avoid using it). [5]

Primary docs to review while migrating

  • pytest 9.0.0 changelog (breaking changes + removals) [1]
  • Deprecations and removals reference (what the “RemovedIn9” errors are pointing at) [4]

Sources

  1. pytest changelog (9.0.0 “Removals and backward incompatible breaking changes”). [1]
  2. pytest changelog (PytestRemovedIn9Warning now errors by default + temporary filterwarnings stopgap). [2]
  3. pytest docs: py.path.local hook args replaced with pathlib.Path. [3]
  4. pytest docs: pytest.importorskip() warning→error timeline in 9.0. [4]
  5. pytest changelog (9.0.2 note about config.inicfg compatibility shim + deprecation/removal plan). [5]

🏁 Script executed:

#!/bin/bash
# Find pytest configuration files
echo "=== Looking for pytest configuration files ==="
find . -maxdepth 3 \( -name "pytest.ini" -o -name "pyproject.toml" -o -name "setup.cfg" -o -name "tox.ini" -o -name ".pytest.ini" \) -type f 2>/dev/null | head -20

echo ""
echo "=== Checking Python version requirement ==="
# Check for Python version in setup.py, pyproject.toml, setup.cfg
find . -maxdepth 2 \( -name "setup.py" -o -name "pyproject.toml" -o -name "setup.cfg" \) -type f 2>/dev/null | xargs grep -l "python_requires\|Programming Language :: Python :: 3" 2>/dev/null | head -5

Repository: DagsHub/client

Length of output: 190


🏁 Script executed:

#!/bin/bash
# Search for common deprecated pytest patterns that break in 9.0
echo "=== Searching for deprecated pytest patterns ==="

# Check for deprecated hook signatures (py.path.local)
rg 'py\.path\.local|pytest_ignore_collect.*path[^:]*:.*py\.path|pytest_collect_file.*path[^:]*:.*py\.path' --type py -n 2>/dev/null | head -10

# Check for pytest.importorskip usage
echo ""
echo "=== pytest.importorskip usage ==="
rg 'pytest\.importorskip' --type py -A 2 -n 2>/dev/null | head -20

# Check for yield_fixture (deprecated)
echo ""
echo "=== Deprecated yield_fixture usage ==="
rg '@pytest\.yield_fixture|@yield_fixture' --type py -n 2>/dev/null | head -10

# Check for --strict flag
echo ""
echo "=== Checking for --strict flag usage ==="
rg '\-\-strict' --type py --type toml --type cfg --type ini -n 2>/dev/null | head -10

Repository: DagsHub/client

Length of output: 223


🏁 Script executed:

#!/bin/bash
# Check plugin version compatibility
echo "=== Checking pytest plugin versions from requirements-dev.txt ==="
cat requirements-dev.txt

echo ""
echo "=== Checking for pytest-mock and pytest-env imports/usage ==="
rg 'pytest_mock|mocker|pytest_env' --type py -n 2>/dev/null | head -15

echo ""
echo "=== Checking pytest configuration in files ==="
fd pyproject.toml -x cat {} \;

Repository: DagsHub/client

Length of output: 1573


🏁 Script executed:

#!/bin/bash
echo "=== Content of pytest.ini ==="
cat ./pytest.ini

echo ""
echo "=== Content of pyproject.toml ==="
cat ./pyproject.toml

echo ""
echo "=== Checking setup.py for python_requires ==="
head -50 ./setup.py | grep -A 5 -B 5 "python_requires"

Repository: DagsHub/client

Length of output: 296


🏁 Script executed:

#!/bin/bash
echo "=== Full setup.py to check python_requires ==="
grep -n "python_requires\|version\|author" ./setup.py | head -20

Repository: DagsHub/client

Length of output: 537


🌐 Web query:

pytest-mock 3.15.1 pytest 9.0 compatibility pytest-env 1.6.0 pytest 9.0 compatibility

💡 Result:

  • pytest-mock 3.15.1 → pytest 9.0.x: Compatible by declared requirements: pytest-mock==3.15.1 requires pytest>=6.2.5 (no upper bound), so it can be installed alongside pytest 9.0.x. [1]

  • pytest-env 1.6.0 → pytest 9.0.x: Compatible only with pytest ≥ 9.0.2: pytest-env==1.6.0 declares pytest>=9.0.2, so it will not install with pytest 9.0.0 or 9.0.1, but will with 9.0.2+. [2]

Sources: [1] [3] [2] (pypi.org)

Citations:


Update python_requires in setup.py to >=3.10 — pytest 9.0 requires Python 3.10 or higher.

The upgrade to pytest 9.0.2 introduces a hard requirement for Python 3.10+. Your setup.py currently specifies python_requires=">=3.9", which creates a constraint conflict. This must be updated to python_requires=">=3.10" to ensure compatibility.

The pytest plugin dependencies (pytest-mock 3.15.1 and pytest-env 1.6.0) are compatible with pytest 9.0.2, and your test code contains no deprecated pytest patterns (no yield_fixture, py.path.local hooks, or other breaking changes). However, the Python version constraint is the blocking issue.

respx==0.22.0
pytest-git==1.8.0
pytest-env==1.1.5
pytest-mock==3.14.0
fiftyone==1.5.2
datasets==3.6.0
ultralytics==8.3.237
pytest-env==1.6.0
pytest-mock==3.15.1
fiftyone==1.13.4
datasets==4.7.0
ultralytics==8.4.22
Loading