Closed hbruch closed 2 months ago
OSM way 89300522 with tags highway=living_street and cycleway:opposite should have ALL permissions.
highway=living_street
cycleway:opposite
ALL
It has PEDESTRIAN_AND_BIKE permissions:
PEDESTRIAN_AND_BIKE
diff --git a/src/test/java/org/opentripplanner/openstreetmap/tagmapping/GermanyMapperTest.java b/src/test/java/org/opentripplanner/openstreetmap/tagmapping/GermanyMapperTest.java index 00b1049bdd..178dea8ca9 100644 --- a/src/test/java/org/opentripplanner/openstreetmap/tagmapping/GermanyMapperTest.java +++ b/src/test/java/org/opentripplanner/openstreetmap/tagmapping/GermanyMapperTest.java @@ -263,6 +263,15 @@ public class GermanyMapperTest { assertEquals(wps.getDataForWay(steps).getPermission(), StreetTraversalPermission.PEDESTRIAN); } + @Test + void setCorrectPermissionsLivingStreetWithCyclewayOposite() { + // https://www.openstreetmap.org/way/89300522 + var street = new OSMWithTags(); + street.addTag("highway", "living_street"); + street.addTag("cycleway", "opposite"); + assertEquals(wps.getDataForWay(street).getPermission(), StreetTraversalPermission.ALL); + } + @Test void testGermanAutobahnSpeed() { // https://www.openstreetmap.org/way/10879847
https://github.com/opentripplanner/OpenTripPlanner/commit/49436441cf399d12ce5bd051a874bcdee7ab9e30
http://download.geofabrik.de/europe/germany/baden-wuerttemberg/karlsruhe-regbez-latest.osm.pbf
The following code defines PEDESTRIAN_AND_BICYCLE as default permission, which is widened to ALL for many highway classes, but not living_street.
PEDESTRIAN_AND_BICYCLE
living_street
https://github.com/opentripplanner/OpenTripPlanner/blob/eced14ee6d8d8dfb24b644279fc09832ca590b41/src/main/java/org/opentripplanner/openstreetmap/tagmapping/DefaultMapper.java#L362-L365
This issue is stale because it has been open 90 days with no activity. Remove stale label or comment or this will be closed in 30 days
Expected behavior
OSM way 89300522 with tags
highway=living_street
andcycleway:opposite
should haveALL
permissions.Observed behavior
It has
PEDESTRIAN_AND_BIKE
permissions:Testcase to reproduce
Version of OTP used (exact commit hash or JAR name)
https://github.com/opentripplanner/OpenTripPlanner/commit/49436441cf399d12ce5bd051a874bcdee7ab9e30
Data sets in use (links to GTFS and OSM PBF files)
http://download.geofabrik.de/europe/germany/baden-wuerttemberg/karlsruhe-regbez-latest.osm.pbf
Suspected Reason
The following code defines
PEDESTRIAN_AND_BICYCLE
as default permission, which is widened toALL
for many highway classes, but notliving_street
.https://github.com/opentripplanner/OpenTripPlanner/blob/eced14ee6d8d8dfb24b644279fc09832ca590b41/src/main/java/org/opentripplanner/openstreetmap/tagmapping/DefaultMapper.java#L362-L365