Open albydnc opened 3 years ago
I had this same issue. I think this was the line which was causing the error in my case. Installing Arduino IDE and removing CLI, then modifying the path to IDE fixed my problem.
I had the same error output:
[Starting] Update package index files...
dummy
Invalid argument passed: invalid item dummy
[Error] Exit with code=7
This is what I did to workaround the issue:
arduino-cli
config by executing:arduino-cli config init --additional-urls https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json
arduino-cli core update-index
. You'll see the following output:Updating index: package_index.json downloaded
Updating index: package_index.json.sig downloaded
Updating index: package_esp32_index.json downloaded
After performing the above, I could view the esp32
package in in the Arduino Board Manager and install it successfully.
My settings.json
{
"arduino.path": "/opt/homebrew/bin/",
"arduino.useArduinoCli": true,
"arduino.commandPath": "arduino-cli",
"arduino.additionalUrls": "https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json"
}
Mac OS 11.6.2
(Big Sur) on M1
VS Code 1.63.2
VS Code Arduino Extension 0.4.8 preview
Arduino CLI 0.20.2
installed using Homebrew
Hope this helps.
Thanks @phan-t worked like a charm on ubuntu
https://github.com/microsoft/vscode-arduino/issues/1388#issuecomment-974882923
I think this was the line which was causing the error in my case.
I think you're right about that, I quickly searched the extension's code for dummy
and that line hasn't been touched in 6 years and specifically mentions the IDE.
Installing Arduino IDE and removing CLI, then modifying the path to IDE fixed my problem.
Although I can see how that would get around it, it's probably not the ideal workaround, especially due to https://github.com/microsoft/vscode-arduino/issues/1477 currently requiring the CLI as a workaround if 2.0 is installed
https://github.com/microsoft/vscode-arduino/issues/1388#issuecomment-1010547815 is probably the best, and I might try submitting a PR to fix later
Any updates on this? I am trying to use the bundled arduino-cli so the suggestion here does not work (I mean, I do not know what is the path to use for arduino-cli in that case).
Re: location of bundled arduino-cli, if on Windows, check under:
C:\Users\YOUR_USERNAME\.vscode\extensions\vsciot-vscode.vscode-arduino-0.5.0-win32-x64\assets\platform\win32-x64\arduino-cli
So basically, you guys want to move to the bundled arduino-cli in the future, and it does not work if one adds custom boards... What a great idea.
Can you try switching to the pre-release version? It includes #1611 which should fix this issue. I'll try to get another official release out soon.
I just published non-pre-release version 0.6.0 to the marketplace as well, which also includes #1611.
This appears to still be broken as of v0.6.230727001
if using mac don't forget ide permissions https://github.com/microsoft/vscode-arduino/issues/1681#issuecomment-1747890450
@SergioGCarvalho thank you so much, that did the trick for me!
When passing the additionalUrls setting, the board manager can't update and the terminal says:
Tried with a single string and in an array, same results. My settings.json is:
VSCode version
1.62.3 ccbaa2d27e38e5afa3e5c21c1c7bef4657064247 x64
Arduino extension versionv0.4.8 preview
Arduino CLI versionarduino-cli alpha Version: 0.19.3 Commit: 12f1afc2 Date: 2021-10-12T10:15:19Z