Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Migrate API docs to mkdocstrings#3628

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
anuraaga wants to merge3 commits intoencode:master
base:master
Choose a base branch
Loading
fromanuraaga:mkdocstrings

Conversation

@anuraaga
Copy link

@anuraagaanuraaga commentedAug 15, 2025
edited
Loading

Summary

Migrates API docs fromautodoc tomkdocstrings. I was hoping to be able to use an httpx inventory file in some documentation and noticed there seems to be interest in it from the attached issue so tried sending a PR.

I have made tweaks such as to the CSS to make it as close to the current site as possible. Though it could also make sense to have the full TOC.

The biggest difference in rendering is the docs don't have a inlet and are rendered directly. There are some other differences like font size and not showing the wordclass (mkdocstrings may allow it in the future as they have an insiders-only feature for it right now).

I did leave the source code previews since while very different from current, being collapsed they seemed safe to keep.

To really render using mkdocstrings, i.e. rendering out parameters in a structured way, the docstrings themselves would need to be updated to one of the supported styles like Google, numpy, or sphinx. This PR doesn't change that though to be smaller and still be quite close to what's already there, while also providing the inventory file.

To test, I run

uv run --with mkdocs --with mkdocs-material --with mkautodoc --with 'mkdocstrings[python]' mkdocs buildopen site/index.html

Fixes#3145

image
 uvx sphobjinv suggest site/objects.inv as_rst-------------------------------------------------------------------------------------------Cannot infer intersphinx_mapping from a local objects.inv.-------------------------------------------------------------------------------------------Project: HTTPXVersion: 0.0.0164 objects in inventory.-------------------------------------------------------------------------------------------No results found with score at/above current threshold of 75.

Checklist

  • I understand that this PR may be closed in case there was no previous discussion. (This doesn't apply to typos!)
  • I've added a test for each change that was introduced, and I tried as much as possible to make a single atomic change.
  • I've updated the documentation accordingly.

@anuraaga
Copy link
Author

@lovelydinosaur Any interest in this? If not will go ahead and close this. Thanks.

@pollier
Copy link

Hello, it would be great to be able to use objects.inv, generated by mkdocstring to have auto cross reference in project

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Cross reference documentation with mkdocstrings'objects.inv

2 participants

@anuraaga@pollier

[8]ページ先頭

©2009-2025 Movatter.jp