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.

classification
Title: Deficiencies in type hint usage in Python standard libraries
Type: behavior Stage: resolved
Components: Documentation Versions:
process
Status: closed Resolution: not a bug
Dependencies: Superseder:
Assigned To: docs@python Nosy List: John Michael Lafayette, docs@python, r.david.murray
Priority: normal Keywords:

Created on 2015-10-11 04:46 by John Michael Lafayette, last changed 2022-04-11 14:58 by admin. This issue is now closed.

Messages (2)
msg252758 - (view) Author: John Michael Lafayette (John Michael Lafayette) Date: 2015-10-11 04:46
I love the new type hint feature in Jetbrains IDE (PEP 0484). Now when my user defined methods return a value, I can press (Crtl+space) and see the type of that value and all its methods. Also, when I pass the wrong type in, I get a warning. 

Oddly, this does not happen with Python standard library functions. I can't get the auto-complete on objects returned by the Python standard library. The Python standard library doesn't warn me in advance if I put the wrong type in a method. How does that make sense? Please support PEP 0484 by using it in the Python standard library where appropriate.
msg252807 - (view) Author: R. David Murray (r.david.murray) * (Python committer) Date: 2015-10-11 14:39
You need to install the (currently externally maintained) type hints files from https://github.com/python/typeshed.  I don't think a decision has been made about if/when these files will be incorporated into the distribution.
History
Date User Action Args
2022-04-11 14:58:22adminsetgithub: 69561
2015-10-11 14:39:39r.david.murraysetstatus: open -> closed

nosy: + r.david.murray
messages: + msg252807

resolution: not a bug
stage: resolved
2015-10-11 04:46:16John Michael Lafayettecreate