-
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
print() doesn't work in debug console while debugging pytests #19949
Comments
This is a duplicate of: #19322 |
I am not sure that this is the same issue because I have this in settings.json, so it is not matter of defaults.
|
Can you type in |
For settings.json like:
I get:
At the moment I can print, but from time to time print(12) just make an empty line. Do you see different vertical spaces? They are when print fails. Usually I don't have anything as output. |
The fact that it doesn't write sometimes due to the clipping is already reported at: (so, this can be closed as a duplicate). |
I don't know is it the same issue. |
Usually, end user (UAT) should confirm that problem is solved. |
@zljubisic, yes this is true - can someone verify? |
It kind of works if you don't count occasional empty line. Please look at the space between second print and word "first". The same goes with dictionary as well. You can see empty line that shows up occasionally. I try to use rich print as well ( |
@zljubisic can you provide the debugger logs for that case? See: https://github.com/microsoft/debugpy/wiki/Enable-debugger-logs for details on how to collect the logs. |
This has happened on my business computer. |
You can verify the log messages and anonymize accordingly before sending the logs. |
Do you have some anonymizing function that can do that, or I have to pass over the files visually? |
Do I have to put
|
You need to pass them yourself and determine what's important for you to remain anonymous.
If you launch it through the testing tab or dropdown in editor yes. |
@fabioz in case of vscode executed on windows 10 but connected to centos 7 in hyperv, where I should expect logs to show up? |
Just to confirm that problem with print() is still present. |
It should be in Linux. I suggest you go with the environment variable in this case and point the environment variable to the place you'd like the logs to be on Linux. p.s.: you have to do the log anonymizing manually and decide what you're comfortable sharing or not (as it's a sample case with sample code, I don't expect you to have to anonymize much...). |
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. |
Type: Bug
If I set a breakpoint in pytest test, when I am on the breakpoint, if I enter debug console and execute prints, nothing is showed up.
Is that a bug or feature?
Extension version: 2022.14.0
VS Code version: Code 1.71.2 (74b1f979648cc44d385a2286793c226e611f59e7, 2022-09-14T21:03:37.738Z)
OS version: Windows_NT x64 10.0.19042
Modes:
Sandboxed: No
Remote OS version: Linux x64 3.10.0-1127.el7.x86_64
The text was updated successfully, but these errors were encountered: