Author Malcolm Smith
Recipients Malcolm Smith, docs@python
Date 2017-05-15.16:20:37
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1494865238.41.0.458723699483.issue30372@psf.upfronthosting.co.za>
In-reply-to
Content
https://docs.python.org/3.6/reference/executionmodel.html#builtins-and-restricted-execution describes the various things you can do with __builtins__, but then says "Users should not touch __builtins__; it is strictly an implementation detail." If this is so, the entire section should be marked "CPython implementation detail", not just that last paragraph.

Elsewhere, https://docs.python.org/3.6/reference/import.html#replacing-the-standard-import-system suggests that the __import__ function could be replaced "at the module level to only alter the behaviour of import statements within that module". Is there any way of doing this other than manipulating the module's __builtins__? If not, this is encouraging the programmer to rely on a CPython implementation detail without marking it as such.
History
Date User Action Args
2017-05-15 16:20:38Malcolm Smithsetrecipients: + Malcolm Smith, docs@python
2017-05-15 16:20:38Malcolm Smithsetmessageid: <1494865238.41.0.458723699483.issue30372@psf.upfronthosting.co.za>
2017-05-15 16:20:38Malcolm Smithlinkissue30372 messages
2017-05-15 16:20:37Malcolm Smithcreate