Opened 3 years ago
Closed 3 years ago
#20681 closed defect (fixed)
[Patch] Unnecessary tag area=yes not reported for waterway=riverbank
Reported by: | Owned by: | GerdP | |
---|---|---|---|
Priority: | minor | Milestone: | 21.10 |
Component: | Core validator | Version: | |
Keywords: | Cc: |
Description
The combination natural=water
+ area=yes
reports an unnecessary tag error, because area=yes
is not needed.
This warning should also be shown for waterway=riverbank
+ area=yes
.
Attachments (2)
Change History (17)
by , 3 years ago
Attachment: | riverbank_area_yes.osm added |
---|
comment:1 by , 3 years ago
Milestone: | → 21.10 |
---|---|
Owner: | changed from | to
Status: | new → assigned |
Summary: | Unnecessary tag area=yes not reported for waterway=riverbank → [Patch] Unnecessary tag area=yes not reported for waterway=riverbank |
This should fix it:
-
resources/data/validator/unnecessary.mapcss
30 30 fixRemove: "{2.key}"; 31 31 } 32 32 33 /* #14256, #15664 */33 /* #14256, #15664, #20681 */ 34 34 area:closed[highway=rest_area][area?], 35 35 area:closed[highway=services][area?], 36 36 area:closed[aeroway=aerodrome][area?], 37 way:closed[waterway=riverbank][area?], 37 38 area:closed[aeroway=helipad][area?] { 38 39 throwWarning: tr("{0} is unnecessary for {1}", "{2.tag}", "{1.tag}"); 39 40 group: tr("unnecessary tag");
comment:2 by , 3 years ago
We have a general mapcss rule for area=*
on MP-Relations, mean-while. Probably, all area
could be changed to way
up front.
comment:3 by , 3 years ago
Good catch. I didn't use way instead of area intentionally, I just started with a different block containing rule
way:closed[natural ][area?],
comment:4 by , 3 years ago
I just tried a multipolygon with natural=way + area=yes and there is no warning that area=yes is not necessary for multipolygons (also not without the patch). What's wrong?
follow-up: 7 comment:5 by , 3 years ago
Do you have a selection, maybe only the way and not the relation?
* Warnings (2) * area on a relation (1) * Unknown property value - Value 'way' for key 'natural' is unknown, maybe 'bay' is meant? (1) * Other (1) * No area style for multipolygon (1)
comment:7 by , 3 years ago
comment:8 by , 3 years ago
Which test produces the area on a relation
message? Maybe a local version?
comment:9 by , 3 years ago
Nice try, no I made sure to disable all my local files and enable all core rules.
geometry.mapcss
comment:10 by , 3 years ago
Oops, sorry, I meant natural=water + area=yes. I see the test
relation[area?] { throwWarning: tr("{0} on a relation", "{0.key}"); fixRemove: "{0.key}"; }
but it doesn't seem to work for my example. Have to debug this ...
comment:11 by , 3 years ago
natural=water
+ area=yes
on MP relation:
* Warnings (1) * area on a relation (1) * Other (1) * missing tag - natural=water without water (1)
by , 3 years ago
Attachment: | 20681.patch added |
---|
comment:14 by , 3 years ago
Milestone: | 21.11 → 21.10 |
---|
Simple test case demonstrating the issue