
May 18, 2023
3:03 p.m.
A simple virtual package could be: # foo.py __path__ = [__file__ + ".d"] But unfortunately this doesn't work with -m: # foo.py.d/__main__.py print("this will never run") (n.b. -m foo.__main__ works but nobody's writing that.) Is it possible to change this backwards-compatibly? If not, is it possible to document it slightly better? Thanks.