Sorunome / arduino-upload

Atom Package for those who don't like the Arduino IDE
https://atom.io/packages/arduino-upload
MIT License
34 stars 7 forks source link

Error output when compiling doesn't show #21

Closed qub1750ul closed 7 years ago

qub1750ul commented 7 years ago

Atom 1.16.0 x64 Linux Mint 18.1 x64 Arduino 1.8.2

Sorunome commented 7 years ago

I can't reproduce, do you have any more information?

qub1750ul commented 7 years ago

In the meantime, i updated Arduino to 1.8.3 x64, Atom to 1.18.0 x64, and reinstalled the package in this moment. Now it didn't work at all. I've wrote the blink example in a new file created in Atom, then through the command palette i tried all the commands provided by the package. In every case the result is the disappearance of the arduino-upload commands in the command palette until i disable and re-enable the package, there isn't any output message from the package or atom itself about this. Using arduino by the CLI instead, works perfectly.

Sorunome commented 7 years ago

Do you see any errors in the debugging console? (Ctrl+Shift+i) What does the output when manually invocing via cli look like?

Am 9. Juli 2017 20:07:51 MESZ schrieb Giuseppe Masino notifications@github.com:

In the meantime, i updated Arduino to 1.8.3 x64, Atom to 1.18.0 x64, and reinstalled the package in this moment. Now it didn't work at all. I've wrote the blink example in a new file created in Atom, then through the command palette i tried all the commands provided by the package. In every case the result is the disappearance of the arduino-upload commands in the command palette until i disable and re-enable the package, there isn't any output message from the package or atom itself about this. Using arduino by the CLI instead, works perfectly.

-- You are receiving this because you commented. Reply to this email directly or view it on GitHub: https://github.com/Sorunome/arduino-upload/issues/21#issuecomment-313935743

qub1750ul commented 7 years ago

Just now Atom notified me about an incompatibility of the package becasue "build for a previous version of Atom", and offered me the possibility to fix it by clicking a button. Doing it actually made the package to work again. But when i introduce an error in the program the only output related to the error that i recive is "Build failed".

Opening the debug console i've found this error reported twice:

Could not connect to indexedDB  -> Event
/home/andrei/atom-1.11.1/out/app/node_modules/tree-view/lib/file.coffee:15378
EventdbOpenRequest.onerror @ /home/andrei/atom-1.11.1/out/app/node_modules/tree-view/lib/file.coffee:15378

When invoking arduino via cli the output is:

Sorunome commented 7 years ago

Do you use https://atom.io/packages/tree-view by any chance? If so, is the bug still present if you disable that? Thank you for your help in debugging this!

Am 9. Juli 2017 20:33:14 MESZ schrieb Giuseppe Masino notifications@github.com:

Just now Atom notified me about an incompatibility of the package becasue "build for a previous version of Atom", and offered me the possibility to fix it by clicking a button. Doing it actually made the package to work again. But when i introduce an error in the program the only output related to the error that i recive is "Build failed".

Opening the debug console i've found this error reported twice:

Could not connect to indexedDB  -> Event
/home/andrei/atom-1.11.1/out/app/node_modules/tree-view/lib/file.coffee:15378
EventdbOpenRequest.onerror @
/home/andrei/atom-1.11.1/out/app/node_modules/tree-view/lib/file.coffee:15378

When invoking arduino via cli the output is:

  • with a good program:
    Picked up JAVA_TOOL_OPTIONS:
    Loading configuration...
    Initializing packages...
    Preparing boards...
    Verifying...
    Sketch uses 4130 bytes (14%) of program storage space. Maximum is 28672
    bytes.
    Global variables use 149 bytes (5%) of dynamic memory, leaving 2411
    bytes for local variabl
    es. Maximum is 2560 bytes.
    Uploading...
  • with a program with an error:
    Picked up JAVA_TOOL_OPTIONS:
    Loading configuration...
    Initializing packages...
    Preparing boards...
    Verifying...
    /tmp/upino/upino.ino: In function 'void loop()':
    upino:8: error: 'gg' was not declared in this scope
    gg;
    ^
    exit status 1

-- You are receiving this because you commented. Reply to this email directly or view it on GitHub: https://github.com/Sorunome/arduino-upload/issues/21#issuecomment-313937090

qub1750ul commented 7 years ago

Disabling the tree-view package, compile errors are shown

Sorunome commented 7 years ago

so you disable the tree-view package and then things work as expected? Weird, I am still unable to reproduce your issue......

With exactly which command did you invoke compiling via CLI?

EDIT: mind posting the debugging output (ctrl+shift+i) with everything, including the non-errors?

qub1750ul commented 7 years ago

arduino --upload --board arduino:avr:micro --port /dev/ttyACM0 upino.ino

qub1750ul commented 7 years ago

In the debug console there are:

Could not connect to indexedDB  -> Event
/home/andrei/atom-1.11.1/out/app/node_modules/tree-view/lib/file.coffee:15378
EventdbOpenRequest.onerror @ /home/andrei/atom-1.11.1/out/app/node_modules/tree-view/lib/file.coffee:15378
arduino-upload.coffee [sm]:143 

/tmp/upino/upino.ino: In function 'void loop()':
upino:8: error: 'gg' was not declared in this scope
  gg;
  ^
Sorunome commented 7 years ago

Okay so the arduino-upload package detects the error message correctly and buffers it internally....for some reason doesn't display it, though.

Which theme packages do you use? It might not be able to create the text output box....

qub1750ul commented 7 years ago

I don't think that the theme is the problem. I've done a test both with the theme that i use recently ( a customized version of Atom Material ) and the theme that i used when i opened the issue ( One Dark ), with the tree-view disabled both work fine:

Some screenshots: Material - error One Dark - error

Material - succesful One Dark - succesful

qub1750ul commented 7 years ago

...and after i enable the tree-view package to do a test it magically works... WTF?

qub1750ul commented 7 years ago

Nothing is changed in the debug console.

Sorunome commented 7 years ago

Soooo.....does it reliably work when restarting atom now, magically?

qub1750ul commented 7 years ago

Yes, omitting that when the sketch is open in preview mode the message "File isn't part of an Arduino sketch!" appears, all works fine.

Sorunome commented 7 years ago

Okay cool, I'll close this issue then! If you have the feeling that the preview mode one needs a new issue ticket thing then please go ahead and open a new bug report ^.^

My guess is that atom somehow screwed up a bit with version upgrading and disabling- and enabling that tree-view package fixed some stuff.