-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Mapbox memory leak crashes app when LeakCanary is enabled #8477
Comments
@cvance can you share the code of the related to mapview, location engine and location engine listener? |
I'm able to reproduce the crash using this sample activity, LeakCanary 1.5 and Mapbox SDK 5.0 and Mapbox UI 2.0 on my Nexus 6P (7.1.2beta) |
Same issue reported in MAS. |
I fixed this by removing all location permission from the manifest. There is a suggestion to use tools:remove in the manifest in the upstream bug, but I have not figured that out yet. |
@cvance, would you be able to retest this with latest SNAPSHOT? I'm thinking that #8825 might have resolved the issue (not able to reproduce with that code). Installation instructions for SNAPSHOT: repositories {
mavenCentral()
maven { url "http://oss.sonatype.org/content/repositories/snapshots/" }
}
dependencies {
compile ('com.mapbox.mapboxsdk:mapbox-android-sdk:5.1.0-SNAPSHOT@aar') {
transitive=true
}
} |
I'm able to reproduce still with 5.1.0-SNAPSHOT. Side note, it also appears to crash Pixel XL on launch, somewhere in native code. |
In #8872, I'm updating LOST to the latest 2.30-SNAPSHOT. |
I'm going to close this issue, so we have more clarity on the milestone related to the LOST issue. I'm opting to track this in #9139 as we have a PR tackling that in #9142. In this PR we working on resolving the current outstanding upstream issues (lostzen/lost#213). Thank you all for chipping in, continuing this issue in #9139. |
Not entirely sure if this is a Mapbox bug (or Mapzen or LeakCanary or a bug in my code) but I believe it is. Either way this seems to stem from a memory leak in Mapbox.
Platform: Android
Mapbox SDK version: 5.0.0
Steps to trigger behavior
Expected behavior
LeakCanary catches a memory leak from Mapbox
Actual behavior
LeakCanary crashes the app. Disabling LeakCanary seems to resolve this crash.
The text was updated successfully, but these errors were encountered: