5

My Device: Sony Xperia XA1 Nougat(7.0)

I want to show a log on Android Monitor like this:

public static final String  TAG   = MainActivity.class.getSimpleName();
public static final boolean DEBUG = true;

if(DEBUG) Log.d(TAG, "onResume()");

But..when I open the monitor window, I can't see this log even the log level is Verbose/Debug. I only can see I/W/E level on Android Monitor, and it always show:

I/art: Enter while loop...

Is it a security issue?

Thank you very much!

荊鈺傑
  • 49
  • 4
  • 1
    Just replace `DEBUG` with `BuildConfig.DEBUG` – Mehran Zamani May 22 '17 at 03:54
  • Is the device rooted? From Android 4.1 onwards ANY logcat app needs root access in order to show logs properly. As per this: https://play.google.com/store/apps/details?id=scd.lcex&referrer=utm_source%3Dgoogle%26utm_medium%3Dorganic%26utm_term%3Dlog+cat+extreme+play+store&pcampaignid=APPU_1_TSpQWdPED8TSgAaUg4SQCw – intrepidis Jun 25 '17 at 21:27
  • 2
    I have the same issue. This is new on Sony XA series with Android 7. There isn't seem to be any way to enable Debug logs so far – nLL Jul 10 '17 at 14:30
  • Same here using a Sony XA1 @nLL – Carla Urrea Stabile Aug 16 '17 at 12:21
  • 2
    I added `^(?!(Enter while loop.))` to Logcat > Edit Configurations > Logcat Message to avoid seeing it while we wait for a solution. This seems to be a flag left by a developer. – Carla Urrea Stabile Aug 16 '17 at 12:33
  • Please refer this: https://stackoverflow.com/questions/49351870/logcat-messages-not-shown-with-xperia-xa1-ultra – Reejesh PK Apr 07 '18 at 06:23
  • You can refer this: https://stackoverflow.com/questions/49351870/logcat-messages-not-shown-with-xperia-xa1-ultra – Reejesh PK Apr 07 '18 at 06:24

0 Answers0