Jason R. Coombs <jar...@jaraco.com> added the comment:
I created this diff: ```diff diff --git a/Lib/test/test_importlib/test_metadata_api.py b/Lib/test/test_importlib/test_metadata_api.py index e16773a7e8..92aacd5ad5 100644 --- a/Lib/test/test_importlib/test_metadata_api.py +++ b/Lib/test/test_importlib/test_metadata_api.py @@ -90,8 +90,11 @@ def test_entry_points_distribution(self): self.assertEqual(ep.dist.version, "1.0.0") def test_entry_points_unique_packages(self): - # Entry points should only be exposed for the first package - # on sys.path with a given name. + """ + Entry points should only be exposed for the first package + on sys.path with a given name. + """ + raise ValueError("Failing on purpose") alt_site_dir = self.fixtures.enter_context(fixtures.tempdir()) self.fixtures.enter_context(self.add_sys_path(alt_site_dir)) alt_pkg = { ``` And then ran the tests, but the output is easy to totally scrutable: ``` cpython bpo-46126/bad-error-message $ ./python.exe -m test.test_importlib ........................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................s............................E.................................................x.............. ........................................................................................s....................................................................................................................................................................Trying 20 threads ... 44.7 ms OK. Trying 50 threads ... 36.8 ms OK. Trying 20 threads ... 27.7 ms OK. Trying 50 threads ... 28.0 ms OK. Trying 20 threads ... 27.9 ms OK. Trying 50 threads ... 31.1 ms OK. .Trying 20 threads ... 7.1 ms OK. Trying 50 threads ... 7.6 ms OK. Trying 20 threads ... 3.2 ms OK. Trying 50 threads ... 8.5 ms OK. Trying 20 threads ... 3.4 ms OK. Trying 50 threads ... 8.7 ms OK. .Trying 20 threads ... 40.3 ms OK. Trying 50 threads ... 8.7 ms OK. Trying 20 threads ... 3.5 ms OK. Trying 50 threads ... 6.5 ms OK. Trying 20 threads ... 3.2 ms OK. Trying 50 threads ... 6.5 ms OK. ..................................................s............................s................................................s............................s............... ====================================================================== ERROR: test_entry_points_unique_packages (test.test_importlib.test_metadata_api.APITests) Entry points should only be exposed for the first package ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/jaraco/code/public/cpython/Lib/test/test_importlib/test_metadata_api.py", line 97, in test_entry_points_unique_packages raise ValueError("Failing on purpose") ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ValueError: Failing on purpose ---------------------------------------------------------------------- Ran 1426 tests in 2.377s FAILED (errors=1, skipped=6, expected failures=1) ``` So there must be some other test invocation that doesn't provide the clarity of which test is failing. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue46126> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com