mapbox / mapbox/mapbox-navigation-android
Voice instructions not working on low memory condition
Nobody has claimed this yet.
- Dominant language
- Kotlin
- Stars
- 651
- Forks
- 321
- PR merge metrics
- No merged PRs in 30d
Description
Android API: 16+
Mapbox Navigation SDK version: 0.43.0
It can be related to this issue
Steps to trigger behavior
When you lock the screen or press the home button to put the navigation into the background, It can be killed by Android in low memory condition (or any other conditions that cause navigation activity to get destroyed).
The problem is that users can't get any voice instruction while their phone is locked.
Expected behavior
Voice instruction must be working on low memory condition, like Waze.
Actual behavior
On low memory condition:
- Android kills the navigation Activity
- stopNavigation will be called so it unbinds the
NavigationService - There is no foreground service to deliver voice instructions.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing stopNavigation in libandroid-navigation/src/main/java/com/mapbox/services/android/navigation/v5/navigation/MapboxNavigation.java and how it unbinds NavigationService when the Activity is destroyed. Reproduce the background or low-memory scenario, then verify that voice instructions continue after the navigation Activity is killed.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, kotlin
- Domain
- mobile
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100