Bug report #21716

Tracing tool stops working with

Added by Cory Albrecht about 5 years ago. Updated almost 5 years ago.

Status:Feedback
Priority:High
Assignee:-
Category:Editing
Affected QGIS version:3.7(master) Regression?:No
Operating System:Ubuntu 18.10 Easy fix?:No
Pull Request or Patch supplied:No Resolution:
Crashes QGIS or corrupts data:No Copied to github as #:29531

Description

When you try to create a feature by tracing other features in other layers, the tracing tool will often stop working with the displayed error

Tracing : Tracing may not work correctly. Please check topology of the input layers

which also shows up in the Messages log panel. It shows up even when all layers show no errors when checked with the tools in the processing toolbox. At the same time as tracing stops working, the Qt log panel shows the line

WARNING    GEOS exception: std::exception
<pre>

When starting from a terminal

<pre>
Warning: GEOS exception: std::exception
Stacktrace (piped through c++filt):
/usr/bin/qgis.bin(+0x10714)[0x55707d3b4714]
/usr/bin/qgis.bin(+0x10c40)[0x55707d3b4c40]
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5(+0xaee28)[0x7f56aba9ee28]
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5(+0xaf0c8)[0x7f56aba9f0c8]
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5(QMessageLogger::warning(char const*, ...) const+0xaf)[0x7f56aba7117f]
/usr/lib/libqgis_core.so.3.7.0(+0xdcc1f8)[0x7f56adaec1f8]
/usr/lib/x86_64-linux-gnu/libgeos_c.so.1(GEOSContextHandle_HS::ERROR_MESSAGE(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, ...)+0xde)[0x7f56a66261be]
/usr/lib/x86_64-linux-gnu/libgeos_c.so.1(GEOSNode_r+0x98)[0x7f56a6617018]
/usr/lib/libqgis_core.so.3.7.0(QgsTracer::initGraph()+0x7b4)[0x7f56ad777312]
/usr/lib/libqgis_core.so.3.7.0(QgsTracer::init()+0x4a)[0x7f56ad77852e]
/usr/lib/libqgis_gui.so.3.7.0(QgsMapToolCapture::tracingAddVertex(QgsPointXY const&)+0x8a)[0x7f56ae9ee426]
/usr/lib/libqgis_gui.so.3.7.0(QgsMapToolCapture::addVertex(QgsPointXY const&, QgsPointLocator::Match const&)+0x252)[0x7f56ae9efe6a]
/usr/lib/libqgis_app.so.3.7.0(QgsMapToolSplitFeatures::cadCanvasReleaseEvent(QgsMapMouseEvent*)+0x1d3)[0x7f56af58a7b9]
/usr/lib/libqgis_gui.so.3.7.0(QgsMapToolAdvancedDigitizing::canvasReleaseEvent(QgsMapMouseEvent*)+0x1cf)[0x7f56ae9ec99f]
/usr/lib/libqgis_gui.so.3.7.0(QgsMapCanvas::mouseReleaseEvent(QMouseEvent*)+0x3b5)[0x7f56ae9c9ac7]
/usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5(QWidget::event(QEvent*)+0x1d8)[0x7f56ac65a7d8]
/usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5(QFrame::event(QEvent*)+0x1e)[0x7f56ac6fde7e]
/usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5(QGraphicsView::viewportEvent(QEvent*)+0x16b)[0x7f56ac9480fb]
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5(QCoreApplicationPrivate::sendThroughObjectEventFilters(QObject*, QEvent*)+0x9b)[0x7f56abc5b1ab]
/usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5(QApplicationPrivate::notify_helper(QObject*, QEvent*)+0x71)[0x7f56ac61c491]
../../src/core/qgsmessagelog.cpp:29 : (logMessage) [1909ms] 2019-03-31T12:46:59 Qt[1] GEOS exception: std::exception
../../src/core/qgstracer.cpp:566 : (initGraph) [8ms] Tracer Noding Exception: std::exception
../../src/core/qgstracer.cpp:583 : (initGraph) [0ms] tracer extract 425 ms, noding 1915 ms (call 0 ms), make 0 ms
../../src/core/qgstracer.cpp:760 : (findShortestPath) [6ms] path timing: prep 5 ms, path 0 ms
../../src/core/qgsmessagelog.cpp:29 : (logMessage) [5ms] 2019-03-31T12:57:25 Messages[1] Tracing : Tracing may not work correctly. Please check topology of the input layers.
</pre>

Sometimes you can reset the tracing tool by zooming in one level and then back out and it will work with no problems. Often, however, you have to stay zoomed in and sometimes have to zoom in multiple levels before tracing finally works again.

As you trace a section and then slide the canvas to trace further, you will eventually have slid your way out of the area shown at the original zoom level without the tracer throwing an error. One would think that once the problematic vertices were in view the problem would happen again.

Sometimes exiting and restarting QGIS will make the problem go away. Sometimes getting too frustrated, going and working on a different part of the map, and then returning days later to try again and things will work with no tracing problems at all.

Also happens in 3.6 and 3.45 in addition to master/3.7

History

#1 Updated by Giovanni Manghi about 5 years ago

  • Status changed from Open to Feedback

what if you first clean your input with the "fix geometries" tool in the Processing toolbox?

#2 Updated by Cory Albrecht about 5 years ago

Giovanni Manghi wrote:

what if you first clean your input with the "fix geometries" tool in the Processing toolbox?

As I said: "It shows up even when all layers show no errors when checked with the tools in the processing toolbox."

#3 Updated by Giovanni Manghi about 5 years ago

As I said: "It shows up even when all layers show no errors when checked with the tools in the processing toolbox."

the "fix geometries" tool does not show any error, it just fixes them. And I asked try it because there are a lot of inconsistencies (about what is considered an error or not) among the tools we have available in qgis.

#4 Updated by Cory Albrecht about 5 years ago

Giovanni Manghi wrote:

As I said: "It shows up even when all layers show no errors when checked with the tools in the processing toolbox."

the "fix geometries" tool does not show any error, it just fixes them. And I asked try it because there are a lot of inconsistencies (about what is considered an error or not) among the tools we have available in qgis.

OK. The the features returned by fix geometries, in that new layer, were seemingly identical and made no difference as to whether the tracing error occurred

#5 Updated by Giovanni Manghi about 5 years ago

Can you attach the problematic layer? thanks.

#6 Updated by Cory Albrecht almost 5 years ago

I don't know which layer PostGIS is referring to because of the ambiguity of the error message. However, all layers are PostGIS layers.

Also available in: Atom PDF