-
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
Running code using the run button in VSC delayed #24239
Comments
@anthonykim1 This looks like Shell integration taking too long. If we need to use |
Related on Stack Overflow: VS Code 1.94 - Run selection/line in Python terminal very slow |
Thanks for filing this @FraidOfWater. I'm looking into resolving this. Could you set your log level to trace and share the logs for Python? |
…endtext. (#24248) For some reason, it seems like shell integration may take awhile to get activated: #24239 Performance issue seemed to indicate exactly 3 second coming from the https://github.com/microsoft/vscode-python/pull/24078/files#diff-5290f3097d5f92e3495c8abfbe095dff83c3f8de3dcac08ab2d0304f71bb412fR93, so lets try reducing this to 0.5 second and let user fall back to sendText. We may need further investigate why onDidChangeTerminalShellIntegration may be taking awhile.
Hey @anthonykim1 , thanks for replying. Here is my VSC stack trace for python. I hope this is what you meant. It was my mistake for not including it. https://pastebin.com/pxPePWgX Edit: I seem to have posted the diagnostic data wrong. It says Extension version: 2024.14.1 although It is really 2024.16.0. I must've downgraded and reported it then. I have added corrected diagnostic data at the end. Edit: Full trace logs here (I figured how to set it as default so it traces when starting up VSC): I do get this new delay also on another machine. Note I turn tracing on only after VSC has started with ">Developert:Set Log Level" to trace all
This is what happens in the new version:
It looks like the lines from the old version:
and the lines from the new version:
don't match for repeated pressing, I seem to get this as the only difference:
Also I do not know the significance of this, but for both versions I do get this error next to the terminal Correct diagnostic data: Extension version: 2024.16.0
User Settings
Installed Extensions
System Info
A/B Experiments
|
…endtext. (#24248) For some reason, it seems like shell integration may take awhile to get activated: #24239 Performance issue seemed to indicate exactly 3 second coming from the https://github.com/microsoft/vscode-python/pull/24078/files#diff-5290f3097d5f92e3495c8abfbe095dff83c3f8de3dcac08ab2d0304f71bb412fR93, so lets try reducing this to 0.5 second and let user fall back to sendText. We may need further investigate why onDidChangeTerminalShellIntegration may be taking awhile.
…endtext. (#24248) For some reason, it seems like shell integration may take awhile to get activated: #24239 Performance issue seemed to indicate exactly 3 second coming from the https://github.com/microsoft/vscode-python/pull/24078/files#diff-5290f3097d5f92e3495c8abfbe095dff83c3f8de3dcac08ab2d0304f71bb412fR93, so lets try reducing this to 0.5 second and let user fall back to sendText. We may need further investigate why onDidChangeTerminalShellIntegration may be taking awhile.
Could you try the latest pre-release version of Python extension? This would've gotten better with #24248 Let me know if you have any complains. Thanks! |
Yeah you guys fixed it already in version 16.1 it seems! Super smooth now, all good, cheers! |
Happy to hear that, please let us know here or in new issue if this problem ever occurs again :) |
Type: Performance Issue
Code executes only after a large delay on the newest version when excecuted from vsc's "run" button.
Diagnostic data
Output for
Python
in theOutput
panel (View
→Output
, change the drop-down the upper-right of theOutput
panel toPython
)Behaviour
The command to run the script isn't inserted into the terminal until after a large delay. This doesn't happen if you manually do ctrl+F5 or F5.
Old perfromance: (v.2024.14.1)
![Code_QtxmNuMFwv](https://private-user-images.githubusercontent.com/141600613/373452243-28cff078-147a-4cd0-90f6-85b233926b63.gif?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mzk1NTUzNzksIm5iZiI6MTczOTU1NTA3OSwicGF0aCI6Ii8xNDE2MDA2MTMvMzczNDUyMjQzLTI4Y2ZmMDc4LTE0N2EtNGNkMC05MGY2LTg1YjIzMzkyNmI2My5naWY_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjUwMjE0JTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI1MDIxNFQxNzQ0MzlaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT1kYmEzNTg0YzE0NDM1MDVlZDczODNkOWZjMzIzYzdiZDIyOGM1Y2ZkOTMxMjFhZTMyM2RiY2Y3N2JmMzk4MTYyJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCJ9.KChyMsnR9WmiJJ8IBMeapZsk6fSH7eiBWWy9VEw3Vyc)
New performance: (The only changed component is that this version is v.2024.16.0.
![Code_VV9mwyYHQ8](https://private-user-images.githubusercontent.com/141600613/373452283-9f4eb5ff-85ed-4eb3-aaac-c8b6f6a98f43.gif?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mzk1NTUzNzksIm5iZiI6MTczOTU1NTA3OSwicGF0aCI6Ii8xNDE2MDA2MTMvMzczNDUyMjgzLTlmNGViNWZmLTg1ZWQtNGViMy1hYWFjLWM4YjZmNmE5OGY0My5naWY_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjUwMjE0JTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI1MDIxNFQxNzQ0MzlaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT0wNzUyNzgxYjkzNzRhMmE1NjM2ZDM3M2ZkYWEyNDRjNmQ2NWE2NjQ0ZDRhMTA5MmM2N2I4ZjM3NGMwYmE1MjhlJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCJ9.KwllAQhvKLyyDJbljbyKpAs7H0KHKbHGOAXMefpUydk)
Steps to reproduce:
Diagnostic data
Output for
Python
in theOutput
panel (View
→Output
, change the drop-down the upper-right of theOutput
panel toPython
)Extension version: 2024.14.1 (mistake, I reported the bug from the previous version, correct bugged version is 2024.16.0)
VS Code version: Code 1.94.0 (d78a74bcdfad14d5d3b1b782f87255d802b57511, 2024-10-02T13:08:12.626Z)
OS version: Windows_NT x64 10.0.22631
Modes:
python.languageServer
setting: DefaultUser Settings
Installed Extensions
System Info
canvas_oop_rasterization: enabled_on
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_graphite: disabled_off
video_decode: enabled
video_encode: enabled
vulkan: disabled_off
webgl: enabled
webgl2: enabled
webgpu: enabled
webnn: disabled_off
Process Info
Workspace Info
A/B Experiments
The text was updated successfully, but these errors were encountered: