WARN/ActivityManager(78): Launch timeout has expired, giving up wake lock! -> what is this

前端 未结 4 1688
别那么骄傲
别那么骄傲 2020-12-11 13:41

As the title indicates i get this \"error\" when running my little app:

WARN/ActivityManager(78): Launch timeout has expired, giving up wake lock!

相关标签:
4条回答
  • 2020-12-11 14:07

    This error means your Activity is taking to long to start. If you are doing a lot of processing on the UI thread, Android kills your application. You should use AsyncTask for any processing intensive stuff.

    If you could post your code and your SDK version, I can provide more help. There is also another thread on stackoverflow about this. Activity idle timeout for HistoryRecord?

    0 讨论(0)
  • 2020-12-11 14:11

    I had a similar problem retrieving a result from a php file in a server. I had solved putting php code inside <html> tags. Without them the app was hanging there.

    Hope it helps

    0 讨论(0)
  • 2020-12-11 14:12

    I had a similar problem.
    Inside my View.dispatchDraw(), I was calling a method that triggered another dispatchDraw().
    (Adding a logline inside my dispatchDraw() showed that the function was called continuously. This did not show up when doing method profiling in Eclipse)

    Hope this is helpful to someone.

    0 讨论(0)
  • 2020-12-11 14:16

    Check if you don't have 2 or more Eclipse IDEs open (if that is your IDE of choice). It is possible that one of those is taken control over the parts of the ADB and refusing the others access. In my case, I experienced the same error, but when I closed every other Eclipse instance, the app started in debug mode immediately.

    0 讨论(0)
提交回复
热议问题