Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
PEP 842 – Module Exports (python.org)
2 points by Ravencentric 38 days ago | hide | past | favorite | 1 comment


When I saw the initial discussion I was confused as to how it's supposed to actually add functionality, but I see the current draft proposes an `ExportWarning` for explicit use of non-exported attributes. That... seems like it's going to slow down attribute access, while still being just a warning that's easily ignored and probably not even seen in a lot of contexts where it would be helpful. Also, this will define a default `__all__` when that's missing, but I can imagine some gotchas for people trying to use both systems.

The concept seems more elegant that `__all__` in itself, but once again backwards compatibility concerns add complexity.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: