PlatformIO Community

Project Inspection does not start

The last time I checked, Project Inspection worked on my machine, it was a year or more ago.
Now it doesn’t start.

If I try to Inspect Memory, I get an error message:
PIO Core Call Error: “DLL load failed: A megadott eljárás nem található.”
The Hungarian part means something like the given procedure cannot be found.

If I try to Check Code, I get an error message:
Bad JSON

What should I do in order to get closer to the root cause?

Please do

  • open a CLI and execute pio upgrade --dev
  • Restart VSCode

Can you build the project? Does project inspection work now?

Thanks for the quick reply, but this did not help.
The error messages remained.

Well there definitely shouldn’t be a DLL error message in PlatformIO.

Can you do a full reinstall?

  1. Remove the PlatformIO VSCode extension and close VSCode
  2. Remove the folder C:\Users\<user>\.platformio\ full
  3. Reinstall VSCode extension
  4. Retry

Now it starts the memory inspection, it reaches 90%, there it becomes slow, takes minutes to increment the percentage one by one. The same happens with the code inspection. Does it make sense to wait several minutes? will it eventually finish?

Again, I get the original message. I am now repeating the uninstall/install procedure to find the weak point. My impression is that there is something strange with the Atmel SAM package, because it seems to be installed but both installing and uninstalling it never ends. I’ll let you know if I find out something.

This time memory inspection did not complain for a missing dll. The progress bar reached 90% in a few seconds. Now, after 17 mintutes it still shows 100% since several minutes.

Hi Max,

After 40 minutes:
Inspecting… Memory: 100%

Do you have any ideas how to find the cause?

I am getting closer:
After installing everything, in the same session inspection seems to start but stucks at 100%.
If I close and reopen VS Code, the next time I receive the DLL load failed and Bad JSON messages.

That is totally not good.

Does an antivirus software interefere here maybe?

Can you test memory usage on the simplest project possible, https://github.com/platformio/platform-atmelavr/tree/develop/examples/arduino-blink?

Checked Defender, “no recent actions”.

I also do have a very small AVR project, tried that. Same result.

In the meantime I found out that also other features are blocked by missing dll:

image
image

Does it make sense to uninstall/reinstall VSCode (not just PIO)?

Can you again open a CLI and post the output of pio platforms update?

PS D:\PIO\Duett\DEV> pio platform update
Platform atmelsam

Updating platformio/atmelsam 5.1.1 [Up-to-date]
Updating platformio/framework-arduino-sam 1.6.12 @ ~1.6.12 [Up-to-date]
Updating platformio/framework-cmsis 1.40500.0 @ ~1.40500.0 [Up-to-date]
Updating platformio/framework-cmsis-atmel 1.2.0 @ ~1.2.0 [Up-to-date]
Tool Manager: Removing toolchain-gccarmnoneeabi @ 1.90301.200702
Tool Manager: toolchain-gccarmnoneeabi @ 1.90301.200702 has been removed!

I don’t understand why toolchain-gccarmnoneeabi @ 1.90301.200702 has been removed. Starting a build afterward installed it again:

Tool Manager: Installing platformio/toolchain-gccarmnoneeabi @ 1.90301.200702

Tried the GUI platform updates again, it still does not work claiming a dll.

Well then it’s mysterious to me how it works in the CLI though without a DLL error and an error in VSCode home.

@ivankravets do you have any ideas here?

1 Like

Please uninstall unofficial Pythons from a system including Anaconda. Remove %USERPROFILE%/.platformio/penv folder. Restart VSCode.

Wow. Yes. This was it.
Now I remember that I heard the same earlier, but I did not realize that somehow I had a miniconda installed. Now I removed it, and voilá.

How can such an installed Python harm PIO? I thought, PIO brings and starts its own python directly. Isn’t it possible to avoid this issue without deinstalling other pythons?

Thank you!
You have just solved also my second problem (could not start debugging)!

Now everything works.

(Except that platform updates removes my compiler, see above. Shall I open a separate ticket?)