Start debugging Android application right after reboot?

You can wait for a debugger Debug.waitForDebugger().

You can wait for a debugger - Debug.waitForDebugger().

Close your emulator and Run the application directly in Debug and select the option to launch the emulator that you want to run it on.

Oh boy.. I am doing it all the time ;-) However problem appears when I reboot my phone. Debug is disconnected and I am too slow to reconnect it manually before first breakpoint appears. – hsz Oct 13 at 10:01.

This is an interesting workaround, however I am not looking for this kind of solution. – hsz Oct 13 at 15:04.

In this case logging is better solution than debuggung. I was able to see logs arising from BOOT_COMPLETE processing even in IDEA logcat window. (I also do not value step by step debugging very much, and prefer TDD approach anyway).

Sure thing, logging is way that I have to go right now, but debugging will be much better - we can do more with it. – hsz Oct 13 at 15:03 not always. You can sort out problems with receiving on boot complete broadcast with logging, and other problems later (I personally prefer mocking, which can be seen as scripted debugging session - I also write tests before actual code) – Konstantin Pribluda Oct 13 at 17:08.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions