-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
VSCode failed to discover pytest unit tests: overwriting env vars #21535
Comments
Hi! Are you on insiders? We have just launched a new testing infrastructure and this could be the problem. You can test this as well by setting |
@eleanorjboyd Thanks for the reply. I just modified the settings as you mentioned, but the problem still exists. I also tried a release version of VSCode, the problem behaves exactly the same as the insiders version: The version info of the release version I've tryied: Version: 1.79.2 (Universal) |
will investigate- thanks! |
Hello! Could you send the full logs from the python output with the settings |
@eleanorjboyd The full logs are as follow:
Even though I changed the settings as you mentioned, the logs don't seem to be getting much more. Hope I'm doing the right thing, thanks. |
Hello! Given the fact that you see it both with and without the rewrite as well as the specific error message, I am not sure if it is actually caused by vscode. To check could you run this command from a non-activated environment |
@eleanorjboyd the |
Thank you for trying those steps! I will need to do some work on my end before I can ask you to try something else but I am working on debugging it. Thanks |
Hi! Can you run this and send me back the whole output? |
@eleanorjboyd thanks for the work. I found that unittests CAN be discovered when I open VSCode today, but the error messages are still shown in the output window, I'm not sure what happened. I'm still willing to help you guys to debug. I ran commands you mentioned, the output is as follows(I can see plugin error here): |
Hi there, I used devcontainer for my work but I cannot now, I can discover the tests, but I cannot run it because of incorrect path (as I can assume because debug setup with full path from launch.json works fine) I am using following setting for my devcontainer:
but as I can see while I am trying to run test path starts from one folder inside and not tests folder, for example: Also color indication doesn't work at all I mean it doesn't representing any info, not green check marks nor red crosses |
@eleanorjboyd thanks, I hope I did everything right #21637 :) |
closing as the issue is no longer appearing- please reopen if the issue surfaces again. Thanks |
Type: Bug
Error messages shows in Test Explorer: Pytest Discovery Error:
Messages shown in OUTPUT > Python:
But "pytest --collect-only" works fine
Please help me to solve this problem, thank you very much.
Extension version: 2023.10.1
VS Code version: Code - Insiders 1.80.0-insider (Universal) (49b8e2d5410795e5a23a9c6b7f99b97f4afb4b47, 2023-06-23T13:51:01.857Z)
OS version: Darwin arm64 22.5.0
Modes:
System Info
canvas_oop_rasterization: disabled_off
direct_rendering_display_compositor: disabled_off_ok
gpu_compositing: enabled
metal: disabled_off
multiple_raster_threads: enabled_on
opengl: enabled_on
rasterization: enabled
raw_draw: disabled_off_ok
video_decode: enabled
video_encode: enabled
vulkan: disabled_off
webgl: enabled
webgl2: enabled
webgpu: enabled
A/B Experiments
The text was updated successfully, but these errors were encountered: