sphinx/ext/autodoc/__init__.py:719 could lead to __bool__
method call, what can lead to side effect or direct failure in case it generate an error
#8522
Milestone
Describe the bug
The code is the following:
But if
safe_getattr
returns some object with redefined__bool__
, e.g.This code will be executed and will lead to sphinx failure or unexpected side effects.
To Reproduce
Unfortunately I can't reproduce it as a toy example, but it lead to failure on my work project.
Expected behavior
Do not call user code.
The text was updated successfully, but these errors were encountered: