skip to Main Content

I have lots of Log.d() messages for debugging purposes. These show up just fine in the Logcat panel of Android Studio when running the app on a connected physical device. But when running the same app on an emulator, these log messages don’t show in the Logcat.

This is for Android Studio Dolphin, and they’ve recently changed the Logcat panel, to show colours etc, but I’m not sure if it broke then or was broken before. Or whether I’m just missing an option somewhere.

Note that the Logcat panel now has a "package:mine" filter to show only log messages from your own app. This works for the physical device, but for the emulator it just filters out everything… nothing left. When the filter is disabled, there are system log messages appearing, so it seems to be just my own Log.d() messages that aren’t making it.

enter image description here

Android Studio Dolphin | 2021.3.1

3

Answers


  1. Chosen as BEST ANSWER

    OK so the next time I fired up Android Studio (with my PC having been restarted in the meantime) and then fired up the emulator again... now the logcat is showing output from the running app as I would expect. So it must have just been a temporary glitch, with the usual "turn it off and on again" solution working. I also notice (which I hadn't done before) that the "Run" tab also shows logcat output from the app (though not prettified with any colour) and I'm not sure if that would have shown logcat output even if there was nothing in the Logcat tab itself.


  2. Just ran into this same issue—happens with and without Patch 1. The workaround I uncovered was to, simply, disconnect the physical device. Once I did this, I could see all the logcat information from the emulated device. Pretty sad how this stuff escapes Quality Assurance testing.

    Login or Signup to reply.
  3. I had the same problem, It seems to be a bug, there are two options, I prefer the first way cause it doesn’t restart the whole IDE.

    First solution:
    Open the terminal from the bottom panel (tabs on the left corner).
    Run these two commands:

    adb kill-server
    adb start-server
    

    Second solution:
    Select the File menu > Invalidate Caches > Invalidate and Restart

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search