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 barry
Recipients barry
Date 2017-10-16.14:16:27
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1508163387.44.0.213398074469.issue31799@psf.upfronthosting.co.za>
In-reply-to
Content
__spec__ is defined in PEP 451.  If you search for "__spec__" in the docs, you get a number of hits.

https://docs.python.org/3/search.html?q=__spec__&check_keywords=yes&area=default

Click on the first link:

https://docs.python.org/3/reference/import.html?highlight=__spec__#__spec__

but that still leaves you scratching your head as to what exactly is in __spec__.  If you happen to scroll up a little bit though, you end up here:

https://docs.python.org/3/reference/import.html?highlight=__spec__#module-spec

and then if you follow the link to ModuleSpec, you finally get to here:

https://docs.python.org/3/library/importlib.html#importlib.machinery.ModuleSpec

and *that's* where the contents of __spec__ are defined.  Not very discoverable.

I propose just a couple of small documentation fixes to add "__spec__" in both of those locations so that a search lands you in a useful place.
History
Date User Action Args
2017-10-16 14:16:27barrysetrecipients: + barry
2017-10-16 14:16:27barrysetmessageid: <1508163387.44.0.213398074469.issue31799@psf.upfronthosting.co.za>
2017-10-16 14:16:27barrylinkissue31799 messages
2017-10-16 14:16:27barrycreate