Skip to content
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

Actual C_Cpp.default.configurationProvider randomly changes #13038

Open
myocytebd opened this issue Dec 10, 2024 · 0 comments
Open

Actual C_Cpp.default.configurationProvider randomly changes #13038

myocytebd opened this issue Dec 10, 2024 · 0 comments

Comments

@myocytebd
Copy link

myocytebd commented Dec 10, 2024

Environment

  • OS and Version: Linux x64 6.8.0-49-generic (Ubuntu 22.04.5 LTS)
  • VS Code Version: 1.95.3
  • C/C++ Extension Version: v1.22.11
  • ms-vscode.makefile-tools: v0.11.13
  • mesonbuild.mesonbuild: v1.26.0

Bug Summary and Steps to Reproduce

Bug Summary:
Unexpected C_Cpp.default.configurationProvider modification appear in C/C++: Log Diagnostics, although setting is not modified.
As a result, some files' intellisense is incorrect.

  1. My project happens to have a broken meson.build file and valid autotools/makefile.
  2. Ensure that C_Cpp.default.configurationProvider is always ms-vscode.makefile-tools.
  3. Use vscode and run make/configure.
  4. After some time, intellisense of some (newly opened or created) files went wrong.
    Check C/C++: Log Diagnostics and find out that compiler/flags are wrong.
    Further check C/C++: Log Diagnostics and find this:
Modified Settings:
{
    "C_Cpp.default.configurationProvider": "mesonbuild.mesonbuild"
}
  1. However, this setting was never changed.
    Check settings and command palette: setting is ms-vscode.makefile-tools.
  2. In command palette: set configurationProvider to None then back to ms-vscode.makefile-tools. And the problem seems temporarily fixed:
    Intellisense is back to normal, and mesonbuild.mesonbuild is gone from C/C++: Log Diagnostics.
  3. Change makefile-tools version (and restart extension), or reload windows, also have a chance to trigger the unexpected Modified Settings.

Configuration and Logs

`C/C++: Log Diagnostics` is not persistent.  
I don't know the exact condition to reproduce this issue (or if it is random).

Other Extensions

No response

Additional context

Expected Behavior:

  • If for some reason, ms-vscode.makefile-tools fails, actual C_Cpp.default.configurationProvider should fallback to None instead of an unpicked provider.
  • If actual C_Cpp.default.configurationProvider changed, an error/warning message should be presented to user.
  • ms-vscode.makefile-tools should not fail.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant