-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Stop tracking unwanted trips in fleet mode on iOS #234
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Can you also change the NSLog
messages related to fleet transitions to the LocalNotificationHandler
logs so that we can see them on real phones and real trips?
Co-authored-by: K. Shankari <k.shankari@nrel.gov>
Changes to fleet logs compiled and ran. I couldn't verify if it shows in the actual phone log but it shows in the Xcode log.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
🥳 Congratulations to @catarial for the first merge 🎉 |
Before this fix, we checked for fleet status only in the EXITED_GEOFENCE case. This meant that the VISIT transitions started trip tracking, which led to spurious trips. Fixed by adding a fleet check to this case as well. Related PR: e-mission/e-mission-data-collection#234 Related release: https://github.com/e-mission/e-mission-data-collection/releases/tag/v1.9.0
Unwanted trips where there is no BLE beacon are happening on iPhone when using a fleet server. This is caused by not checking for fleet mode when receiving a VISIT_ENDED transition.
This can be tested by using an opcode for a fleet server then forcing a transition into VISIT_ENDED. In the unpatched code this triggers a trip start.
Log showing trip start:
This was fixed by simply ignoring a VISIT_ENDED transition for fleet mode.
Log after patch, trip doesn't start: