Skip to content

Dynamically update return-to-homebase directions during active walks #7

@ericmjl

Description

@ericmjl

Marcus suggested that directions back to homebase should dynamically update during an active walk based on the walker's current state.

Idea

When the user is walking and needs to return to homebase/start, Random Walker should update the return guidance using:

  • Current GPS location
  • Current observed walking pace
  • Planned vs completed walk progress
  • Remaining desired walk time or distance
  • Whether the user is ahead of or behind the original route expectations

Why

Today, return-to-start behavior detects when the user has returned near the start, and routeWalkingResume exists in code, but return guidance is not exposed as a dynamic user-facing flow during simplified guidance.

A more adaptive return-to-homebase experience would make walks feel safer and more responsive, especially if the user slows down, speeds up, deviates from the route, or wants to head back early.

Possible behavior

  • During an active walk, estimate remaining time/distance using the current or learned pace.
  • If the user chooses to return to homebase, route from current location back to the original start coordinate.
  • Periodically refresh return guidance when the user's location or pace meaningfully changes.
  • Consider progress through the planned walk so the app can choose between:
    • continuing the existing loop,
    • shortcutting back to homebase,
    • or fully replanning from the current location.

Acceptance criteria

  • The app can produce return-to-homebase walking directions from the current GPS fix.
  • Estimated return duration uses the same effective pace model as planning where appropriate.
  • Return guidance updates when the user materially deviates or their projected return time changes.
  • The UI clearly distinguishes "continue planned walk" from "return to homebase."
  • Behavior is documented in docs/in-app-navigation.md and, if pace logic changes, docs/walking-pace.md.

Relevant code/docs

  • WalkSessionViewModel.replanFromCurrentLocation
  • RoutingService.routeWalkingResume
  • WalkingPaceService
  • docs/in-app-navigation.md
  • docs/walking-pace.md

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions