[New-bugs-announce] [issue26234] The typing module includes 're' and 'io' in __all__

Guido van Rossum report at bugs.python.org
Thu Jan 28 19:07:33 EST 2016


New submission from Guido van Rossum:

If you write "from typing import *" you get "re" and "io" for free, which is surprising if this import occurs after an actual "import re" or "import io".

The solution is not to include those two in __all__. You can still use them -- use "from typing import re" explicitly or reference them as "typing.re".

Because typing is provisional I'll fix this in 3.5.2 as well.

----------
messages: 259177
nosy: gvanrossum
priority: release blocker
severity: normal
status: open
title: The typing module includes 're' and 'io' in __all__
versions: Python 3.5, Python 3.6

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue26234>
_______________________________________


More information about the New-bugs-announce mailing list