Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

NullPointerException: MapboxNavigationEvent buildRerouteEvent #562

Closed
pjankowski90 opened this issue Dec 3, 2017 · 2 comments
Closed

NullPointerException: MapboxNavigationEvent buildRerouteEvent #562

pjankowski90 opened this issue Dec 3, 2017 · 2 comments

Comments

@pjankowski90
Copy link

Hi,

Sometimes when I want to finish running navigation, NPE occur.

Fatal Exception: java.lang.NullPointerException
       at java.util.Hashtable.put(Hashtable.java:442)
       at com.mapbox.services.android.telemetry.navigation.MapboxNavigationEvent.buildRerouteEvent(MapboxNavigationEvent.java:216)
       at com.mapbox.services.android.navigation.v5.navigation.NavigationMetricsWrapper.rerouteEvent(NavigationMetricsWrapper.java:114)
       at com.mapbox.services.android.navigation.v5.navigation.NavigationTelemetry.sendRerouteEvent(NavigationTelemetry.java:413)
       at com.mapbox.services.android.navigation.v5.navigation.NavigationTelemetry.flushEventQueues(NavigationTelemetry.java:286)
       at com.mapbox.services.android.navigation.v5.navigation.NavigationTelemetry.endSession(NavigationTelemetry.java:160)
       at com.mapbox.services.android.navigation.v5.navigation.MapboxNavigation.endNavigation(MapboxNavigation.java:394)

Used libraries:

compile 'com.mapbox.mapboxsdk:mapbox-android-services:2.3.0-SNAPSHOT'
compile 'com.mapbox.mapboxsdk:mapbox-android-plugin-locationlayer:0.2.0'
compile 'com.mapbox.mapboxsdk:mapbox-android-navigation:0.7.1-SNAPSHOT'
@danesfeder
Copy link
Contributor

Hey @pjankowski90, thanks for bringing this to us - will look into it and then update this ticket.

@danesfeder
Copy link
Contributor

Can you update your dependencies to just:

implementation ('com.mapbox.mapboxsdk:mapbox-android-navigation-ui:0.7.1-SNAPSHOT') {
        transitive = true
    }

Both android-services and the locationlayer are included when you do this and ensure you have the correct versions. Please let me know if you can reproduce after do this. Thanks!

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants