Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to get rid of "This app is causing your device to run slowly" notification (app development time)?

Tags:

android

galaxy

When an Android app is being developed, debugged, and tested, there is a lot of code exceptions being occurred. Almost each exception causes an Android device (Galaxy Note 3, Android 5.0 - if it matters) pops up the annoying "This app is causing your device to run slowly" notification with crash statistics and suggestion to uninstall the app. Is there any way to get rid of this annoying notification?

Selecting the app as a debug app in Developer Options does not help.

like image 776
Zmiter Avatar asked Dec 06 '15 23:12

Zmiter


1 Answers

There can be many reasons for this to be happening. For instance:

  • Too many exceptions being thrown from within a possibly infinite loop
  • Race conditions between threads and/or poorly implemented spinlocks
  • Excessive debug verbose (try reducing the amount of messages or tuning the severities)
  • Unnecessary screen and/or components re-drawing (see this article about UI optimization)

Of course these are very generic points that should be analysed carefully.

like image 152
marcelovca90 Avatar answered Nov 10 '22 03:11

marcelovca90