#16458 closed defect (fixed)
False positives with roles guidepost and information in hiking routes
Reported by: | Davidleci | Owned by: | team |
---|---|---|---|
Priority: | normal | Milestone: | 18.07 |
Component: | Internal preset | Version: | latest |
Keywords: | role guidepost information route hiking | Cc: | Klumbumbus |
Description
Dear JOSM team:
I do not understand why JOSM warn me about errors relating to guidepost in route relations. I included a guidepost into two hiking routes and JOSM told me that it did not know the role guidepost for type route relations.
Can you download this node (https://www.openstreetmap.org/node/5680431998) with JOSM and tell me where is the error that I cannot find?
Excuse me for not writing from my computer. I like editing with JOSM, but this summer I have not much time for it.
Thank you for your work.
Attachments (1)
Change History (13)
comment:1 by , 6 years ago
Keywords: | role route hiking added; roles: removed |
---|---|
Milestone: | → 18.07 |
comment:2 by , 6 years ago
Component: | Core → Internal preset |
---|
by , 6 years ago
Attachment: | bugroles.png added |
---|
comment:3 by , 6 years ago
Cc: | added |
---|
Bug fixed with a chunk:
<chunk id="walking_routes_roles"> <roles> <role key="" text="route segment" requisite="required" type="way,closedway" member_expression="highway|route=ferry"/> <role key="" text="infrastructure" requisite="optional" type="node,closedway" member_expression="tourism OR amenity"/> <role key="" text="natural" requisite="optional" type="node,closedway" member_expression="natural=peak OR natural=volcano OR mountain_pass=yes OR natural=water OR tourism=viewpoint OR amenity=drinking_water OR natural=spring OR place=locality"/> <role key="guidepost" text="guidepost" requisite="optional" type="node" member_expression="information=guidepost"/> </roles> </chunk>
But this causes this bug, the chunk is duplicated:
Did you see this problem already? Maybe there's an other ticket.
comment:4 by , 6 years ago
No I didn't see this before as we don't have roles defined in chunks in the internal preset until now.
However by a quick check I can't reproduce your bug. roles in chunks work fine for me, i.e. displayed only once. Did you double check that you didn't accidently double reference the chunk or chunk + "normal" roles?
comment:5 by , 6 years ago
This is what I did:
-
data/defaultpresets.xml
438 438 <chunk id="motorcycle_brands"> 439 439 <multiselect key="brand" text="Motorcycle brand" values="Aprillia;BMW;Ducati;Gilera;Harley-Davidson;Honda;Kawasaki;KTM;Kymco;Piaggio;Peugeot;Piaggio;Suzuki;Triumph;Vespa;Yamaha" values_no_i18n="true" /> 440 440 </chunk> 441 <chunk id="walking_routes_roles"> 442 <roles> 443 <role key="" text="route segment" requisite="required" type="way,closedway" member_expression="highway|route=ferry"/> 444 <role key="" text="infrastructure" requisite="optional" type="node,closedway" member_expression="tourism OR amenity"/> 445 <role key="" text="natural" requisite="optional" type="node,closedway" member_expression="natural=peak OR natural=volcano OR mountain_pass=yes OR natural=water OR tourism=viewpoint OR amenity=drinking_water OR natural=spring OR place=locality"/> 446 <role key="guidepost" text="guidepost" requisite="optional" type="node" member_expression="information=guidepost"/> 447 </roles> 448 </chunk> 441 449 <!-- Link chunks --> 442 450 <chunk id="link_contact_address"> 443 451 <preset_link preset_name="Contact (Common Schema)" /> … … 11693 11701 <optional> 11694 11702 <reference ref="route_hikebike_optionals" /> 11695 11703 </optional> 11696 <roles> 11697 <role key="" text="route segment" requisite="required" type="way,closedway" member_expression="highway|route=ferry"/> 11698 <role key="" text="infrastructure" requisite="optional" type="node,closedway" member_expression="tourism OR amenity"/> 11699 <role key="" text="natural" requisite="optional" type="node,closedway" member_expression="natural=peak OR natural=volcano OR mountain_pass=yes OR natural=water OR tourism=viewpoint OR amenity=drinking_water OR natural=spring OR place=locality"/> 11700 </roles> 11704 <reference ref="walking_routes_roles" /> 11701 11705 </item> <!-- Hiking Route --> 11702 11706 <item name="Walking Route" icon="presets/misc/route.svg" type="relation" preset_name_label="true"> 11703 11707 <link href="https://wiki.openstreetmap.org/wiki/Tag:route=foot" … … 11711 11715 <optional> 11712 11716 <reference ref="route_hikebike_optionals" /> 11713 11717 </optional> 11714 <roles> 11715 <role key="" text="route segment" requisite="required" type="way,closedway" member_expression="highway|route=ferry"/> 11716 <role key="" text="infrastructure" requisite="optional" type="node,closedway" member_expression="tourism OR amenity"/> 11717 <role key="" text="natural" requisite="optional" type="node,closedway" member_expression="natural=peak OR natural=volcano OR mountain_pass=yes OR natural=water OR tourism=viewpoint OR amenity=drinking_water OR natural=spring OR place=locality"/> 11718 </roles> 11718 <reference ref="walking_routes_roles" /> 11719 11719 </item> <!-- Walking Route --> 11720 11720 <item name="Riding Route" icon="presets/misc/route.svg" type="relation" preset_name_label="true"> 11721 11721 <link href="https://wiki.openstreetmap.org/wiki/Tag:route=horse"
comment:6 by , 6 years ago
OK, I couldn't reproduce because I used the reference only once. It seems it is displayed so often like the reference is used. (3 times reference used => 3 times the roles in the preset dialog for these 3 presets)
The plugin tagging presets tester is not happy about this code too.
follow-up: 10 comment:8 by , 6 years ago
Could you please fix the tagging-presets-tester plugin too?
comment:10 by , 6 years ago
Replying to Klumbumbus:
Could you please fix the tagging-presets-tester plugin too?
What's wrong with it? I was able with r14001 to open it without problem. Didn't test prior r13999 though.
comment:11 by , 6 years ago
There was an error message but it works fine for me now too. I'm not sure which version I tested. Much likely it was fixed with r13999.
Replying to davidjulianez@…:
Because
guidepost
is not a defined role in the JOSM route presets.But I see this is documented and the OSM database contains 48519 members with
guidepost
role.