R30's shared-layer lists are hand-maintained and have drifted: airports/airport_points missing since #149 #201
Labels
No labels
blocked
claude-wip
map-report
map:is
map:se
needs-review
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
art/ismap#201
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
R30's two acceptance tests in
conf/shared/acceptance.yamlenumerate the sharedlayers by hand, and the list has drifted out of date twice without anyone
noticing.
airportsandairport_pointshave been missing since #149 foldedthem in.
What is missing
There are 18 shared contracts, 17 of them non-
internaland therefore tilelayers. R30 has two halves, and neither covers all 17:
The floor half ("a request below a layer's floor returns an empty tile",
26 checks) is missing
airportsandairport_pointsentirely — neitherthe z2 global-floor row nor the stop_z-1 row. Both have a deliberate
stop_zabove the global
min_zoom(airports 10, airport_points 8), so both belong inthe second group the test's own comment describes: "the layers whose floor is a
deliberate stop_z above the global one … the zoom just under that stop_z, so the
layer's OWN floor is exercised rather than only the global one".
The ceiling half ("a request above maxz serves the maxz table", 14 checks) is
missing
airports,airport_points,contoursandpeaks.Not hiding a bug
Measured against the current database, the four missing floor rows all return
0 bytes — they would pass as written:
zxy_map_airports(2,0,0)zxy_map_airports(9,0,0)zxy_map_airport_points(2,0,0)zxy_map_airport_points(7,0,0)So this is missing coverage, not a live failure. The floor half is a four-line
fix. The ceiling half is more work per layer: each row needs a tile where that
layer provably draws at maxz, measured live (the existing rows are a Stockholm
z15, a Tornio–Haparanda border tile, the Dalälven rapids, and so on), so
airports/airport_points/contours/peaks each need a tile picked and measured.
The thing actually worth fixing
The list is hand-maintained in a project whose shared-layer design is otherwise
"the catalogue knows what exists". Every fact these rows encode — the function
name, the
stop_z, themaxz— is already declared inconf/shared/contracts/*.yaml, which is why R119/R120 could become cataloguequeries that cover whatever countries exist. R30 is the check that did not make
that move, and it drifts once per fold: #149 added airports and airport_points
and neither reached the list; #151/#152 added contours and peaks and only the
floor half was updated (in !199, and only because the same PR was already
editing the test to drop
zxy_is).Two options:
shared layer's
stop_zandmin_zoom; it could emit the z2 and stop_z-1rows rather than have them typed. A new contract then inherits the check the
way it inherits R119.
set of
zxy_map_*functions inpg_procequals the set the R30 rows name —so a layer added without a row fails R30 instead of silently not being
covered.
The ceiling half probably cannot be fully generated (picking a tile where a
layer draws is a judgement about the data), but it could at least be made to
fail loudly when a layer has no row.
Notes
there, the airports pair did not, as it is outside that issue.
partition. Same shape of problem — a check that enumerates less than it claims.