vscode-cmake-tools icon indicating copy to clipboard operation
vscode-cmake-tools copied to clipboard

[Flaky]Duplicate information appeared in output when Add CMakePreset.json

Open PhoebeTf opened this issue 1 year ago • 0 comments

Brief Issue Summary

Environment: VSCode 1.90.1+ CMake Tools v1.19.13(pre-release)

More info:

  • Repro Language: ENU and loc languages
  • This is a flaky issue: repro rate 30%

Repro steps:

  1. Open VScode
  2. Create a new folder named 'Test' and open it with vscode.
  3. Create a file named CMakeLists.txt under test with the following content:
cmake_minimum_required (VERSION 3.8) 
project ("test") 
add_executable (test "test.cpp" ) 
  1. Create a file named test.cpp under test with the following content:
#include <iostream> 
int main(int argc, char **argv) 
{ 
std::cout << "Hello World" << std::endl; 
return 0; 
} 
  1. Create "CMakePresets.json" file and copy the following code into the file, then save it
{
"version": 3,
"configurePresets": [
{
"name": "windows-base",
"hidden": true,
"generator": "Ninja",
"binaryDir": "${sourceDir}/out/build/${presetName}",
"installDir": "${sourceDir}/out/install/${presetName}",
"cacheVariables": {
"CMAKE_C_COMPILER": "cl.exe",
"CMAKE_CXX_COMPILER": "cl.exe"
},
"condition": {
"type": "equals",
"lhs": "${hostSystemName}",
"rhs": "Windows"
}
}
]
}
  1. Launch output window and navigate to "CMake/Build" category
  2. Check the output info

Expected result: Without duplicate output info

Actual result: Duplicate output info appeared Dup_output

Whole process: CMakeTools_DupOutput

CMake Tools Diagnostics

No response

Debug Log

No response

Additional Information

No response

PhoebeTf avatar Jul 05 '24 02:07 PhoebeTf