Skip to content

misidentifies pytest as not installed #25773

Description

when trying to discover a test, it fails due to an import errors

    return _bootstrap._gcd_import(name[level:], package, level)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
test_alice.py:3: in <module>
    import numpy as np
E   ModuleNotFoundError: No module named 'numpy'
=========================== short test summary info ============================
ERROR test_alice.py
!!!!!!!!!!!!!!!!!!!! Interrupted: 1 error during collection !!!!!!!!!!!!!!!!!!!!
===================== no tests collected, 1 error in 0.08s =====================

2026-02-06 10:28:34.748 [error] pytest discovery failed with exit code 2 and signal null for workspace /Users/eleanorboyd/testing/tests-plus-projects/alice/bob. Creating error payload.
2026-02-06 10:28:34.748 [error] pytest test discovery error for workspace:  /Users/eleanorboyd/testing/tests-plus-projects 

The node in the test explorer incorrectly marks this as
pytest Not Installed [project-name ]

which is obviously wrong bc its numpy that is not installed and throwing the error

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

triage-neededNeeds assignment to the proper sub-team

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions