Guido van Rossum <gu...@python.org> added the comment:

I'm not a big user of the inspect module, but I always thought that its use was 
so that you could look at a function (or other object) *produced by a 3rd 
party* and learn something about it.

Asking for the signature is one such operation, and I'd be rather upset if I 
couldn't inspect the annotation if that 3rd party happened to have added a bad 
string annotation. especially if I wasn't interested in the annotation part of 
the signature in the first place. (There's a lot of other useful info to be 
gleaned from it.)

OTOH I think it's fine for get_annotations() to raise by default if there's a 
bad annotation.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue43817>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to