mansenfranzen / autodoc_pydantic

Seamlessly integrate pydantic models in your Sphinx documentation.
MIT License
159 stars 27 forks source link

Deprecation warning `sphinx.util.typing.stringify` for Sphinx v7.2.6 #178

Closed huxuan closed 8 months ago

huxuan commented 1 year ago
Running Sphinx v7.2.6
/home/huxuan/Code/serious-scaffold-python/.venv/lib/python3.10/site-packages/sphinxcontrib/autodoc_pydantic/directives/autodocumenters.py:21: RemovedInSphinx80Warning: The alias 'sphinx.util.typing.stringify' is deprecated, use 'sphinx.util.typing.stringify_annotation' instead. Check CHANGES for Sphinx API modifications.
  from sphinx.util.typing import get_type_hints, stringify
mansenfranzen commented 11 months ago

Thanks for raising the deprecation warning! I will be recognized in the upcoming release.

mansenfranzen commented 8 months ago

Done via #190

mansenfranzen commented 8 months ago

@all-contributors please add @huxuan for bug

allcontributors[bot] commented 8 months ago

@mansenfranzen

I've put up a pull request to add @huxuan! :tada:

mansenfranzen commented 8 months ago

Before merging the related PR, it would be great if you could test the changed behavior. To do so, please install the current dev release in your doc-building-environment via pip install git+https://github.com/mansenfranzen/autodoc_pydantic.git@v2.1.0-a.1 and rebuild your docs.

Please feel free to reopen if any problem remains. I will release the new version upcoming Monday.

huxuan commented 8 months ago

Hi @mansenfranzen,

I created a pull request for test: https://github.com/serious-scaffold/ss-python/pull/405, and the preview documentation generated by autodoc_pydantic can be referred here: https://ss-python--405.org.readthedocs.build/en/405/api/settings.html. it looks like everything works smoothly!

More details:

The workflow run for the pull request: https://github.com/serious-scaffold/ss-python/actions/runs/8281329818

The workflow run for the latest main branch: https://github.com/serious-scaffold/ss-python/actions/runs/8280763274

You can refer to the ci (3.8), ci (3.9), ci (3.10), ci (3.11), ci (3.12) as test jobs for different Python versions. In each jobs, the Run make dev step shows the installation of the packages including autodoc_pydantic, and the Run CI_PAGES_URL=https://serious-scaffold.github.io/ss-python make doc step show the documentation building process.

With the logs we can confirm that, when new version of autodoc_pydantic is installed the deprecation warning is gone and the whole documentation building process works for different Python versions.

mansenfranzen commented 8 months ago

Thanks for your detailed response.