Skip to content
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

Compile/Upload must retain control over started processes #3771

Closed
ffissore opened this issue Sep 8, 2015 · 16 comments
Closed

Compile/Upload must retain control over started processes #3771

ffissore opened this issue Sep 8, 2015 · 16 comments
Assignees
Labels
Component: Compilation Related to compilation of Arduino sketches Component: IDE The Arduino IDE Type: Bug

Comments

@ffissore
Copy link
Contributor

ffissore commented Sep 8, 2015

Right now processes are started but they are not under user control. User cannot stop or abort them, and hitting the buttons twice starts twice the processes.
Symptoms have been acknowledged in #3568 #2718 #2574 #2417 #766

@ffissore ffissore added Component: IDE The Arduino IDE Type: Bug Component: Compilation Related to compilation of Arduino sketches labels Sep 8, 2015
@ffissore ffissore self-assigned this Sep 8, 2015
@ffissore ffissore changed the title Compile/Upload must retain control over the running processes Compile/Upload must retain control over started processes Sep 8, 2015
@Testato
Copy link

Testato commented Sep 8, 2015

+1

@lmihalkovic
Copy link

[LMCHK]

@lmihalkovic
Copy link

It was straight forward to make the compilation process interruptible cleanly anytime with a java written driver. Dealing with arduino-builder cleanly is not as simple. Someone will have to modify builder to support this feature. The way i did it was to introduce a CoreJob (defined in core) class which conrains a isInterrupted() method that the java builder checks regularly. There is also a EditorJob subclass that has added UI only info (defined inside app). Doing it this way has the merrit of also solving the console problem (compilation output follows the active editor instead of remaining in the console fo the editor that started the compilation) by add a simple getOutput() and getError() to CoreJob. With this in place, all thats left is to replace all the System.xxx.print() in Compiler.jave with calls to job.getOut().println(). There is bit more to it if you replace the PumpThisThatTheOtherThing(), you get the idea.

@facchinm
Copy link
Member

facchinm commented Feb 5, 2016

Solved by #4482 (commit 3f07b8a)

@facchinm
Copy link
Member

Fixed by merging 6d5597b

@NicoHood
Copy link
Contributor

This is not fixed:
#3568

Upload a (larger) program to a 32u4 and unplug the device when uploading the code. It will freeze. And you still can reconnect, select a new port and upload again. So a) two processes are started and b) you still cannot abort.

@facchinm
Copy link
Member

The second time you click the upload button the stuck avrdude_bin gets killed (just tested with nighly, a Leonardo and an ArduBoy sketch). Are you on Linux ? (I believe so but I'm asking just to be sure 😄 )

@NicoHood
Copy link
Contributor

Sure I am on Linux ;)
Me as user (and as developer ;( ) expect an "abort" button. I am very afraid of pressing uploading twice, and after arduino was buggy about that for a long time now, me and others are afraid to even try this again. Its also not expected behavior. So a real "kill" aka abort button is appreciated.

@Testato
Copy link

Testato commented Apr 11, 2016

+1

@NicoHood
Copy link
Contributor

Testato we got this super thumbs up github feature now. Please use it.

@Testato
Copy link

Testato commented Apr 11, 2016

I do not understand :-)

@NicoHood
Copy link
Contributor

I am not sure if this is ironie. On the upper right hit the smiley button and select a thumbs up instead of posting +1

@Testato
Copy link

Testato commented Apr 11, 2016

now i understand, on the smartphone the new icon systems it is not visible.
So if you post by a smartphone, or directly by email, it is not possible use it

@facchinm
Copy link
Member

@NicoHood , I agree with you, an abort button could be far more understandable (it should only appear during upload, since compilation is going to end sooner or later).
I'm asking the UI team if it is the desirable feedback (then the PR should come in a matter of minutes, all the pieces and callbacks are in place )

@matthijskooijman
Copy link
Collaborator

@facchinm, I'm also planning to revisit this part of the code as part of my debugger work, so perhaps we should have a chat, probably including the UI folks as well?

@matthijskooijman
Copy link
Collaborator

woops, didn't mean to reopen

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component: Compilation Related to compilation of Arduino sketches Component: IDE The Arduino IDE Type: Bug
Projects
None yet
Development

No branches or pull requests

7 participants
@matthijskooijman @ffissore @lmihalkovic @NicoHood @Testato @facchinm and others