Bug report #9779

QGIS crashes opening old (2.0.1) project in valmiera (2.2.1)

Added by Alexandre Neto over 6 years ago. Updated about 6 years ago.

Status:Closed
Priority:High
Assignee:-
Category:Project Loading/Saving
Affected QGIS version:master Regression?:No
Operating System: Easy fix?:No
Pull Request or Patch supplied:No Resolution:
Crashes QGIS or corrupts data:Yes Copied to github as #:18321

Description

I'm having problems opening a Dufour project (2.0.1) in Valmiera (2.2.1) using windows 7 64 bit.

QGIS warns me that a older version project is going to be opened, complete the layers loading (at least it seems to) but crashes before rendering the layersthe layers. The same project still opens in 2.0.1 without any problems.

More, it is possible to use "embed groups and layer" to successfully add all layers to a new project. Which I believe excludes problems with the layers, so it must be a project settings that is causing the crash.

I put the qgs file in attachment. And I will try to provide some portable sample data that still cause the crash.

SIG_DTOP.qgs (645 KB) Alexandre Neto, 2014-03-13 12:01 PM

SIG_DTOP_teste_1.qgs (19.2 KB) Alexandre Neto, 2014-03-14 04:08 AM

Associated revisions

Revision 1a67988e
Added by Jürgen Fischer over 6 years ago

atlas: don't crash the coverage layer is removed (refs #9779)

History

#1 Updated by Alexandre Neto over 6 years ago

#2 Updated by Alexandre Neto over 6 years ago

I have opened the problematic project in qgis 2.0.1-3, removed all layers and saved it as a new project. The new project (SIG_DTOP_teste_1.qgs), even with no layer at all, still cause qgis 2.2.1 to crash.

#3 Updated by Giovanni Manghi over 6 years ago

  • Crashes QGIS or corrupts data changed from No to Yes
  • Affected QGIS version changed from 2.2.0 to master
  • OS version deleted (2.2.1)
  • Operating System deleted (Windows 7 64 bit)
  • Target version set to Version 2.4
  • Priority changed from Normal to High

Alexandre Neto wrote:

I have opened the problematic project in qgis 2.0.1-3, removed all layers and saved it as a new project. The new project (SIG_DTOP_teste_1.qgs), even with no layer at all, still cause qgis 2.2.1 to crash.

here the console message

