Pio isnt recognizing the active workig project while compiling

hello peepz, i have a problem since pio got updated cuz i need to work on new codes now.

i the past i just needed to be in one project related file and the compiler only compiles all depent on the project, the file iam using for edit is in.

after updated pio to new core version i have for example a nanoatmeg328 project opened, copy some code from there, go into another project for example teensy or stm32, past the code and iam really in the main of a this project (not the nano project anymore). if i want to compile the compiler runs some nanoatmega328 stuff but i did changes to my teensy code which i want to compile. i already deinstalled visual code and pio but after reinstalling it behaves the same. anything i missed between the new core updates?

thank you all for help

best regards

It was observed that in newer PlatformIO extension version (the core is irrelevant for that), correct project selection can fail.

As countermeasures you can try and open the platformio.ini for the project that you want to compile, and then refreshing the project tasks.


You might also want to try the new beta version which has many fixes: PlatformIO IDE for VSCode 2.3 Beta – Help us with testing!

It explicitly has the project selection in the status bar now for switching, too.

thank you deeply <3 i will give it a try