Skip to content

Publish the off-trail numbers as data, not only as prose - #10

Merged
eamon-b merged 1 commit into
mainfrom
access-twins
Sep 13, 2026
Merged

eamon-b merged 1 commit into
mainfrom
access-twins

Conversation

@eamon-b

@eamon-b eamon-b commented Sep 13, 2026

Copy link
Copy Markdown
Owner

Adds GPX <extensions> under the tn: namespace (offTrailKm, acceptsBoxes, and accessMode/accessName when the source has them) to every resupply site and its turnoff. No waypoint is renamed, retyped or moved; <wpt> count unchanged. Consumed by trail-maps' resupply selection (plans/resupply-selection.md).

🤖 Generated with Claude Code

https://claude.ai/code/session_016zeWKEHNbEm4J3KZLwKPvy

A resupply point's description says "70.0 km off trail" and "Accepts resupply
boxes", and a planner wanting to act on either has to parse English out of it.
The turnoff waypoint says the same thing again in its own sentence. Neither is
something a program should be reading.

So both waypoints now carry an `<extensions>` block in a `tn:` namespace of
our own: `offTrailKm`, `acceptsBoxes`, and `accessMode` and `accessName` where
`data/resupply.json` has them - which today is nowhere, so those two elements
are simply absent rather than guessed. The turnoff declares the same block as
the place it serves, so either waypoint on its own says how far away the other
is, and `offTrailKm` is read off the same `offTrailMeters` the description
sentence is written from, so the prose and the data cannot drift apart.

`writeGpx` has no hook for extensions, so they go in by position afterwards,
with the waypoint counts checked against each other rather than trusted. The
block is last in each `<wpt>`, where GPX 1.1 wants it, every element in it is
optional, and a reader that does not know the namespace ignores the whole
thing: every waypoint in the file is byte-identical to the last build except
for gaining one, and no CSV moves at all.

`accessName` and `accessMode` are now read from `data/resupply.json` where
present. Filling them in is the most useful correction anyone can send.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016zeWKEHNbEm4J3KZLwKPvy
@eamon-b
eamon-b merged commit dbd1882 into main Sep 13, 2026
1 check passed
@eamon-b
eamon-b deleted the access-twins branch September 13, 2026 10:10
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