Skip to content
This repository has been archived by the owner on Jul 24, 2021. It is now read-only.

osm2pgsql multipolygon handling necessarily broken on outer tagging change #2853

Open
openstreetmap-trac opened this issue Jul 23, 2021 · 3 comments

Comments

@openstreetmap-trac
Copy link

Reporter: Ldp
[Submitted to the original trac issue database at 10.16am, Thursday, 1st April 2010]

When you have a multipolygon with tags (say landuse=forest) on the outer way, and the same tags (landuse=forest) on the inner ways, osm2pgsql rightly drops the tags from the inner ways and just creates a single polygon object with holes. This renders as a forest with unfilled holes. So far so good.

If you now change the tagging on the outer way (say, to natural=heath), osm2pgsql updates that polygon's tagging. Since it never created separate polygons for the inner ways, those inner ways still won't render, and the natural=heath polygon will have unfilled holes. The only trick to get them to appear, is to modify the inner ways (change geom, change tagging), wait for the mapnik db to update, and then change the inner ways back to what they're supposed to be. This creates separate objects for the inner ways, so these finally render.

@openstreetmap-trac
Copy link
Author

Author: ipofanes
[Added to the original trac issue at 8.20am, Monday, 21st February 2011]

I don't know if a multipolygon with same outer and inner tags should interpret the inner polygon as an absence of the properties.

If the outer polygon has the additional tag wood=mixed and the inner has wood=coniferous, how do I map this? The way in
http://www.openstreetmap.org/browse/way/85172223 is rendered as desired in
Osmarender, but not in Mapnik.

@openstreetmap-trac
Copy link
Author

Author: amm
[Added to the original trac issue at 5.05pm, Saturday, 12th January 2013]

This sounds like a duplicate of #4525

On relation changes in diff processing, all of the member ways need to be reprocessed to catch these kind of issues.

@openstreetmap-trac
Copy link
Author

Author: amm
[Added to the original trac issue at 6.43pm, Monday, 16th September 2013]

It looks like this wasn't fixed with the fix to #4525.

For this to work, one would have to "expire" all relations for which any changed way is a member, which then in return would have to set all ways of all of those relations to pending.

This will probably introduce a huge overhead in diff processing.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant