Skip to content

sphinx 8.2 deprecation warning _InventoryItem.__iter__ #1078

@lucascolley

Description

@lucascolley

sphinx-doc/sphinx#13248

    Traceback (most recent call last):
      File "/Users/lucascolley/ghq/github.com/scipy/scipy/.pixi/envs/docs/lib/python3.14/site-packages/sphinx/cmd/build.py", line 432, in build_main
        app.build(args.force_all, args.filenames)
        ~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/Users/lucascolley/ghq/github.com/scipy/scipy/.pixi/envs/docs/lib/python3.14/site-packages/sphinx/application.py", line 426, in build
        self.builder.build_update()
        ~~~~~~~~~~~~~~~~~~~~~~~~~^^
      File "/Users/lucascolley/ghq/github.com/scipy/scipy/.pixi/envs/docs/lib/python3.14/site-packages/sphinx/builders/__init__.py", line 375, in build_update
        self.build(
        ~~~~~~~~~~^
            to_build,
            ^^^^^^^^^
        ...<2 lines>...
            method='update',
            ^^^^^^^^^^^^^^^^
        )
        ^
      File "/Users/lucascolley/ghq/github.com/scipy/scipy/.pixi/envs/docs/lib/python3.14/site-packages/sphinx/builders/__init__.py", line 454, in build
        self.write(docnames, updated_docnames, method)
        ~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/Users/lucascolley/ghq/github.com/scipy/scipy/.pixi/envs/docs/lib/python3.14/site-packages/sphinx/builders/__init__.py", line 735, in write
        self.write_documents(docnames)
        ~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^
      File "/Users/lucascolley/ghq/github.com/scipy/scipy/.pixi/envs/docs/lib/python3.14/site-packages/sphinx/builders/__init__.py", line 749, in write_documents
        self._write_serial(sorted_docnames)
        ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^
      File "/Users/lucascolley/ghq/github.com/scipy/scipy/.pixi/envs/docs/lib/python3.14/site-packages/sphinx/builders/__init__.py", line 765, in _write_serial
        doctree = self.env.get_and_resolve_doctree(docname, self)
      File "/Users/lucascolley/ghq/github.com/scipy/scipy/.pixi/envs/docs/lib/python3.14/site-packages/sphinx/environment/__init__.py", line 701, in get_and_resolve_doctree
        self.apply_post_transforms(doctree, docname)
        ~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^
      File "/Users/lucascolley/ghq/github.com/scipy/scipy/.pixi/envs/docs/lib/python3.14/site-packages/sphinx/environment/__init__.py", line 773, in apply_post_transforms
        transformer.apply_transforms()
        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
      File "/Users/lucascolley/ghq/github.com/scipy/scipy/.pixi/envs/docs/lib/python3.14/site-packages/sphinx/transforms/__init__.py", line 92, in apply_transforms
        super().apply_transforms()  # type: ignore[misc]
        ~~~~~~~~~~~~~~~~~~~~~~~~^^
      File "/Users/lucascolley/ghq/github.com/scipy/scipy/.pixi/envs/docs/lib/python3.14/site-packages/docutils/transforms/__init__.py", line 182, in apply_transforms
        transform.apply(**kwargs)
        ~~~~~~~~~~~~~~~^^^^^^^^^^
      File "/Users/lucascolley/ghq/github.com/scipy/scipy/.pixi/envs/docs/lib/python3.14/site-packages/sphinx/transforms/post_transforms/__init__.py", line 46, in apply
        self.run(**kwargs)
        ~~~~~~~~^^^^^^^^^^
      File "/Users/lucascolley/ghq/github.com/scipy/scipy/.pixi/envs/docs/lib/python3.14/site-packages/myst_parser/sphinx_ext/myst_refs.py", line 99, in run
        newnode = self._resolve_myst_ref_intersphinx(
            node, contnode, target, search_domains
        )
      File "/Users/lucascolley/ghq/github.com/scipy/scipy/.pixi/envs/docs/lib/python3.14/site-packages/myst_parser/sphinx_ext/myst_refs.py", line 354, in _resolve_myst_ref_intersphinx
        for m in inventory.filter_sphinx_inventories(
                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
            InventoryAdapter(self.env).named_inventory,
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
            targets=target,
            ^^^^^^^^^^^^^^^
        )
        ^
      File "/Users/lucascolley/ghq/github.com/scipy/scipy/.pixi/envs/docs/lib/python3.14/site-packages/myst_parser/inventory.py", line 369, in filter_sphinx_inventories
        project, version, loc, text = data[target]
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/Users/lucascolley/ghq/github.com/scipy/scipy/.pixi/envs/docs/lib/python3.14/site-packages/sphinx/util/inventory.py", line 322, in __iter__
        warnings.warn(
        ~~~~~~~~~~~~~^
            'The iter() interface for _InventoryItem objects is deprecated.',
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
            RemovedInSphinx10Warning,
            ^^^^^^^^^^^^^^^^^^^^^^^^^
            stacklevel=2,
            ^^^^^^^^^^^^^
        )
        ^
    sphinx.deprecation.RemovedInSphinx10Warning: The iter() interface for _InventoryItem objects is deprecated.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions