Skip to content

Conversation

USSX-Hares
Copy link

@USSX-Hares USSX-Hares commented Jul 24, 2025

Closes #463

Changes

  • Added pdoc._unwrap_object() function which behaves like insepct.unwrap(), but respects classes
    • This function is used instead of inspect.unwrap() in the entire codebase
  • Added a test covering this specific case (pdoc.test.ApiTest.test_class_wrappers and pdoc.test.example_pkg._test_classwrap)

Code Quality

  • flake8 checks passed locally (added a single exception for long lines due to longer docstrings)
    • There was a single error on pdoc.cli#603, but I have not touched this file
  • Tests passed via tox on the following environments (os: Windows):
    • Python 3.9.12
    • Python 3.10.4
    • Python 3.11.9
    • Python 3.12.1
    • Python 3.12.10
    • Python 3.13.5
  • There are two mypy issues in the code I haven't touched, however

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Ambigous usage of inspect.unwrap() on classes
1 participant