I've been looking for some information about an issue related with the debugger on Android Studio (I'm using 2.2.3 version) and I have found this two links:
How to stop debug without closing app in Android Studio 2
unanble to detach debugger from Android Studio 2.2.3
They say that, in order to detach debugger and keep on running the app, you should click on "Close" button instead of "Stop" button, but this doesn't work for me. When I click "Close" button I get a dialog like this:
I keep unchecked the "Terminate the process after disconnect" option, but when I click on "Disconnect" the debugger detaches, which is correct, but the application stops too, which I guess it's not the expected result.
Any idea? Is this a bug in the latest version of Android Studio? Perhaps that functionality does not longer exist or maybe it is now attached to another button?
Thanks in advance.
David.
Debugger Isn't Working: Disconnected or Client not ready yetThis is usually a signal that the emulator instance is not properly connected with ADB and Android Studio. There are a few steps to try: First, try uninstalling the app from within the emulator and then restarting the emulator completely.
You can start a debugging session as follows: Set some breakpoints in the app code. In the toolbar, select a device to debug your app on from the target device drop-down menu. If you don't have any devices configured, then you need to either connect a device via USB or create an AVD to use the Android Emulator.
Click Stop Debugging on the Debug menu to stop the target's execution and end the target process and all its threads. This action enables you to start to debug a different target application. )
If it is stuck waiting for a debugger means it is not attached to the app. You have to manually attach by clicking on Attach Debugger to Android process. It is on the right side of the run icon.
I have just updated to 2.3 version of Android Studio and I think this issue is solved now:
I don't really know if this worked lin the previous version too, but anyway this is how the debugger can be detached without stopping the app.
Bye!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With