You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Debugging isn't stopped by apk install failure #329
The failure, on Flutter's side, is here. My guess is that either a signal is being sent and DC isn't picking it up, or there's no signal being sent here. I'll find time to test the same scenario with IntelliJ to see how it stacks up.
@Skylled Is there an easy way I can repro this sort of failure? I just tested by having no devices attached, but it seemed to handle it fine (flutter run terminated, which ends the debug session). Not sure if it's since been fixed or whether it's a different type of failure.
I checked the code, and it looks like as long as flutter run terminated, we should disconnect fine (by sending TeminatedEvent). This isn't new code, so I wonder if flutter run isn't terminating correctly in this case.
I'll see if I can repro by disconnecting the device during deployment or something.
Okay, so I traced out the error message Error launching application on {device} to runHot in resident_runner which is hooked into run in HotRunner, which is called by the flutter run command, and in this case should use throwToolExit to throw an exception and stop the program.
Maybe it's abruptly ending, and not sending a signal to DC?
We hook when the process exits which should fire in all cases :( I'll see if disconnecting during deployment causes same behavior.. should be easy to fix if so!
Activity
Skylled commentedon Jun 20, 2017
Relevant logs from IntelliJ
DanTup commentedon Jul 6, 2017
@Skylled Is there an easy way I can repro this sort of failure? I just tested by having no devices attached, but it seemed to handle it fine (
flutter runterminated, which ends the debug session). Not sure if it's since been fixed or whether it's a different type of failure.Skylled commentedon Jul 6, 2017
No, I wish. I can't even get a solid repro for the flutter devs.
flutter runjust quits when the problem comes up.It's an edge case, that I wish I wasn't part of.
DanTup commentedon Jul 6, 2017
I checked the code, and it looks like as long as
flutter runterminated, we should disconnect fine (by sendingTeminatedEvent). This isn't new code, so I wonder ifflutter runisn't terminating correctly in this case.I'll see if I can repro by disconnecting the device during deployment or something.
Skylled commentedon Jul 6, 2017
Okay, so I traced out the error message
Error launching application on {device}torunHotin resident_runner which is hooked intorunin HotRunner, which is called by the flutter run command, and in this case should usethrowToolExitto throw an exception and stop the program.Maybe it's abruptly ending, and not sending a signal to DC?
DanTup commentedon Jul 6, 2017
We hook when the process exits which should fire in all cases :( I'll see if disconnecting during deployment causes same behavior.. should be easy to fix if so!
DanTup commentedon Jul 7, 2017
Yanking the cable during an install results in same behaviour - debugger doesn't disconnect.
DanTup commentedon Jul 7, 2017
I've raised flutter/flutter#11103 - seems like
flutter run --machineis incorrectly (IMO) not terminating after an install failure.DanTup commentedon Jul 7, 2017
I've added some code to terminate the flutter process when it sends an
app.stopevent in the meantime.