Water polygons cross national borders and two partitions draw the same lake — 1 438 km² doubled at the SE/FI border #197
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#197
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?
Found while reviewing !195 (Greece's water_bodies), but it is not a Greece
problem and not a water_bodies problem — it is what happens when a feature that
crosses a national border meets a table partitioned by country. Greece is only
where it was visible, because Prespa is 86% not Greek. Sweden and Finland are
already drawing 1 438 km² of the same water twice, today, on the live map.
Measured
Area of each country's
map_water_bodies_14partition falling outside thatcountry's own
map_country_mask_0, over polygons larger than 5 km²(EPSG:3857 areas, the unit these tables are in):
Iceland is the control: no land neighbour, nothing outside. Poland's 3 934 km²
is almost entirely
Morze Bałtyckie, the Baltic slab mislabelled as a lake —that is #43 and not this issue.
The two remaining classes are different failures and want different fixes:
Straddling — one real feature shared with a neighbour. Greece: ΛΙΜΝΗ ΜΕΓΑΛΗ
ΠΡΕΣΠΑ (493 km², 423 outside — Albania and North Macedonia), ΛΙΜΝΗ ΔΟΪΡΑΝΗ (69,
39 outside), ΛΙΜΝΗ ΜΙΚΡΗ ΠΡΕΣΠΑ (83, 8). The WFD publishes a lake water body as
one polygon regardless of which state it lies in, so the whole lake arrives.
Verified against
gr_perifereies(the administrative extent, inland waterincluded), not just the mask; interior lakes come back 0 km² outside, which is
the control for the measurement. Finland's 27 straddlers (116 km²) sit at
68.7°N / 25.2°E — the Torne–Muonio–Könkämä border chain.
Wholly outside — a polygon entirely on the other side of its own mask.
Sweden 44 (613 km²) at 67.4°N / 23.1°E, Finland 47 (736 km²) at 67.0°N /
24.9°E: the same corridor, mirrored. This is not shared water, it is each
country's source and each country's mask disagreeing about where the border
runs, or coastal/archipelago water that the mask does not cover.
It is already visible, and it is not additive
In the SE/FI border box (19–27°E, 65–70°N), 745 polygon pairs from the two
partitions overlap, 1 438 km² of doubly-drawn water. Decoded tile
zxy_map(11, 1142, 475)over Kilpisjärvi:water_bodies features=49— 38 fromse, 10 fromfi, of which 24 pairs overlap inside that one tile, 94 km².The largest overlaps are at 68.5–69.0°N / 20.7–22.0°E, the Treriksröset corner.
Water is one colour, so two stacked polygons look like one — which is exactly
why this has survived. What it costs: every such feature is paid for twice in
tile bytes and in the generalization cascade, and the moment a shared feature is
named it is labelled twice by two partitions that cannot see each other.
Greece's lakes are all named; Albania is simply not imported yet, so the label
collision is scheduled rather than absent.
Why it is a shared-table question, not a per-country one
There is one
zxy_map_water_bodiesreading every country's parent tables, so"whose lake is this" has no answer inside a single country config — which is the
same shape as the problem
docs/unification.mdWorkstream B exists for, and thewater form of the question the world carve asks for land (#186: at a coast we
must carve, at a land border we must not, and the data cannot tell them apart).
Options, none of them free
straight edge through open water where no edge exists — Prespa would end
mid-lake at the border. Also needs a mask good enough to clip against, which
is the #186 problem again.
geometrically, but it needs a rule for which partition wins, and the tile
function currently unions partitions without looking at them.
intersection is largest, say), and let the others drop it. Cheap to compute,
survives a neighbour being added later, and is a real decision recorded in the
data rather than a rendering trick.
every country that has it. Honest, and it makes the label duplication a known
cost rather than a surprise.
Whatever the answer, it wants an acceptance test that fails when a country's
partition carries area outside its own mask beyond a documented allowance —
today that test would go red for four of the five countries, which is the point.
Not in scope
measurement happens to rank first.
cover,roads,railwaysandwaterwayslayers were not measured. Thesame question applies to every one of them; a border river's centreline is the
obvious next case.
Measured 2026-08-20 against the live database, after !194 and !195 merged
(main
ebdaa34).