Bug report #14447
Unknown exception when tracing is enabled
|Affected QGIS version:||master||Regression?:||No|
|Operating System:||Easy fix?:||No|
|Pull Request or Patch supplied:||No||Resolution:|
|Crashes QGIS or corrupts data:||No||Copied to github as #:||22425|
When digitising complex features using the new tracing tool an expception window ('unknown exception') opens. The issue occurs when moving the mouse inside the canvas.
#1 Updated by Maximilian Krambach almost 5 years ago
Further settings are "snapping on all layers, to vertex and segment, 10 pixel tolerance").
The exception raises whenever a tiny, but valid polygon (between bigger polygons, area < 0.1m², maximum width ~8mm) is on the canvas' extent. It raises an exception whenever a first point is set, or, if a first point was already set outside this area, whenever some snapping is calculated (whenever the mouse moves).
The layer's CRS is Gauss-Krueger based. The error does not depend on scale in this CRS.
Setting the OTF-reprojection to a UTM based CRS makes the error appear only in scale 1:5000 and smaller.
Setting it to EPSG:3857 (google Pseudomercator) makes the error disappear, which may serve as temporary workaround. Another workaround is removing the small areas (toolbox-> v.clean -> option rmarea) before further digitizing.
I think it is a rounding issue somewhere in qgsadvanceddigitizingwidget.cpp. Calculating 8mm in GK based systems and UTM based systems may make a difference, and there is some rounding going on in the file (example) .
#2 Updated by R. R. almost 5 years ago
- Assignee set to Saber Razmjooei
Thanks for debugging and the detailed explanation. After deleting all tiny polygons the tracing tool is working properly. I've assigned the ticket to Saber Razmjooei (see http://www.lutraconsulting.co.uk/blog/2016/02/16/qgis-trace-digitising/).
#4 Updated by Saber Razmjooei almost 5 years ago
- Assignee changed from Saber Razmjooei to Martin Dobias
- Affected QGIS version changed from 2.14.0 to master
As mentioned, there seems to be a problem with the file.
However, the trace digitizing tool should show a more meaningful message.
Tested in the master with same result.