square / leakcanary

A memory leak detection library for Android.
https://square.github.io/leakcanary
Apache License 2.0
29.42k stars 3.97k forks source link

No leak notification #752

Closed panwarab closed 6 years ago

panwarab commented 7 years ago

On screen rotation, a message appears "dumping data, app will freeze,Brrr" but when I open Leaks app no data is being displayed regarding leak or dump. I have correctly performed all the steps mentioned in the FAQs. Please suggest a solution. I am sure that leak is happening because I have viewed the hprof files in the android studio itself after deploying analyze tasks. It clearly shows several instances of main activity being leaked but none in leaks app.

jrodbx commented 7 years ago

1) What version of LeakCanary are you using? 2) On what API version are you running your app? 3) Can you share your hprof?

Also, be sure to exclude weak, phantom and soft references when analyzing your hprof for extra activity instances.

panwarab commented 7 years ago

What version of LeakCanary are you using?

leakcanary-android:1.5.1

On what API version are you running your app?

API 21 i.e. Lollipop

Can you share your hprof?

Link to G-Drive

JakeWharton commented 7 years ago

Upload to Google Drive or Dropbox and share a link

On Tue, May 2, 2017 at 10:37 AM Abhiroj notifications@github.com wrote:

What version of LeakCanary are you using?

leakcanary-android:1.5.1

On what API version are you running your app?

API 21 i.e. Lollipop

Can you share your hprof?

How to share it?

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/square/leakcanary/issues/752#issuecomment-298654431, or mute the thread https://github.com/notifications/unsubscribe-auth/AAEEEebRjyQcgWCAbsjIYwySy4nN05_-ks5r1z90gaJpZM4NNbq1 .

panwarab commented 7 years ago

@JakeWharton @jrodbx I have updated my comment, sharing the hprof via google drive

It is a .tar file with a size of 7 MB, actual file size is 33 MB.

flossokay commented 7 years ago

I too get the same result for leakycanary versions 1.5 and 1.5.1, but not 1.4. I have tested this on a MotoG 3rd generation and nexus 5.

panwarab commented 7 years ago

I gotta try1.4 then

anthony3444 commented 7 years ago

Hi guys! I have the same problem: nothing to show on Canary App.

I tried on Samsung S5, MotoG4, same problem. The hprof is well generated. Thanks

hanhmh1203 commented 6 years ago

any update, I got the same problem.

anthony3444 commented 6 years ago

I found the problem couple of months ago: I've used JRebel Android plugin, and this plugin is not compatible with Leakcanary... So you have it, just run your App to standard way from Android Studio (not with JRebel).

pyricau commented 6 years ago

We should run the LeakCanary code in a test against this hprof and see what comes out, or otherwise close this.

pyricau commented 6 years ago

Confirmed there are 11 leakcanary weaks refs in this hprof.

LeakCanary should never be silent, it always calls back with something, unless developers provide a custom service to handle results.

I'm not sure how to investigate this further.

CreaterXu commented 6 years ago

i got a same problem, on Nexus5 well,but smartion T1 not show the notifcation

pyricau commented 6 years ago

1003 should help a bit by introducing Android notifications for every step which should help understand where this is stuck (if stuck anywhere).

pyricau commented 6 years ago

The 1.6 release provides step by step progress notification, which should let devs know whats up and where leakcanary is stuck. If leakcanary is actually stuck or not doing anything this won't solve it, but at least we'll get reports with step information. Closing, someone will report more details and maybe we can some day repro (heap dumps didnt tell us why leakcanary was stuck)