appium/appium — pull request #356 by bootstraponline (2013-03-31 00:55:03+00:00)
Title: Reconnect after bootstrap disconnect

We don't know if the bootstrap has disconnected until a command is issued and
the uiautomator runtest command crashes. The crash is detected, uiautomator is
restarted, and the command that detected the crash is resent.

--

Sometimes there's this error `ADB failed to launch!` so I think there's a timing issue.