-
Notifications
You must be signed in to change notification settings - Fork 27.9k
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
SendText to terminal while handling run-in-terminal
request send partial content.
#158517
Comments
Note: I switched my default terminal from Git Bash to Command Prompt and it seems to be working okay and consistently (so far). So this may point to an issue sending text reliably to the Git Bash terminal. |
@MSLeiter Git Bash is currently not supported, we have an open item to support it: microsoft/vscode-python#15799 |
@karthiknadig The issue is that it does work, with these intermittent issues. For example, there are no path issues (Git Bash accepts mixed / and , as shown above). There is no warning or error given anywhere that Git Bash is not supported. Regardless, given the situation, this is additional information on what is needed to officially support Git Bash - there appears to be an interprocess communication issue with VS Code talking to Git Bash compared to other terminals, one where characters get added or missed. Somehow the buffer is not transferring characters cleanly. |
This seems to be an issue with how |
run-in-terminal
request send partial content.
Thanks for creating this issue! It looks like you may be using an old version of VS Code, the latest stable release is 1.70.2. Please try upgrading to the latest version and checking whether this issue remains. Happy Coding! |
Dropping random characters would probably be an issue behind sendText itself, or an issue with git bash itself - any idea @Tyriar? |
I had a peer try this out with Git Bash and he wasn't seeing the same issue - at least after several tries he didn't see it. The rest of our setups are pretty much the same. So, there may be something specific to my setup, but I'm not sure what that would be - maybe a specific extension I have loaded he doesn't, or a setting I changed in VS Code itself. So, the root cause may be something to do with a particular install version, extension, or configuration setting. Maybe even in the Git for Windows install, etc., but all this is on the same vanilla Windows 10 install from IT for very similar work PCs, with basically all the same applications installed. |
I have the exact same issue which has been occurring for a similar timeframe. I'll share all my versions and configurations to see if there's something in common. |
I seem to be having the same issue. For me it is happening very frequently, basically every time I try to use the debugger, so it became useless. I have Git Bash as integrated terminal on Windows. Version: 1.70.2 (user setup) |
The temporary solution for me on Windows was to switch to either Cmd or PowerShell as the default terminal. Until Git Bash is officially supported it is unlikely this will be fixed. Debugging seems to work fine for me out of those shell, and I can open a separate Git Bash for anything else I want to do. Note that swapping to cmd/PS also seems to fix the issue with both Run and Debug sometimes opening a new, separate, and duplicate terminal (name of "Python" for run and "Python Debug Console" for debugging). It now seems to always consistently reuse the existing window, if there was one. |
We have had problems with sendText dropping characters in the past, maybe they're still present on git bash. In the meantime you can switch to just cmd or pwsh for debugging and tasks by making an automation profile via the |
@Tyriar The Do I just really need to set the path to the cmd.exe or powershell executable? In fact, I can't figure out how to get to the various terminal settings for all the profiles to see the existing profiles - I remember there used to be a way to get there through the profile dropdown by the "create new terminal" + sign button, but it just takes you to settings now. |
@LightCC here are the automation profile docs https://code.visualstudio.com/docs/terminal/profiles#_configuring-the-taskdebug-profile You should still see a dropdown for profiles: |
/duplicate #100225 |
Type: Bug
Not sure the root cause, but with my setup, at least for Python files, there is an intermittent problem launching the debugger. Details:
NOTE: This has been happening intermittently for a long time, at least 6-9 months. Sometimes it's better, sometimes worse. Just haven't logged a defect because I can usually get it to launch within a few tries, but still very annoying.
Terminal output from "Python Debugger" terminal automatically opened when debugging:
Here's a 2nd example, where part of the prior command bled into the final prompt given back to the user. Note that the characters "env\Scripts\p" that were dumped on the final prompt appear to be missing from the middle of the command, where it says "\.envudate_inc_ids". They are also not just directly taken out of a chunk of the text, they are pulled out from multiple places - i.e. it should read "\.venv\Scripts\update_inc_ids", so the first v is missing completely, the en is duplicated both locations, then the \Scripts\ is moved, then p is from one character later, after the u. Also note that the "e" appears to be missing from "launcher" where it says "\debugpy\launchr", elsewhere in the text.
So, the text that is taken out is not just one chunk, but scrambled together from multiple places.
Extension version: 2022.12.0
VS Code version: Code 1.70.1 (6d9b74a, 2022-08-10T06:08:33.642Z)
OS version: Windows_NT x64 10.0.19044
Modes:
System Info
canvas_oop_rasterization: disabled_off
direct_rendering_display_compositor: disabled_off_ok
gpu_compositing: enabled
multiple_raster_threads: enabled_on
opengl: enabled_on
rasterization: enabled
raw_draw: disabled_off_ok
skia_renderer: enabled_on
video_decode: enabled
video_encode: unavailable_off
vulkan: disabled_off
webgl: enabled
webgl2: enabled
A/B Experiments
The text was updated successfully, but these errors were encountered: