« first day (5138 days earlier)      last day (29 days later) » 

19:48
Bug of the day: If a module imports a submodule and then crashes, the submodule remains in sys.modules but the parent module doesn't. If this submodule is a namespace package and you try to iterate over its __path__, you get a KeyError because for some reason, it tries to look up its parent module in sys.modules
try:
    import some_package.some_namespace_package
except:
    import sys
    iter(sys.modules['some_package.some_namespace_package'].__path__)
Traceback (most recent call last):
  File "D:\Users\Aran-Fey\Desktop\temp {e}\untitled.py", line 3, in <module>
    import some_package.some_namespace_package
  File "D:\Users\Aran-Fey\Desktop\temp {e}\some_package\__init__.py", line 4, in <module>
    1/0
    ~^~
ZeroDivisionError: division by zero

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "D:\Users\Aran-Fey\Desktop\temp {e}\untitled.py", line 6, in <module>
    iter(sys.modules['some_package.some_namespace_package'].__path__)
Do not ask me how I found out about this

« first day (5138 days earlier)      last day (29 days later) »