Skip to content

STDERR output from arduino-cli is not shown #1527

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
alranel opened this issue Mar 20, 2021 · 2 comments
Closed

STDERR output from arduino-cli is not shown #1527

alranel opened this issue Mar 20, 2021 · 2 comments
Assignees
Labels
conclusion: resolved Issue was resolved topic: code Related to content of the project itself type: imperfection Perceived defect in any part of project

Comments

@alranel
Copy link
Contributor

alranel commented Mar 20, 2021

The STDERR output from arduino-cli is not shown in the Output panel during compilation, even when the "Verbose" setting is enabled in the IDE preferences.

This has the effect of suppressing useful troubleshooting information. For instance:

% arduino-cli compile -b arduino:samd:mkrwifi1010
In file included from /Users/alranel/Documents/Arduino/OplaWidgets/OplaWidgets.ino:2:0:
/Users/alranel/Documents/Arduino/libraries/OplaUI/src/Arduino_OplaUI.h:5:10: fatal error: widget_direct.h: No such file or directory
 #include "widget_direct.h"
          ^~~~~~~~~~~~~~~~~
compilation terminated.
Multiple libraries were found for "SD.h"
 Used: /Users/alranel/Documents/Arduino/libraries/SD
 Not used: /Applications/Arduino.app/Contents/Java/libraries/SD

Error during build: exit status 1

When suppressing STDERR from the same command, it becomes pretty useless:

% arduino-cli compile -b arduino:samd:mkrwifi1010 2> /dev/null
Multiple libraries were found for "SD.h"
 Used: /Users/alranel/Documents/Arduino/libraries/SD
 Not used: /Applications/Arduino.app/Contents/Java/libraries/SD

This is how it is displayed in the IDE, leaving user with no clue about the compilation error (it ends with "Compilation error: Error: 2 UNKNOWN: exit status 1").

I don't know if including STDERR in the output panel in the IDE is the proper solution. For sure it's a workaround. Maybe the correct solution is to have arduino-cli print that kind of output to STDOUT instead? Proper STDOUT/STDERR semantics should be designed.

Version

2.0.0 beta4

@alranel
Copy link
Contributor Author

alranel commented Mar 21, 2021

This issue also applies whenever #including a library that is not installed. Compilation fails but IDE doesn't say that it's because of a missing library!

@per1234 per1234 transferred this issue from arduino/arduino-ide Oct 20, 2021
@per1234
Copy link
Contributor

per1234 commented Oct 20, 2021

Fixed by #1523

@per1234 per1234 closed this as completed Oct 20, 2021
@per1234 per1234 added topic: code Related to content of the project itself type: imperfection Perceived defect in any part of project conclusion: resolved Issue was resolved labels Oct 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
conclusion: resolved Issue was resolved topic: code Related to content of the project itself type: imperfection Perceived defect in any part of project
Projects
None yet
Development

No branches or pull requests

3 participants