[email protected] ~ $ qgis
Warning: loading of qt translation failed [/usr/share/qt4/translations/qt_en_US]
Warning: QGraphicsScene::addItem: item has already been added to this scene
Warning: Loading a file that was saved with an older version of qgis (saved in 2.0.1-Dufour, loaded in 2.3.0-Master). Problems may occur.
QGIS died on signal 11[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[New Thread 0x7f71e994a700 (LWP 9516)]
[New Thread 0x7f71ea14b700 (LWP 9515)]
[New Thread 0x7f72008e5700 (LWP 9511)]
[New Thread 0x7f72010e6700 (LWP 9510)]
[New Thread 0x7f7201f62700 (LWP 9509)]
0x00007f7235e63ccd in waitpid () from /lib/x86_64-linux-gnu/libc.so.6
[Current thread is 1 (Thread 0x7f723d16e7c0 (LWP 9497))]
#0  0x00007f7235e63ccd in waitpid () from /lib/x86_64-linux-gnu/libc.so.6
No symbol table info available.
#1  0x00000000004f45b0 in qgisCrash(int) ()
No symbol table info available.
#2  <signal handler called>
No symbol table info available.
#3  0x00007f7239a41e59 in QgsExpression::NodeColumnRef::prepare(QgsExpression*, QgsFields const&) () from /usr/lib/libqgis_core.so.2.3.0
No symbol table info available.
#4  0x00007f7239a4028b in QgsExpression::NodeBinaryOperator::prepare(QgsExpression*, QgsFields const&) () from /usr/lib/libqgis_core.so.2.3.0
No symbol table info available.
#5  0x00007f7239a4028b in QgsExpression::NodeBinaryOperator::prepare(QgsExpression*, QgsFields const&) () from /usr/lib/libqgis_core.so.2.3.0
No symbol table info available.
#6  0x00007f7239a46bf5 in QgsExpression::prepare(QgsFields const&) () from /usr/lib/libqgis_core.so.2.3.0
No symbol table info available.
#7  0x00007f7239bef7d4 in QgsAtlasComposition::updateFilenameExpression() () from /usr/lib/libqgis_core.so.2.3.0
No symbol table info available.
#8  0x00000000008182c1 in ?? ()
No symbol table info available.
#9  0x000000000081843b in QgsAtlasCompositionWidget::qt_metacall(QMetaObject::Call, int, void**) ()
No symbol table info available.
#10 0x00007f7238a5e489 in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
No symbol table info available.
#11 0x00007f72381eccb2 in QLineEdit::textChanged(QString const&) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#12 0x00007f72381ecf59 in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#13 0x00007f7238a5e281 in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
No symbol table info available.
#14 0x00007f723845fb75 in QLineControl::textChanged(QString const&) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#15 0x00007f72381f1b7b in QLineControl::finishChange(int, bool, bool) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#16 0x00007f72381f1e10 in QLineControl::internalSetText(QString const&, int, bool) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#17 0x000000000078ad54 in QgsAtlasCompositionWidget::updateGuiElements() ()
No symbol table info available.
#18 0x000000000081827d in ?? ()
No symbol table info available.
#19 0x00007f7238a5e281 in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
No symbol table info available.
#20 0x00007f7239bf100b in QgsAtlasComposition::readXML(QDomElement const&, QDomDocument const&) () from /usr/lib/libqgis_core.so.2.3.0
No symbol table info available.
#21 0x000000000073aa61 in QgsComposer::readXML(QDomElement const&, QDomDocument const&, bool) ()
No symbol table info available.
#22 0x000000000052e309 in QgisApp::loadComposersFromProject(QDomDocument const&) ()
No symbol table info available.
#23 0x000000000080c1e1 in ?? ()
No symbol table info available.
#24 0x00007f7238a5e281 in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
No symbol table info available.
#25 0x00007f7239c8f6f2 in QgsProject::readProject(QDomDocument const&) () from /usr/lib/libqgis_core.so.2.3.0
No symbol table info available.
#26 0x00007f7239b1dfdd in QgsProject::read() () from /usr/lib/libqgis_core.so.2.3.0
No symbol table info available.
#27 0x00007f7239b1e73c in QgsProject::read(QFileInfo const&) () from /usr/lib/libqgis_core.so.2.3.0
No symbol table info available.
#28 0x0000000000529668 in QgisApp::addProject(QString) ()
No symbol table info available.
#29 0x000000000052aee5 in QgisApp::fileOpen() ()
No symbol table info available.
#30 0x000000000080ba2a in ?? ()
No symbol table info available.
#31 0x00007f7238a5e281 in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
No symbol table info available.
#32 0x00007f7237dc6132 in QAction::triggered(bool) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#33 0x00007f7237dc631f in QAction::activate(QAction::ActionEvent) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#34 0x00007f723819bd8a in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#35 0x00007f723819c03c in QAbstractButton::mouseReleaseEvent(QMouseEvent*) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#36 0x00007f723825961a in QToolButton::mouseReleaseEvent(QMouseEvent*) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#37 0x00007f7237e1d144 in QWidget::event(QEvent*) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#38 0x00007f7237dcc894 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#39 0x00007f7237dd20bf in QApplication::notify(QObject*, QEvent*) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#40 0x00007f7239a07936 in QgsApplication::notify(QObject*, QEvent*) () from /usr/lib/libqgis_core.so.2.3.0
No symbol table info available.
#41 0x00007f7238a49e9c in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
No symbol table info available.
#42 0x00007f7237dcd862 in QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer<QWidget>&, bool) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#43 0x00007f7237e4cc35 in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#44 0x00007f7237e4bbee in QApplication::x11ProcessEvent(_XEvent*) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#45 0x00007f7237e621ac in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#46 0x00007f7238233183 in QSplashScreen::finish(QWidget*) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#47 0x00000000004eeeb0 in main ()
No symbol table info available.
gdb returned 0
Aborted (core dumped)

#4 Updated by Giovanni Manghi over 6 years ago

  • Status changed from Open to Feedback

Alexandre Neto wrote:

I have opened the problematic project in qgis 2.0.1-3, removed all layers and saved it as a new project. The new project (SIG_DTOP_teste_1.qgs), even with no layer at all, still cause qgis 2.2.1 to crash.

in the project there are composer layouts (2?) definitions, if I remove them then no crash.

Can you try remove the layouts from the project and see if then it still crashes?

#5 Updated by Alexandre Neto over 6 years ago

You are correct. If I remove one of the layouts from original project, it no longer crashes. More specifically one that has atlas creation active.

I have been doing some tests, and it seems that the offending project had an empty coverage layer name (coverageLayer=""), but in the atlas settings GUI it seemed to be using one of the canvas layers, reselecting the layer corrected the problem.

In QGIS 2.0.1, I was only able to recreate a project in those conditions if I remove the last suitable candidate for atlas coverage, i.e., removing the last vector layer. No errors are emitted, but after that QGIS 2.2 will crash trying to open that project. Strangely if I add a new vector layer, it will automatically set as coverage. Therefore, I'm not sure how have this happen in my particular project.

Anyway, in QGIS 2.2, if one remove the last suitable coverage layer (with atlas creation active), a crash dump occurs immediately.

I think that the current issue can be closed as an isolated strange case, but I believe the behavior in qgis 2.2 (or master) should be corrected.

Should I keep this open? or should I close it and open a brand new issue?

#6 Updated by Giovanni Manghi over 6 years ago

  • Assignee set to Nyall Dawson
  • Status changed from Feedback to Open

Anyway, in QGIS 2.2, if one remove the last suitable coverage layer (with atlas creation active), a crash dump occurs immediately.

Nyall, as this is about the composer I'm assigning it to you (hopefully I'm not wrong).

I think that the current issue can be closed as an isolated strange case, but I believe the behavior in qgis 2.2 (or master) should be corrected.

Should I keep this open? or should I close it and open a brand new issue?

let's see what Nyall says.

#7 Updated by Jürgen Fischer over 6 years ago

  • Assignee deleted (Nyall Dawson)
  • Status changed from Open to Feedback

Alexandre Neto wrote:

I have opened the problematic project in qgis 2.0.1-3, removed all layers and saved it as a new project. The new project (SIG_DTOP_teste_1.qgs), even with no layer at all, still cause qgis 2.2.1 to crash.

That's just because the atlas composition still references a coverage layer that is now gone. 1a67988 should fix that.

#8 Updated by Matthias Kuhn over 6 years ago

1a67988 cherry-picks nicely on top of release-2_2. Any objections to push it there?

#9 Updated by Alexandre Neto about 6 years ago

  • Status changed from Feedback to Closed

I have finally tested this, and acording to my test, the problem is solved in master. I'm closing it.

thanks

Also available in: Atom PDF