Skip to content

"Switch SDK" doesn't update tasks.json #206

@maqifrnswa

Description

@maqifrnswa

Describe the bug
Using "Switch SDK" from 2.1.1 to 2.2.0 keeps references to "command": "${env:HOME}/.pico-sdk/picotool/2.1.1/picotool/picotool"

This will cause builds to fail if SDK 2.1.1 is uninstalled or otherwise not present, even after switching to 2.2.0.

Extension Logs
N/A

To Reproduce

  1. Create a C/C++ project in 2.1.1
  2. "Switch SDK" to 2.2.0

Expected behavior
I'd expect that references to 2.1.1 should be removed (e.g., so that you can delete the 2.1.1 SDK without problems).

Also, CMakeLists.txt has set(picotoolVersion 2.2.0) even though tasks.json has "command": "${env:HOME}/.pico-sdk/picotool/2.1.1/picotool/picotool"

Screenshots
If applicable, add screenshots to help explain your problem.

Platform (please complete the following information):

  • OS: Windows 11
  • Architecture: x86

Additional context
This was found in a class sharing code that was created with 2.1.1, switched to 2.2.0, then shared with students that had 2.2.0 but not 2.1.1.
Related to this, I'm not totally sure what the best practice is for sharing projects. I see .gitignore ignores .vscode, and pico-examples both does not share .vscode or pico_sdk_import.cmake. To avoid the above issue, you could remove .vscode and .build then "import project." In the past, "import project" was problematic (mangling CMakeLists.txt), but maybe it is stable enough to use? If it is, then this issue might be more about documenting what "Import Project" does and how to use it. thank you!

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions