Modify

Opened 5 months ago

Closed 5 months ago

Last modified 5 months ago

#17765 closed enhancement (fixed)

[Patch] Move code for error "Area style way is not closed" to UnclosedWays

Reported by: GerdP Owned by: team
Priority: normal Milestone: 19.05
Component: Core validator Version:
Keywords: Cc: Klumbumbus

Description

Don't know why this message is produced by MultipolygonTest instead of UnclosedWays.

The message is produced for unclosed ways with e.g. just one tag highway=services.

The attached patch moves the corresponding code from MultipolygonTest to UnclosedWays
and the message to the error group "Unclosed way" with new error code 1131 (old was 1609)

@Klumbumbus:
With r15094 we get two messages for such a way with highway=services. Is that intended?

Attachments (1)

17765.patch (5.3 KB) - added by GerdP 5 months ago.

Download all attachments as: .zip

Change History (11)

Changed 5 months ago by GerdP

Attachment: 17765.patch added

comment:1 Changed 5 months ago by Klumbumbus

For the example tag combination from #17623 (highway=trunk + junction=yes) on a unclosed way the "Area style way is not closed" warning doesn't show up, thats why I wasn't aware of that test while creating r15094.

The "Area style way is not closed" test and the second rule in r15094 have little different goals. (The first "assumes" the area is not closed, i.e. error in geometry while the second "assumes" that there is an error in the tags.) Not sure if and how they could be merged.

comment:2 Changed 5 months ago by GerdP

Ah, probably the list in the new rule needs $ and ^ so that service doesn't match services?

comment:3 Changed 5 months ago by Klumbumbus

Ah, now I get it. So yes and no. The missing $ and ^ are intended to match all the ..._link highways. However services should not match as this is used on areas. I'll fix the rule.

comment:4 Changed 5 months ago by Klumbumbus

In 15131/josm:

see #17623 , see #17765 - fix validator warning, don't treat highway=services as linear object

comment:5 Changed 5 months ago by Klumbumbus

(I wanted to add asserts but they didn't work due to the :AreaStyle pseudo class)

comment:6 Changed 5 months ago by GerdP

Resolution: fixed
Status: newclosed

In 15132/josm:

fix #17765: Move code for error "Area style way is not closed" to UnclosedWays
This simplifies the code. Method UnclosedWays.getCheckedKeys() is no longer needed
by any code in core or the plugins directory, but I did not dare to remove it.

comment:7 Changed 5 months ago by GerdP

In 15133/josm:

see #17765: Further simplify code

comment:9 Changed 5 months ago by GerdP

Oops, I only looked at the file multipolygon.osm...
I'll add a new test for UnclosedWays.

comment:10 Changed 5 months ago by GerdP

In 15134/josm:

see #17765: fix / add unit tests

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain team.
as The resolution will be set.
The resolution will be deleted.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.