From 82af60115dfec446851091bc97be2a6e1b6d4a50 Mon Sep 17 00:00:00 2001 From: Martin Raifer Date: Mon, 4 Mar 2024 18:16:31 +0100 Subject: [PATCH] disalow splitting of closed roundabouts when they are part of a route these cases are not covered by the splitting algorithm at the moment: * typicall, only a part of the roundabout should be part of the resulting route * when multiple routes meet at a roundabout coming from different angles, the roundabout must be split at any of those entry/exit point simutaneously, such that all routes remain correct as a workaround, a mapper can remove the route relation(s) from the roundabout, split it accordingly and then re-add the respective parts to the relation(s) again. --- data/core.yaml | 1 + modules/actions/split.js | 3 +++ 2 files changed, 4 insertions(+) diff --git a/data/core.yaml b/data/core.yaml index 68bd982f7..e02459336 100644 --- a/data/core.yaml +++ b/data/core.yaml @@ -500,6 +500,7 @@ en: other: "Split {n} features." not_eligible: Lines can't be split at their beginning or end. parent_incomplete: This line cannot be split because it is part of a larger relation which has only been partially loaded. Make sure that all ways connected to this way are present on the map. + simple_roundabout: This line cannot be split because this roundabout is part of a larger relation. You must remove it from the relation first. connected_to_hidden: This can't be split because it is connected to a hidden feature. restriction: annotation: diff --git a/modules/actions/split.js b/modules/actions/split.js index 8e3a51d90..2039bc3e9 100644 --- a/modules/actions/split.js +++ b/modules/actions/split.js @@ -428,6 +428,9 @@ export function actionSplit(nodeIds, newWayIds) { } } } + if (way.tags.junction === 'roundabout' && way.isClosed()) { + return 'simple_roundabout'; + } } } }