Skip to content
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

Pytest run completes, but throws an exception at the end #21714

Closed
nlykkei opened this issue Jul 31, 2023 · 5 comments
Closed

Pytest run completes, but throws an exception at the end #21714

nlykkei opened this issue Jul 31, 2023 · 5 comments
Assignees
Labels
area-testing info-needed Issue requires more information from poster triage-needed Needs assignment to the proper sub-team

Comments

@nlykkei
Copy link

nlykkei commented Jul 31, 2023

Type: Bug

Pytest run completes, but throws an exception at the end, which results in "Pytest test execution error":

at ChildProcess.<anonymous> (/Users/dkNiLyIv/.vscode/extensions/ms-python.python-2023.13.12091005/out/client/extension.js:2:241907)
at Object.onceWrapper (node:events:628:26)
at ChildProcess.emit (node:events:513:28)
at ChildProcess.emit (node:domain:489:12)
at maybeClose (node:internal/child_process:1121:16)
at Process.ChildProcess._handle.onexit (node:internal/child_process:304:5)

Extension version: 2023.13.12091005
VS Code version: Code 1.80.2 (Universal) (2ccd690cbff1569e4a83d7c43d45101f817401dc, 2023-07-27T21:05:41.366Z)
OS version: Darwin arm64 22.5.0
Modes:

System Info
Item Value
CPUs Apple M1 Pro (10 x 24)
GPU Status 2d_canvas: enabled
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
Load (avg) 3, 5, 5
Memory (System) 32.00GB (4.08GB free)
Process Argv . --crash-reporter-id 274423a4-addb-4168-83cb-c314243d362f
Screen Reader no
VM 0%
A/B Experiments
vsliv368:30146709
vsreu685:30147344
python383:30185418
vspor879:30202332
vspor708:30202333
vspor363:30204092
vslsvsres303:30308271
vserr242:30382549
pythontb:30283811
vsjup518:30340749
pythonptprofiler:30281270
vshan820:30294714
vstes263:30335439
vscorecescf:30445987
vscod805:30301674
binariesv615:30325510
bridge0708:30335490
bridge0723:30353136
vsaa593:30376534
pythonvs932:30410667
vscaac:30438847
vsclangdc:30486549
c4g48928:30535728
dsvsc012:30540252
pynewext54:30695312
azure-dev_surveyone:30548225
2e4cg342:30602488
89544117:30613380
2i9eh265:30646982
showlangstatbar:30737416
vsctsb:30748421
a2ce3375:30757347
57b77579:30736110
pythonfmttext:30731395
pythoncmv:30756943
fixshowwlkth:30771522
showindicator:30785052
pythongtdpath:30769146
i26e3531:30792625
gsofa:30797621
pythonnosmt12:30797651
pythonnoceb:30797650
e537b577:30795824
dsvsc013:30795093
dsvsc014:30797589
cmakestatusbarv2:30779594

@github-actions github-actions bot added the triage-needed Needs assignment to the proper sub-team label Jul 31, 2023
@eleanorjboyd
Copy link
Member

Hello! Could you check at the top of your logs for something that says Experiment 'pythonTestAdapter'? If none of the experiments are coming up then change the setting "python.analysis.logLevel": "Trace",` in your user settings. Let me know what it says regarding this experiment since that will narrow down if this issue is due to the testing rewrite or not. Thanks

@github-actions github-actions bot added the info-needed Issue requires more information from poster label Jul 31, 2023
@nlykkei
Copy link
Author

nlykkei commented Aug 1, 2023

2023-08-01 13:28:15.476 [info] Experiment 'pythonaa' is active
2023-08-01 13:28:15.476 [info] Experiment 'pythonPromptNewFormatterExt' is active
2023-08-01 13:28:15.476 [info] Experiment 'pythonPromptNewToolsExt' is active
2023-08-01 13:28:15.476 [info] Experiment 'pythonTestAdapter' is active
2023-08-01 13:28:15.476 [info] Test server listening.
2023-08-01 13:28:16.496 [info] > ./lego/.venv/bin/python -I ~/.vscode/extensions/ms-python.python-2023.13.12131007/pythonFiles/get_output_via_markers.py ~/.vscode/extensions/ms-python.python-2023.13.12131007/pythonFiles/interpreterInfo.py
2023-08-01 13:28:16.625 [info] Python interpreter path: ./lego/.venv/bin/python
2023-08-01 13:28:17.468 [info] Starting Pylance language server.
2023-08-01 13:28:22.477 [info] Experiment 'pythonaa' is active
2023-08-01 13:28:22.477 [info] Experiment 'pythonPromptNewFormatterExt' is active
2023-08-01 13:28:22.477 [info] Experiment 'pythonPromptNewToolsExt' is active
2023-08-01 13:28:22.477 [info] Experiment 'pythonTestAdapter' is active
2023-08-01 13:28:22.526 [info] Test server listening.
2023-08-01 13:28:22.527 [info] Python interpreter path: ./lego/.venv/bin/python
2023-08-01 13:28:24.722 [info] Starting Pylance language server.
2023-08-01 13:28:26.873 [info] Discover tests for workspace name: lddprobff - uri: /Users/dkNiLyIv/projects/ldd/lddprobff
2023-08-01 13:28:26.873 [info] Discover tests for workspace name: lego - uri: /Users/dkNiLyIv/projects/ldd/lddprobff/xxx
2023-08-01 13:28:26.873 [info] Running discovery for pytest using the new test adapter.

@github-actions github-actions bot removed the info-needed Issue requires more information from poster label Aug 1, 2023
@nlykkei
Copy link
Author

nlykkei commented Aug 1, 2023

I work in a multi-root project, but the issue also exist in single-root projects.

The adapter has multiple issues. Sometimes, it reports test status dynamically, other times not...

@eleanorjboyd
Copy link
Member

@nlykkei thank you for the info! Apologies for the inconsistency and the bugs you are seeing, we are in the process of rolling out a new architecture for testing and experiencing some of those issues along the way. You can opt out of the experiment by going to your user setting and setting "python.experiments.optOutFrom": ["pythonTestAdapter"],. If this doesn't work let me know as this will mean it is a different issue.

To diagnose your issue further could you send over the settings you have for your pytest args and also a minimal repro that I could try? I have not encountered this error and therefore cannot investigate it further.

We appreciate your patience and help during this time! All the bugs users file are key to making our extension work and community support is essential. Thanks

@github-actions github-actions bot added the info-needed Issue requires more information from poster label Aug 1, 2023
@brettcannon
Copy link
Member

Because we have not heard back with the information we requested, we are closing this issue for now. If you are able to provide the info later on, then we will be happy to re-open this issue to pick up where we left off.

@brettcannon brettcannon closed this as not planned Won't fix, can't repro, duplicate, stale Aug 31, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 1, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-testing info-needed Issue requires more information from poster triage-needed Needs assignment to the proper sub-team
Projects
None yet
Development

No branches or pull requests

3 participants