Logcat not showing debug level messages
Asked Answered
L

3

20

For some reason I'm able to see messages of all levels Log.i() and above, but not the Log.d() or Log.v() levels. Haven't had much luck finding a reason for this. Anyone have any idea how to fix this?

Some further details: This is not an issue with me forgetting to select the appropriate level in the logcat dropdown in Eclipse. The log messages in question don't show up on an app I have for logcat tracking on my phone either. (debug log messages are showing up from other apps though). I am running OSX.

Lundin answered 25/10, 2012 at 6:54 Comment(5)
This has been going on for a very long time. Restarting eclipse is not the issue. Additionally, I have an app on my phone that shows me the logcat output, and it doesn't show the Log.d() level output either. It shows it for my coworker though, so it's not an issue with the project itself--at least, shouldn't be.Lundin
In logcat screen, there is a dropdown to indicate log levels. Select verbose in thatFennec
@Fennec that doesn't solve the problem.Lundin
Alternatively you can check your logcat in command line. goto your /android-sdk-linux/platform-tools directory and type adb logcat.Confirm your debug logs are showing here or not?Polariscope
@juned No, not showing up there either.Lundin
L
15

Turns out I had to enable the appropriate logging level directly through ADB.

$ ./adb shell stop
$ ./adb shell setprop log.tag.MYTAG VERBOSE
$ ./adb shell start

This solved the problem. Seems like a pain to do that every time I restart my phone though.

Lundin answered 26/10, 2012 at 1:48 Comment(2)
./adb shell setprop log.tag.MY_APP_TAG VERBOSE works for me. It enabled debug output for my application on Sony Xperia XA. ./adb shell stop|start requires root and, probably, not needed.Suffrage
On a Xperia XA1 I found out using adb shell getprop that the property log.tag was set to I. Setting it to V using adb shell setprop log.tag V worked for me.Perlite
M
9

There's a way to set the appropriate logging level globally (for all apps) on Amazon Fire TV Stick. The command to enable VERBOSE level:

adb shell setprop persist.log.tag V
Monodic answered 14/12, 2022 at 23:34 Comment(0)
P
-1

Also keep in mind, some manufacturers may restrict logging. (Eg. Huawei - Huawei, logcat not showing the log for my app?). If nothing works, try running on different mobile, or try to find a phone specific solution.

Picaresque answered 10/1, 2017 at 21:10 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.