-
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
Spawn for running test discovery is not following symlinks properly. #9347
Comments
Thanks for letting us know about this, @JacekPliszka. We'll take a look as soon as we can. |
+1. I am having the same issue. Although, intermittently, I am able to |
@JacekPliszka, I wasn't able to reproduce the problem. Using the simple example you provided, the extension was able to discover the test without problem. Is it happening every time for you? Since running the command manually worked for you, we know that the problem isn't related to the output of the command. There is something wrong in the extension (at least your install, if not the extension itself). However, it will be hard to determine the cause until we can reliably reproduce the problem. FWIW, the |
Yes. Happens every time. With any project. This is my first install and the first time I use vscode for anything. I do not know Javascript so I do not know how to debug it. What would be useful is better error message/issue detection. Something is undefined but should not be but what and why - I've no idea. |
Yeah, I agree that the error message is unhelpful. Sorry about that. Would you mind trying the latest version of the extension (released just yesterday)? |
updated - no change. I believe I have something missing in setup and the extension is not detecting it and not telling me and I do not know what to do. |
Understood. I'll try to narrow down the possible problematic code (based on |
@JacekPliszka, during discovery did a message like the following pop up?
|
No Test discovery error, please check the configuration settings for the tests. It is at the top of the log I've pasted |
What is in your settings.json file? |
Same what I've pasted under steps to reproduce
|
Do you have a workspace file? Also, what do you see in the status bar when you discover tests? It should show "Discovering Tests" and then change depending on the outcome. (On success it says "Run Tests".) |
This is all I have
In status bar I have Discovering Tests and then Test discovery failed |
Thanks. That helps. |
Given that info, we know that the problem is somewhere under the call to the pytest @JacekPliszka, in the |
OK, now I am getting python error too. I do not know why it is calling tests in different directory. But regardless of it - vscode should be able to handle it gracefully with some meaningful error message. Errors was checked - I unchecked the other. The result are 3 entries
|
OK, looks like there was config in ~/.config/Code/ - testing working directory should be per project/workspace, not global. After fixing this I got
command line run:
|
Yeah, I agree that the "TypeError: Cannot read property 'uri' of undefined" error is basically useless (both for you and for us). We will work on fixing that (see #9521). As to the problem, VS Code (actually, Node JS) is saying that your operating system couldn't find Please provide the contents of the "Python" output panel. Also, are you using any remote extensions? |
dup of #9347, hopefully, it can be addressed soon now that we are rolling out the rewrite. |
tried these steps and was able to find and run tests with pytest. Are people still seeing issues currently on insiders? Could someone provide a minimal repro or steps to create one if so? |
repost from #21373, trying to consolidate discussion of testing with symlinks there. my msg: |
Closing this issue since it has been a month and I haven't gotten any response to my above post regarding a minimal repro. Please comment if you are still seeing this and have a repo I can debug with and Ill reopen the issue. Thanks! |
Hello! I was able to figure out a repo and a solution. I have put together a detailed problem report and proposed solution for symlinks. Please check it out here and contribute any thoughts you may have: #22658 |
Hello! This bug should be fixed and on vscode insiders! The release to vscode stable will be out by the end of the week. Please let me know if you try it on insiders or stable when it comes out and still doesn't work and I can investigate your specific issue further. |
Environment data
"python.jediEnabled"
set to; more info How to update the language server to the latest stable version #3977): "python.jediEnabled": trueExpected behaviour
tests are detected
Actual behaviour
tests are not detected, error is issues, running the adapter returns:
Steps to reproduce:
code .
Logs
Output from
Console
under theDeveloper Tools
panel (toggle Developer Tools on underHelp
; turn on source maps to make any tracebacks be useful by runningEnable source map support for extension debugging
)The text was updated successfully, but these errors were encountered: