Skip to content

Commit c95c959

Browse files
committed
Removed debugging code
1 parent 147368a commit c95c959

File tree

1 file changed

+0
-7
lines changed

1 file changed

+0
-7
lines changed

sphinx_autodoc_typehints.py

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,6 @@ def get_annotation_args(annotation, module: str, class_name: str) -> Tuple:
8787
def format_annotation(annotation,
8888
fully_qualified: bool = False,
8989
simplify_optional_unions: bool = True) -> str:
90-
print(f'formatting annotation: {annotation!r} ({type(annotation)})')
9190
# Special cases
9291
if annotation is None or annotation is type(None): # noqa: E721
9392
return ':py:obj:`None`'
@@ -166,8 +165,6 @@ def process_signature(app, what: str, name: str, obj, options, signature, return
166165
param.replace(annotation=inspect.Parameter.empty)
167166
for param in signature.parameters.values()
168167
]
169-
if name == 'dummy_module.function_with_unresolvable_annotation':
170-
print(f' parameters: {parameters}')
171168

172169
# The generated dataclass __init__() and class are weird and need extra checks
173170
# This helper function operates on the generated class and methods
@@ -189,8 +186,6 @@ def _is_dataclass(name: str, what: str, qualname: str) -> bool:
189186
return
190187

191188
if parameters:
192-
if name == 'dummy_module.function_with_unresolvable_annotation':
193-
print(' formatting parameters')
194189
if inspect.isclass(original_obj) or (what == 'method' and name.endswith('.__init__')):
195190
del parameters[0]
196191
elif what == 'method':
@@ -214,8 +209,6 @@ def _is_dataclass(name: str, what: str, qualname: str) -> bool:
214209
parameters=parameters,
215210
return_annotation=inspect.Signature.empty)
216211

217-
if name == 'dummy_module.function_with_unresolvable_annotation':
218-
print(' stringifying signature')
219212
return stringify_signature(signature).replace('\\', '\\\\'), None
220213

221214

0 commit comments

Comments
 (0)