pdoc icon indicating copy to clipboard operation
pdoc copied to clipboard

Support patching docs from imported module stub files

Open inventshah opened this issue 1 month ago • 2 comments

Fixes #791.

Patches docs for variables imported from other modules with external type stubs if the current module has no type stubs. Helps create docs for native extension modules (e.g. from nanobind or PyO3).

inventshah avatar Nov 11 '25 20:11 inventshah

Investigating test failures. The 3.14.0 ones looks potentially unrelated, but the others are legit.

inventshah avatar Nov 11 '25 21:11 inventshah

@mhils fixed the tests so this should be ready for review.

One other behavior change is in TypeDict inheritance, attributes no longer skip directly to the base class its from, and instead follows the inheritance hierarchy (test_snapshot.py::test_snapshots[repr-typed_dict]). This feels slightly more accurate to me, but happy to try to preserve the old behavior if desirable. I see theres already some special casing around TypeDict so maybe you have thoughts or advise there.

inventshah avatar Nov 11 '25 22:11 inventshah