This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author McSinyx
Recipients McSinyx, docs@python
Date 2020-03-17.14:19:08
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <[email protected]>
In-reply-to
Content
I traced it down to inspect.formatannotation(annotation).  Before checking for isinstance(annotation, type), IMHO we should do something like

import typing

if isinstance(annotation, str):
    annotation = typing.ForwardRef(str)._evaluate(annotation)

However, is is not aware of globals and especially locals of help caller, so I guess more sophisticated solution is required.
History
Date User Action Args
2020-03-17 14:19:09McSinyxsetrecipients: + McSinyx, docs@python
2020-03-17 14:19:09McSinyxsetmessageid: <[email protected]>
2020-03-17 14:19:09McSinyxlinkissue39990 messages
2020-03-17 14:19:08McSinyxcreate