Code change:
Does this issue occur when all extensions are disabled?: I dont know VS Code Version: 1.88.0-insider OS Version: Windows 10 - 10.0. Build Steps to Reproduce: Start debugging python script. It creates a new "debugging terminal". This should work stop debugging debugging. If you look at the debugging terminal, you will see a input (generated by VS Code) then command for debugging the selected file. path of the is somehow truncated, hence cannot find the file. debugging is however starting: you will be prompted with the message: Timed out waiting for launcher to connect. As seen on the gif below: Path 1st time: (Correct path) Path 2nd time: (truncated path) !
I'm getting similar behaviour when using Git Bash as default profile. First time debugging the Python Debug Console opens and the application runs without issue: the subsequent times I sometimes get: ... which does in fact executes the code, but then I also sometimes get: I don't know what the call to comes from (possible the end of the directory name, but in in the last instance is not called. This inevitable gives this error. ! Which then starts a new Python Debug Console. Similar to what is above. I don't see this behaviour when using PowerShell or Cmd. IMO There's some weird truncation happening. Version: 1.88.0 (user setup) Commit: Date: 2024-04-03T13:26:18.741Z Electron: 28.2.8 ElectronBuildId: Chromium: 120.0.6099.291 18.18.2 V8: 12.0.267.19-electron.0 OS: Windows_NT x64 10.0.
Thank you for adding details! This is the exact same problem that I experience: I didn't try with another terminal (Powershell or Cmd). I will see if that can fix my problem temporary using .
As mentionned by This issue is not here using . However, this is still adding extra command that could be the explanation behind it: ! The first run it is only using: On the second run, it : before the command. There is still the before this line though (2nd blank line)
I am seeing the problem when I set my default terminal profile to any of the following and run my debug launch script twice. Each shell will fail on the second launch with the same mangled command line. bash command prompt powershell Work around: revert back to vs code 1.87.
I am having a similar problem launching Python from VS.Code with or without debugging (both cmd and wt as terminal.external.windowsExec). If the path to the Python executable contains space as in default I end up with and an error message in the launched terminal window: Yet this works fine if I pick a Python interpreter from venv or somewhere else such that there is no space in path e.g. Curiously - the internal terminal and internal console work with either path
it seems sending the ctrl+c in a separate is not sufficient -- any suggestions?
If you want to execute something again we have a helper on the render process side , this conditionally sends a ^C and may wait for a shell integration prompt. That might work?
It looks like that does the same thing with a 100ms delay. I'll adopt the delay as well, see if that fixes it
please could you confirm when this will be released? It doesn't seem to have gone out in the latest April release. I've tried the insiders version and can't debug anything so it's even worse.
This is available on Insiders. Please open another issue with the details for not being able to debug anything; that's probably not related to this fix...
Can any of you verify that this is fixed in the newest version of VS Code Insiders? Thanks!
<!-- AUTHORVERIFICATIONREQUEST --This bug has been fixed in the latest release of ! you can help us out by commenting if things are now working as expected. If things still don't seem right, please ensure you're on version of Insiders (today's or later - you can use in the command palette to check), and leave a comment letting us know what isn't working as expected. Happy Coding!
The external terminal launch is working with space in pythonInterpreter path () using both and as Windows Terminal in current: 1.89.1 and insiders 1.90.0 /verified
Running on version 1.90.0 I can not longer observe the truncation. The execution command looks intact even after multiple runs. ! There's an extraneous whenever you start a run but I guess that's intentional.
I am experiencing this issue using Python Debugger: Current File with Arguments. I am using ver VSCode ver 1.9

Related discussion:
text: *  Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ <del> import { createCancelablePromise, firstParallel } from 'vs/base/common/async'; </del> <ins> import { createCancelablePromise, firstParallel, timeout } from 'vs/base/common/async'; </ins> import { IDisposable } from 'vs/base/common/lifecycle'; import * as platform from 'vs/base/common/platform'; import * as nls from 'vs/nls';