Bug report #18254

Topology checker thinks everything is a multipart polygon

Added by Bartosz Mazurkiewicz over 6 years ago. Updated over 5 years ago.

Status:Closed
Priority:Normal
Assignee:-
Category:C++ plugins/Topology checker
Affected QGIS version:3.0.0 Regression?:No
Operating System:Windows 7, 64 bit Easy fix?:No
Pull Request or Patch supplied:No Resolution:no timely feedback
Crashes QGIS or corrupts data:No Copied to github as #:26145

Description

The topology checker does not work well in qgis3.
Even with a just by hand created polygon layer it shows that every polygon is a multipart one.

History

#1 Updated by Giovanni Manghi over 6 years ago

  • Status changed from Open to Feedback

Does it works differently in 2.18?

Please add detailed steps to allow others easily replicate the issue.

#2 Updated by Bartosz Mazurkiewicz over 6 years ago

Giovanni Manghi wrote:

Does it works differently in 2.18?

Please add detailed steps to allow others easily replicate the issue.

Yes in 2.18 the same shapefile does not show "is multipart" error.
I tried it with various shapefiles. Even one manually created and certainly not multipart.

#3 Updated by Nyall Dawson over 6 years ago

Actually this was an intentional change in 3.0. Because shapefile don't have strict single/multi types for line/polygon layers (they only do for point/multipoint) there was some heuristics in QGIS to detect whether a layer contained single or multi part geometries. But it was fragile and broke in many cases, causing layers which were reported as single part types to sometimes still return multi part features.

To solve this qgis now treats all shapefile line/polygon layers as multipart and returns multipart features from these layers.

In other words - it's another shapefile limitation.

#4 Updated by Giovanni Manghi over 6 years ago

Nyall Dawson wrote:

Actually this was an intentional change in 3.0. Because shapefile don't have strict single/multi types for line/polygon layers (they only do for point/multipoint) there was some heuristics in QGIS to detect whether a layer contained single or multi part geometries. But it was fragile and broke in many cases, causing layers which were reported as single part types to sometimes still return multi part features.

To solve this qgis now treats all shapefile line/polygon layers as multipart and returns multipart features from these layers.

In other words - it's another shapefile limitation.

closing?

#5 Updated by Bartosz Mazurkiewicz over 6 years ago

Giovanni Manghi wrote:

Nyall Dawson wrote:

Actually this was an intentional change in 3.0. Because shapefile don't have strict single/multi types for line/polygon layers (they only do for point/multipoint) there was some heuristics in QGIS to detect whether a layer contained single or multi part geometries. But it was fragile and broke in many cases, causing layers which were reported as single part types to sometimes still return multi part features.

To solve this qgis now treats all shapefile line/polygon layers as multipart and returns multipart features from these layers.

In other words - it's another shapefile limitation.

closing?

Thank you for the explanation.

So wouldn't be better to eliminate this topology test for line/polygon shapefiles if it always fails for them? Maybe adding something in the help section of the tool?

#6 Updated by Giovanni Manghi over 6 years ago

So wouldn't be better to eliminate this topology test for line/polygon shapefiles if it always fails for them? Maybe adding something in the help section of the tool?

give a try to the "geometry checker" core tool. The "topology checker" is (as far as I know) unmaintained.

#7 Updated by Giovanni Manghi over 6 years ago

Nyall Dawson wrote:

Actually this was an intentional change in 3.0. Because shapefile don't have strict single/multi types for line/polygon layers (they only do for point/multipoint) there was some heuristics in QGIS to detect whether a layer contained single or multi part geometries. But it was fragile and broke in many cases, causing layers which were reported as single part types to sometimes still return multi part features.

To solve this qgis now treats all shapefile line/polygon layers as multipart and returns multipart features from these layers.

In other words - it's another shapefile limitation.

considered also this

https://github.com/qgis/QGIS-Enhancement-Proposals/issues/131#issuecomment-414785213

should we close this?

#8 Updated by Jürgen Fischer over 5 years ago

  • Resolution set to no timely feedback
  • Status changed from Feedback to Closed

Bulk closing 82 tickets in feedback state for more than 90 days affecting an old version. Feel free to reopen if it still applies to a current version and you have more information that clarify the issue.

Also available in: Atom PDF