Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix for #7516 #7520

Merged
merged 1 commit into from Apr 20, 2020
Merged

fix for #7516 #7520

merged 1 commit into from Apr 20, 2020

Conversation

a-recknagel
Copy link
Contributor

@a-recknagel a-recknagel commented Apr 20, 2020

Bugfix

Subject: Enable secure object inspection in autodoc'd modules.

Purpose

Inspecting objects in user modules can be risky if they raise errors in their __getattr__ implementations. One such case is the flask.request proxy which will complain about not being in a valid context if is accessed in any way and throws a RuntimeError.

Detail

I replaced the getattr call with the existing safe_getattr.

Relates

#7516


Same as #7518 based from a different branch, because I was not clever enough to rebase between branches that can't be fast-forwarded.

@a-recknagel a-recknagel mentioned this pull request Apr 20, 2020
@a-recknagel
Copy link
Contributor Author

ping @tk0miya , with the changes you requested. I tested it locally and the fix still works.

@tk0miya tk0miya added this to the 3.0.3 milestone Apr 20, 2020
@tk0miya tk0miya merged commit a65db71 into sphinx-doc:3.0.x Apr 20, 2020
@tk0miya
Copy link
Member

tk0miya commented Apr 20, 2020

Thanks!

ooduor referenced this pull request Jan 5, 2021
Fix #8164: autodoc: Classes that inherit mocked class are not documented
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jul 31, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants