Bug report #14908

Processing plugin intersection module doesn't work properly

Added by AZeta Gis almost 8 years ago. Updated almost 8 years ago.

Assignee:Victor Olaya
Affected QGIS version:2.14.3 Regression?:No
Operating System: Easy fix?:No
Pull Request or Patch supplied:Yes Resolution:
Crashes QGIS or corrupts data:No Copied to github as #:22861


The " intersection " module of processing plugin doesn't work properly .
In attached example intersecting the layer "B" with the layer "A" doesn't return any feature while intersecting the layer "A" with the layer "B" is properly returned a feature .
The cause of this bug is the " break " statement at line 106 of the "processing\\algs\\qgis\\Intersection.py" file that prevents the evaluation of the successive intersections . Removing that line the algorithm works correctly.
The implemented algorithm in ftool plugin has a different structure and functioning properly (see lines 961 to 988 in fTools\\tools\\doGeoprocessing.py ).

IntersectionTest.zip (9.59 KB) AZeta Gis, 2016-05-26 11:02 AM

Associated revisions

Revision f4ca8476
Added by Victor Olaya almost 8 years ago

[processing] do not exit loop in intersect if there are errors

fixes #14908


#1 Updated by Alexander Bruy almost 8 years ago

  • Tag deleted (processing, intersection)
  • Status changed from Open to Feedback

It is not a bug, if intersection result has invalid geometry it skipped.

#2 Updated by AZeta Gis almost 8 years ago

Invalid geometry is skipped but the break line interrupts entire cicle and other geometries that overlap first geometry and produce valid intersections don't be evaluated.
In the attached example intersection result changes if input layers are inverted.

#3 Updated by Victor Olaya almost 8 years ago

  • Status changed from Feedback to Closed

Also available in: Atom PDF