You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
QGIS3 implementation under development. Currently failing with
" ASSERT failure in QgsFeatureRenderer::renderFeature: "renderFeature called in a different thread - use a cloned renderer instead"
Looking at QgsFeatureRenderer code it appears this is caused by a two calls to QgsFeatureRenderer::startRender from different threads, or from a call to renderFeature without a corresponding call to startRender.
The plugin does not override renderFeature, but does override startRender, stopRender, and symbolsForFeature.
Sample project attached below. Steps to reproduce are select test.csv layer, open properties/symbology
select VectorField renderer, set X attribute to dx and Y attribute to dy, then Ok.
Running gdb qgis.bin gives following abbreviated stack trace:
Fatal: ASSERT failure in QgsFeatureRenderer::renderFeature: "renderFeature called in a different thread - use a
cloned renderer instead", file ../../src/core/symbology/qgsrenderer.cpp, line 121
QGIS died on signal -1Warning: QPainter::end: Painter not active, aborted
Stacktrace (piped through c++filt):
/usr/bin/qgis.bin(+0xca4d)[0x555555560a4d]
/usr/bin/qgis.bin(+0xcf5a)[0x555555560f5a]
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5(+0x914c6)[0x7ffff4ae64c6]
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5(QMessageLogger::warning(char const*, ...) const+0xac)[0x7ffff4ae728c]
/usr/lib/x86_64-linux-gnu/libQt5Gui.so.5(QPainter::end()+0x35e)[0x7ffff52635ee]
/usr/lib/libqgis_core.so.2.99.0(QgsSymbolLayerUtils::symbolPreviewPixmap(QgsSymbol*, QSize, int, QgsRenderConte
xt*)+0x167)[0x7ffff5f18955]
/usr/lib/libqgis_core.so.2.99.0(QgsSymbolLegendNode::minimumIconSize(QgsRenderContext*) const+0xd3)[0x7ffff5f92
f13]
/usr/lib/libqgis_core.so.2.99.0(QgsLayerTreeModel::invalidateLegendMapBasedData()+0x1b3)[0x7ffff5f87879]
/usr/lib/libqgis_core.so.2.99.0(+0x49044b)[0x7ffff5f9044b]
/usr/lib/libqgis_core.so.2.99.0(+0x48f747)[0x7ffff5f8f747]
/usr/lib/libqgis_core.so.2.99.0(+0x48df9f)[0x7ffff5f8df9f]
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5(QMetaObject::activate(QObject*, int, int, void**)+0x66f)[0x7ffff4d09b
af]
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5(QTimer::timerEvent(QTimerEvent*)+0x28)[0x7ffff4d165c8]
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5(QObject::event(QEvent*)+0xa3)[0x7ffff4d0abb3]
/usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5(QApplicationPrivate::notify_helper(QObject*, QEvent*)+0x8c)[0x7fff
f55ce05c]
/usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5(QApplication::notify(QObject*, QEvent*)+0x256)[0x7ffff55d3516]
/usr/lib/libqgis_core.so.2.99.0(QgsApplication::notify(QObject*, QEvent*)+0x9b)[0x7ffff611b319]
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5(QCoreApplication::notifyInternal(QObject*, QEvent*)+0xdb)[0x7ffff4cdb
38b]
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5(QTimerInfoList::activateTimers()+0x52d)[0x7ffff4d305ed]
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5(+0x2dbaf1)[0x7ffff4d30af1]
../../src/core/qgsmessagelog.cpp: 27: (logMessage) [695ms] 2018-02-11T23:26:03 Qt[1] QPainter::end: Painter not
active, aborted
Warning: QPainter::end: Painter not active, aborted
Stacktrace (piped through c++filt):
/usr/bin/qgis.bin(+0xca4d)[0x555555560a4d]
/usr/bin/qgis.bin(+0xcf5a)[0x555555560f5a]
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5(+0x914c6)[0x7ffff4ae64c6]
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5(QMessageLogger::warning(char const*, ...) const+0xac)[0x7ffff4ae728c]
/usr/lib/x86_64-linux-gnu/libQt5Gui.so.5(QPainter::end()+0x35e)[0x7ffff52635ee]
/usr/lib/libqgis_core.so.2.99.0(QgsSymbolLayerUtils::symbolPreviewPixmap(QgsSymbol*, QSize, int, QgsRenderConte
xt*)+0x167)[0x7ffff5f18955]
/usr/lib/libqgis_core.so.2.99.0(QgsSymbolLegendNode::minimumIconSize(QgsRenderContext*) const+0xd3)[0x7ffff5f92
f13]
/usr/lib/libqgis_core.so.2.99.0(QgsLayerTreeModel::invalidateLegendMapBasedData()+0x1b3)[0x7ffff5f87879]
/usr/lib/libqgis_core.so.2.99.0(+0x49044b)[0x7ffff5f9044b]
/usr/lib/libqgis_core.so.2.99.0(+0x48f747)[0x7ffff5f8f747]
/usr/lib/libqgis_core.so.2.99.0(+0x48df9f)[0x7ffff5f8df9f]
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5(QMetaObject::activate(QObject*, int, int, void**)+0x66f)[0x7ffff4d09b
af]
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5(QTimer::timerEvent(QTimerEvent*)+0x28)[0x7ffff4d165c8]
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5(QObject::event(QEvent*)+0xa3)[0x7ffff4d0abb3]
/usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5(QApplicationPrivate::notify_helper(QObject*, QEvent*)+0x8c)[0x7fff
f55ce05c]
/usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5(QApplication::notify(QObject*, QEvent*)+0x256)[0x7ffff55d3516]
/usr/lib/libqgis_core.so.2.99.0(QgsApplication::notify(QObject*, QEvent*)+0x9b)[0x7ffff611b319]
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5(QCoreApplication::notifyInternal(QObject*, QEvent*)+0xdb)[0x7ffff4cdb
38b]
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5(QTimerInfoList::activateTimers()+0x52d)[0x7ffff4d305ed]
/usr/lib/x86_64-linux-gnu/libQt5Core.so.5(+0x2dbaf1)[0x7ffff4d30af1]
Using ubuntu 16.04 nightly-ubuntugis .. details from About are
QGIS3 implementation under development. Currently failing with
" ASSERT failure in QgsFeatureRenderer::renderFeature: "renderFeature called in a different thread - use a cloned renderer instead"
Looking at QgsFeatureRenderer code it appears this is caused by a two calls to QgsFeatureRenderer::startRender from different threads, or from a call to renderFeature without a corresponding call to startRender.
https://qgis.org/api/classQgsFeatureRenderer.html#af01839c584bf5fc58e259adaa318c0bd
Python plugin code for startRender is at:
https://github.com/ccrook/QGIS-VectorFieldRenderer-Plugin/blob/qgis3_wip/VectorFieldRenderer/VectorFieldRenderer.py#L412
The plugin does not override renderFeature, but does override startRender, stopRender, and symbolsForFeature.
Sample project attached below. Steps to reproduce are select test.csv layer, open properties/symbology
select VectorField renderer, set X attribute to dx and Y attribute to dy, then Ok.
Running gdb qgis.bin gives following abbreviated stack trace:
Using ubuntu 16.04 nightly-ubuntugis .. details from About are
vectest.zip
The text was updated successfully, but these errors were encountered: