Skip to content
This repository was archived by the owner on Oct 22, 2021. It is now read-only.

Improve error message when using too old version of Arduino CLI #122

Closed
aentinger opened this issue Oct 30, 2019 · 1 comment
Closed

Improve error message when using too old version of Arduino CLI #122

aentinger opened this issue Oct 30, 2019 · 1 comment
Labels
type: enhancement New feature or request
Milestone

Comments

@aentinger
Copy link

Describe the bug
After downloading and starting the Arduino Pro IDE via command line I got an unresponsive IDE and ton's of error messages which I found out has to do with a too old version of arduino-cli.

To Reproduce

arduino-cli Version: 0.4.0 Commit: =98b7be9
wget https://downloads.arduino.cc/arduino-pro-ide/arduino-pro-ide-0.0.2-alpha.preview-linux64.tar.xz
tar -xvf arduino-pro-ide-0.0.2-alpha.preview-linux64.tar.xz
cd Arduino\ Pro\ IDE-v0.0.2-linux/ 

Note: spaces in the directory and commandline usage is an awkward combination.

./arduino.pro.ide

The result is the following error output + a unresponsive window (see screenshot):

alex@dragon:~/Downloads/Arduino Pro IDE-v0.0.2-linux$ ./arduino.pro.ide ```
> cd Arduino\ Pro\ IDE-v0.0.2-linux/ 
> ```^C
alex@dragon:~/Downloads/Arduino Pro IDE-v0.0.2-linux$ ./arduino.pro.ide 
root INFO Theia app listening on http://localhost:43835.
daemon INFO >>> Starting arduino-cli version: 0.4.0 commit: =98b7be9 daemon from /usr/local/bin/arduino-cli...
daemon INFO Error: unknown shorthand flag: 'v' in -v
daemon INFO Bad exit.
daemon INFO Error: unknown shorthand flag: 'v' in -v
daemon INFO Usage:
daemon INFO   arduino-cli daemon [flags]
daemon INFO Examples:
daemon INFO   /usr/local/bin/arduino-cli daemon
daemon INFO Flags:
daemon INFO   -h, --help   help for daemon
daemon INFO Global Flags:
daemon INFO       --additional-urls strings   Additional URLs for the board manager.
daemon INFO       --config-file string        The custom config file (if not specified the default will be used).
daemon INFO       --debug                     Enables debug output (super verbose, used to debug the CLI).
daemon INFO       --format string             The output format, can be [text|json]. (default "text")
daemon INFO Daemon exited with code: 1. Signal was: null.
root INFO Error: Command failed: "/usr/local/bin/arduino-cli" daemon -v --log-level info --format json --log-format json
Error: unknown shorthand flag: 'v' in -v
Usage:
  arduino-cli daemon [flags]

Examples:
  /usr/local/bin/arduino-cli daemon

Flags:
  -h, --help   help for daemon

Global Flags:
      --additional-urls strings   Additional URLs for the board manager.
      --config-file string        The custom config file (if not specified the default will be used).
      --debug                     Enables debug output (super verbose, used to debug the CLI).
      --format string             The output format, can be [text|json]. (default "text")


    at ChildProcess.exithandler (child_process.js:299:12)
    at ChildProcess.emit (events.js:182:13)
    at maybeClose (internal/child_process.js:962:16)
    at Socket.stream.socket.on (internal/child_process.js:381:11)
    at Socket.emit (events.js:182:13)
    at Pipe._handle.close (net.js:606:12)
daemon INFO <<< The 'arduino-cli' daemon is up an running.
...

2019-10-30-Arduino-Pro-IDE-Screenshot

Expected behavior
A error message saying "Please update your arduino-cli" or something similiar. It works with

arduino-cli Version: 0.6.0 Commit: 3a08b07

Desktop (please complete the following information):

  • Ubuntu 18.04.3 LTS
@aentinger aentinger added type: imperfection Something isn't working type: enhancement New feature or request and removed type: imperfection Something isn't working labels Oct 30, 2019
@mastrolinux mastrolinux added this to the v0.0.3 milestone Nov 26, 2019
@kittaakos
Copy link
Contributor

kittaakos commented Nov 28, 2019

@lxrobotics, thank you for the detailed bug report. We have changed the way we pick up and use the arduino-cli from the PATH. See: #142

I am closing it. The changes will be available with 0.0.3.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
type: enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants