Eric Snow <ericsnowcurren...@gmail.com> added the comment:
I ended up writing up more thoughts on this in the issue about __package__: https://bugs.python.org/issue45540#msg404619. Users can call importlib.util.find_spec(), which is probably good enough to figure out how a module was originally imported. So I don't have any serious objections to making the spec the writable single-source-of-truth. FWIW, I'd rather there were high-level helpers available as an alternative to the low-level practice of modifying module attrs. However, in this case it probably isn't frequent enough to make it worth it. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue33277> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com