Bug report #16802
Master crashes with 2 WMTS layers and scrollwheel use
Status: | Closed | ||
---|---|---|---|
Priority: | High | ||
Assignee: | Alessandro Pasotti | ||
Category: | Web Services clients/WMS | ||
Affected QGIS version: | master | Regression?: | Yes |
Operating System: | Debian and Windows | Easy fix?: | No |
Pull Request or Patch supplied: | No | Resolution: | fixed/implemented |
Crashes QGIS or corrupts data: | Yes | Copied to github as #: | 24701 |
Description
Tested here on:
- Debian testing fresh compiled of 6t july 2017
- Windows 2.99 osgeo4w64
Both crash when I add 2(!) WMTS raster layers to a project.
Tested with a new config (NO plugins!):
qgis --profiles-path /tmp/qgis
Create a fresh project (EPSG:28992)
Add 2x times (the same or different) rasterlayers, for example via the Python console:
qgis.utils.iface.addRasterLayer(
"tileMatrixSet=EPSG:28992&crs=EPSG:28992&layers=brtachtergrondkaart&styles=&format=image/png&url=http://geodata.nationaalgeoregister.nl/tiles/service/wmts/brtachtergrondkaart", # uri
"wmts master example", # name for layer (as seen in QGIS)
"wms" # dataprovider key
)
Now do some scrolling using a mouse wheel or so (you also create some bookmarks and run around these).
Sometimes after a couple of seconds, sometimes after some more time QGIS just crashes
History
#1 Updated by Richard Duivenvoorde over 7 years ago
Running in gdb:
src/providers/wms/qgswmsprovider.cpp: 3817: (tileReplyFinished) [1ms] [thread:0x7fff40002490] tile reply 2 (2) tile:14(retry 0) rect:161881.280000,435474.960000 168762.560000,428593.680000) fromcache:0 error:Unknown error url:https://geodata.nationaalgeoregister.nl/tiles/service/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=brtachtergrondkaart&STYLE=&FORMAT=image/png&TILEMATRIXSET=EPSG:28992&TILEMATRIX=EPSG:28992:7&TILEROW=68&TILECOL=65 src/providers/wms/qgswmsprovider.cpp: 3862: (tileReplyFinished) [0ms] [thread:0x7fff40002490] contentType: image/png src/providers/wms/qgswmsprovider.cpp: 3910: (tileReplyFinished) [0ms] [thread:0x7fff40002490] tile reply: length 61759 src/providers/wms/qgswmsprovider.cpp: 3794: (tileReplyFinished) [4ms] [thread:0x7fff40002490] expirationDate: src/providers/wms/qgswmsprovider.cpp: 858: (draw) [13ms] [thread:0x7fff40001dc0] TILE CACHE total: 159 / 256 src/providers/wms/qgswmsprovider.cpp: 884: (readBlock) [0ms] [thread:0x7fff40001dc0] image height = 480 bytesPerLine = 7068 Thread 16 "Thread (pooled)" received signal SIGSEGV, Segmentation fault. [Switching to Thread 0x7fff44c10700 (LWP 26875)] 0x00003f2090000003 in ?? () (gdb) bt #0 0x00003f2090000003 in ?? () #1 0x00007fffee4b4447 in ?? () from /lib/x86_64-linux-gnu/libQt5Core.so.5 #2 0x00007fffee4b6853 in QIODevice::write(char const*, long long) () from /lib/x86_64-linux-gnu/libQt5Core.so.5 #3 0x00007ffff1deab11 in ?? () from /lib/x86_64-linux-gnu/libQt5Network.so.5 #4 0x00007ffff1e88ad0 in ?? () from /lib/x86_64-linux-gnu/libQt5Network.so.5 #5 0x00007fffee5b6499 in QObject::event(QEvent*) () from /lib/x86_64-linux-gnu/libQt5Core.so.5 #6 0x00007ffff1861b8c in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /lib/x86_64-linux-gnu/libQt5Widgets.so.5 #7 0x00007ffff1869341 in QApplication::notify(QObject*, QEvent*) () from /lib/x86_64-linux-gnu/libQt5Widgets.so.5 #8 0x00007ffff48a04e1 in QgsApplication::notify (this=0x7fffffffd240, receiver=0x7fff387f6e60, event=0x7fff2404e930) at /home/richard/dev/qgis/git/qgis/src/core/qgsapplication.cpp:300 #9 0x00007fffee5899e0 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () from /lib/x86_64-linux-gnu/libQt5Core.so.5 #10 0x00007fffee58c16d in QCoreApplicationPrivate::sendPostedEvents(QObject*, int, QThreadData*) () from /lib/x86_64-linux-gnu/libQt5Core.so.5 #11 0x00007fffee5ddc43 in ?? () from /lib/x86_64-linux-gnu/libQt5Core.so.5 #12 0x00007fffeb484a17 in g_main_context_dispatch () from /lib/x86_64-linux-gnu/libglib-2.0.so.0 #13 0x00007fffeb484c80 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0 #14 0x00007fffeb484d2c in g_main_context_iteration () from /lib/x86_64-linux-gnu/libglib-2.0.so.0 #15 0x00007fffee5de04f in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /lib/x86_64-linux-gnu/libQt5Core.so.5 #16 0x00007fffee5879ca in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /lib/x86_64-linux-gnu/libQt5Core.so.5 #17 0x00007fff519bc97f in QgsWmsTiledImageDownloadHandler::downloadBlocking (this=0x7fff44c0daa0) at /home/richard/dev/qgis/git/qgis/src/providers/wms/qgswmsprovider.cpp:3754 #18 0x00007fff51998ca1 in QgsWmsProvider::draw (this=0x55555c7504f0, viewExtent=..., pixelWidth=1767, pixelHeight=480, feedback=0x55555c750420) at /home/richard/dev/qgis/git/qgis/src/providers/wms/qgswmsprovider.cpp:855 #19 0x00007fff51999538 in QgsWmsProvider::readBlock (this=0x55555c7504f0, bandNo=1, viewExtent=..., pixelWidth=1767, pixelHeight=480, block=0x7fff38002ba0, feedback=0x55555c750420) at /home/richard/dev/qgis/git/qgis/src/providers/wms/qgswmsprovider.cpp:877 #20 0x00007ffff4cfdcdc in QgsRasterDataProvider::block (this=0x55555c7504f0, bandNo=1, boundingBox=..., width=1767, height=480, feedback=0x55555c750420) at /home/richard/dev/qgis/git/qgis/src/core/raster/qgsrasterdataprovider.cpp:200 #21 0x00007ffff4d510a6 in QgsSingleBandColorDataRenderer::block (this=0x55555c758000, bandNo=1, extent=..., width=1767, height=480, feedback=0x55555c750420) at /home/richard/dev/qgis/git/qgis/src/core/raster/qgssinglebandcolordatarenderer.cpp:62 #22 0x00007ffff4d31362 in QgsBrightnessContrastFilter::block (this=0x55555c760080, bandNo=1, extent=..., width=1767, height=480, feedback=0x55555c750420) at /home/richard/dev/qgis/git/qgis/src/core/raster/qgsbrightnesscontrastfilter.cpp:121 #23 0x00007ffff4d361c6 in QgsHueSaturationFilter::block (this=0x55555c750e20, bandNo=1, extent=..., width=1767, height=480, feedback=0x55555c750420) at /home/richard/dev/qgis/git/qgis/src/core/raster/qgshuesaturationfilter.cpp:130 #24 0x00007ffff4d4f9b2 in QgsRasterResampleFilter::block (this=0x55555c750dd0, bandNo=1, extent=..., width=1767, height=480, feedback=0x55555c750420) at /home/richard/dev/qgis/git/qgis/src/core/raster/qgsrasterresamplefilter.cpp:162 #25 0x00007ffff4d27c1b in QgsRasterProjector::block (this=0x55555c750950, bandNo=1, extent=..., width=1767, height=480, feedback=0x55555c750420) at /home/richard/dev/qgis/git/qgis/src/core/raster/qgsrasterprojector.cpp:759 #26 0x00007ffff4d099dc in QgsRasterIterator::readNextRasterPart (this=0x7fff44c0ee80, bandNumber=1, nCols=@0x7fff44c0edd4: 1767, nRows=@0x7fff44c0edd0: 480, block=0x7fff44c0edc0, topLeftCol=@0x7fff44c0edcc: 0, topLeftRow=@0x7fff44c0edc8: 0) at /home/richard/dev/qgis/git/qgis/src/core/raster/qgsrasteriterator.cpp:109 #27 0x00007ffff4d41d8d in QgsRasterDrawer::draw (this=0x7fff44c0ee78, p=0x55555c628200, viewPort=0x55555c757dc0, qgsMapToPixel=0x55555c7580e8, feedback=0x55555c750420) at /home/richard/dev/qgis/git/qgis/src/core/raster/qgsrasterdrawer.cpp:58 #28 0x00007ffff4d1bf17 in QgsRasterLayerRenderer::render (this=0x55555c758250) at /home/richard/dev/qgis/git/qgis/src/core/raster/qgsrasterlayerrenderer.cpp:221 #29 0x00007ffff49d97d0 in QgsMapRendererParallelJob::renderLayerStatic (job=...) at /home/richard/dev/qgis/git/qgis/src/core/qgsmaprendererparalleljob.cpp:257 #30 0x00007ffff49daff6 in QtConcurrent::FunctionWrapper1<void, LayerRenderJob&>::operator() (this=0x55555d76ab28, u=...) at /usr/include/x86_64-linux-gnu/qt5/QtConcurrent/qtconcurrentfunctionwrappers.h:83 #31 0x00007ffff49dad59 in QtConcurrent::MapKernel<QList<LayerRenderJob>::iterator, QtConcurrent::FunctionWrapper1<void, LayerRenderJob&> >::runIteration (this=0x55555d76aaf0, it=...) at /usr/include/x86_64-linux-gnu/qt5/QtConcurrent/qtconcurrentmapkernel.h:69 #32 0x00007ffff49dade3 in QtConcurrent::MapKernel<QList<LayerRenderJob>::iterator, QtConcurrent::FunctionWrapper1<void, LayerRenderJob&> >::runIterations (this=0x55555d76aaf0, sequenceBeginIterator=..., beginIndex=1, endIndex=2) at /usr/include/x86_64-linux-gnu/qt5/QtConcurrent/qtconcurrentmapkernel.h:78 #33 0x00007ffff49db235 in QtConcurrent::IterateKernel<QList<LayerRenderJob>::iterator, void>::forThreadFunction (this=0x55555d76aaf0) at /usr/include/x86_64-linux-gnu/qt5/QtConcurrent/qtconcurrentiteratekernel.h:256 #34 0x00007ffff49daf60 in QtConcurrent::IterateKernel<QList<LayerRenderJob>::iterator, void>::threadFunction (this=0x55555d76aaf0) at /usr/include/x86_64-linux-gnu/qt5/QtConcurrent/qtconcurrentiteratekernel.h:218 #35 0x00007ffff7efbc9d in QtConcurrent::ThreadEngineBase::run() () from /lib/x86_64-linux-gnu/libQt5Concurrent.so.5 #36 0x00007fffee3b614f in ?? () from /lib/x86_64-linux-gnu/libQt5Core.so.5 #37 0x00007fffee3b9da8 in ?? () from /lib/x86_64-linux-gnu/libQt5Core.so.5 #38 0x00007fffed22f494 in start_thread (arg=0x7fff44c10700) at pthread_create.c:333 #39 0x00007fffed587a8f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:97 (gdb)
#2 Updated by Giovanni Manghi over 7 years ago
- Crashes QGIS or corrupts data changed from No to Yes
- Regression? changed from No to Yes
- Priority changed from Normal to High
#3 Updated by Alessandro Pasotti almost 7 years ago
- Status changed from Open to Feedback
- Assignee set to Alessandro Pasotti
Tested right now in master but I wasn't able to reproduce.
Can you please try latest master and confirm the the bug is still reproducible?
#4 Updated by Richard Duivenvoorde almost 7 years ago
- Description updated (diff)
#5 Updated by Richard Duivenvoorde almost 7 years ago
- Status changed from Feedback to Closed
Yep, tested here again. Cannot reproduce anymore. Apparently one of earlier commits fixed this.
QGIS master is getting more and more stable anyway with me now :-)
Closing this one
#6 Updated by Giovanni Manghi almost 7 years ago
- Resolution set to fixed/implemented