Skip to content

feat(path): add total path distance display#198

Open
codemonkeybr wants to merge 1 commit into
agessaman:mainfrom
codemonkeybr:feat/path-distance
Open

feat(path): add total path distance display#198
codemonkeybr wants to merge 1 commit into
agessaman:mainfrom
codemonkeybr:feat/path-distance

Conversation

@codemonkeybr

@codemonkeybr codemonkeybr commented Jun 14, 2026

Copy link
Copy Markdown

Summary

  • Sums the haversine distance from sender → through each intermediate repeater → to the bot and appends it to the path command response
  • Silently omitted when any node in the chain has no known coordinates in the database (to avoid showing an inaccurate partial distance)
  • Controlled by show_path_distance config flag (default: true)
  • Adds distance_traveled translation key for all 10 supported locales (de, en-GB, es, fr, fr-CA, nl, pl, pt-BR, pt, en)

Example output:

26: Auburn Off-Leash
14: Repeater-NE
📏 12.4 km traveled

Test plan

  • Send a path command from a node with known coordinates through repeaters with known coordinates — distance line should appear
  • Send a path command where one repeater has no coordinates in DB — distance line should be silently omitted
  • Set show_path_distance = false in config — distance line should never appear
  • Verify all locale translations render correctly by switching locale in config

Sum the haversine distance from sender through each repeater to the bot
and append it to the path response. Silently omitted when any node in
the chain has unknown coordinates. Controlled by show_path_distance
config flag (default: true).

Add distance_traveled translation key for all 10 supported locales.
@codemonkeybr

Copy link
Copy Markdown
Author

Dear maintainer, dont merge just yet. im running some live tests on my local mesh with other folks helping me, i think there is a bug.

@codemonkeybr

Copy link
Copy Markdown
Author

Someone has reported a bug, but aint a bug, was an expected behaviour, sender didnt have coords enable on adverto so bot didnt count the sender -> repeater distance.

Good to merge

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant