You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
unittest discovery and test.regrtest cannot find tests when they're not on the filesystem #157144
When the standard library is a zip archive on sys.path, the test package is not a directory: findtests() failed with an OSError from os.listdir() and load_package_tests() failed with "Start directory is not importable" from unittest discovery.
I'm still deciding if this should be done, it is perhaps odd thing to do to bundle tests into an archive before running, but this should apply to other import hooks as well and bundling tests into a zip is sort of a nice way of running tests against a fully zipped application. It's a feature regardless.
changed the title [-]test.regrtest cannot find tests when they're not on the filesystem[/-][+]unittest discovery and test.regrtest cannot find tests when they're not on the filesystem[/+]on Sep 8, 2026
Activity
pythongh-157144: Support archives in unittest discovery instead of in…
pythongh-157144: Name the entry kinds in unittest discovery
[-]test.regrtest cannot find tests when they're not on the filesystem[/-][+]unittest discovery and test.regrtest cannot find tests when they're not on the filesystem[/+]pythongh-157144: Reject missing archive paths and unimportable names …