-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
crashes on startup #12237
Comments
Could you please provide more information about what is causing the crash? Does it happen whenever you open any .cpp file? Could you provide a copy of your c_cpp_properties.json file? This should be in the .vscode folder |
Hi thanks for replying. It was occurring whenever I opened VS code. I have some folders in the workspace that was being opened when i opened vs code - raspberry pi/pico sdk etc but none with my own C++. (For context I'm just getting started with this dev environment on the mac and with the pi/pico.) There's no file by that name in .vscode in my home folder:
|
maybe this file? |
@m76589 The c_cpp_properties.json file would exist in your workspace folder's .vscode folder, but it won't exist unless you generated it via a command like C/C++: Edit Configuration. Without it, it uses defaults. With 1.20.1, we've added crash call stack logging if you check the Help->Toggle Developer Tools->Console. Otherwise, can you set C_Cpp.loggingLevel to "Debug" and check the "C/C++" pane logging to see what output occurs before the crash? Typically a crash restart will generate another "initialize" message. |
I've split my initial workspace into two smaller ones and the issue seems not to occur (only tested briefly). From the debug info in the console there's some information that shows before the crash about something being used before initialized. The crashes occur when i open the workspace.
|
@m76589 Can you try with 1.20.2 (pre-release)? It may be fixed in there or the crash call stack may be shown in the Console tab after using the 'Toggle Developer Tools' command. |
Ah. I see. Will do. |
@m76589 Also, I think Also, if you don't get any logging, can check if you have /Users/mm/.vscode/extensions/ms-vscode.cpptools-1.19.9-darwin-x64/bin/cpptools (or whatever the version is) and the file is runnable? |
Hi Sean Crash call stack:
C/C++ Logging:
|
above updated due to copy-paste error. |
Hi @m76589 . Did your repro involve multiple workspace folders in a multi-root workspace that may have resolved to the same folder, due to a symbolic link in the file system, or some other reason why multiple paths wind up referring to the same folder? We believe we've identified a problem, but it would seem specific to multiple workspace folders in a workspace resolving to the same path. If that is not your scenario, there may be more for us to investigate. |
Yes - I have/had two folders that were "added to workspace" that were sub folders of another top level workspace folder. |
Hi @m76589 . To clarify, the issue we've identified is specific to exactly the same 'workspace folder' being present multiple times in a multi-root workspace, at the root level. You would see exactly the same contents in both (or all such) workspace folders. Normally, it's not possible to add the same folder to a multi-root workspace twice, though VS Code does not appear to resolve symbolic links and can allow this to happen if the paths differ due to containing a symbolic link. If you can confirm whether or not this scenario is indeed what occurred in your repro, that would help us determine if we've addressed the issue or not. |
|
@m76589 We think this is fixed with https://github.com/microsoft/vscode-cpptools/releases/tag/v1.20.3 , although we weren't able to repro your exact scenario so it's possible there could be another failure after the fix we made. |
Type: Bug
using latest version 1.19.9 and tried with 1.18.5.
C++ crashes repeatedly on startup and is therefore diabled by vs code.
This report was generated using the bisect so I hope it gives the information required to fix.
Extension version: 1.18.5
VS Code version: Code 1.88.0 (Universal) (5c3e652f63e798a5ac2f31ffd0d863669328dc4c, 2024-04-03T13:28:18.899Z)
OS version: Darwin x64 21.6.0
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_graphite: disabled_off
video_decode: enabled
video_encode: enabled
webgl: enabled
webgl2: enabled
webgpu: enabled
A/B Experiments
The text was updated successfully, but these errors were encountered: