PEP 484: Clarify Python versioning in stub file search path (#410)

This commit is contained in:
Ethan Smith 2017-09-09 20:56:06 -07:00 committed by Guido van Rossum
parent 13595c99f2
commit ee64ced217
1 changed files with 6 additions and 6 deletions

View File

@ -1833,12 +1833,12 @@ they're updated often.
Third-party stub packages can use any location for stub storage. Type
checkers should search for them using PYTHONPATH. A default fallback
directory that is always checked is ``shared/typehints/python3.5/`` (or
3.6, etc.). Since there can only be one package installed for a given
Python version per environment, no additional versioning is performed
under that directory (just like bare directory installs by ``pip`` in
site-packages). Stub file package authors might use the following
snippet in ``setup.py``::
directory that is always checked is ``shared/typehints/pythonX.Y/`` (for
some PythonX.Y as determined by the type checker, not just the installed
version). Since there can only be one package installed for a given Python
version per environment, no additional versioning is performed under that
directory (just like bare directory installs by ``pip`` in site-packages).
Stub file package authors might use the following snippet in ``setup.py``::
...
data_files=[