Bug report #755

loading projects from 0.8.1 doesn't work, sometimes crashes

Added by Maciej Sieczka - over 16 years ago. Updated almost 15 years ago.

Assignee:Magnus Homann
Category:Project Loading/Saving
Affected QGIS version: Regression?:No
Operating System:Debian Easy fix?:No
Pull Request or Patch supplied: Resolution:fixed
Crashes QGIS or corrupts data: Copied to github as #:10814


My projects created in QGIS 0.8.1 open in QGIS 0.9 SVN 7174, but no layers are visible. Zooming to a layer or to a full extent, turning rendering on/off doesn't help. Also, the projection is always reset to EPSG 4326, no matter what it was set to in QGIS 0.8.1 (ususally EPSG 32633 in my case). At random occasions, QGIS 0.9 even crashes loading 0.8.1 projects. Example backtrace follows:

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 46912606875408 (LWP 22651)]
0x00000000004d097a in QListData::size ()
(gdb) bt
#0  0x00000000004d097a in QListData::size ()
#3905  0x0000000000516df9 in QList<QTreeWidgetItem*>::count ()
#3906  0x0000000000516e15 in QTreeWidgetItem::childCount ()
#3907  0x00000000005e5046 in [[QgsLegend]]::nextItem ()
#3908  0x00000000005e93bc in [[QgsLegend]]::updateMapCanvasLayerSet ()
#3909  0x00000000005eb505 in [[QgsLegend]]::handleItemChange ()
#3910  0x0000000000622aa8 in [[QgsLegend]]::qt_metacall ()
#3911  0x00002aaaaacd54db in QMetaObject::activate (sender=0xc25990,
    from_signal_index=95, to_signal_index=95, argv=0x0)
    at kernel/qobject.cpp:3080
#3912  0x00002aaaab6aff50 in QTreeWidget::itemChanged (this=0x30, _t1=0xce56e0,
    _t2=0) at moc_qtreewidget.cpp:225
#3913  0x00002aaaab6b9f8e in QTreeWidget::qt_metacall (this=0xc25990,
    _c=QMetaObject::InvokeMetaMethod, _id=-7, _a=0x7fffffcbe570)
    at moc_qtreewidget.cpp:145
#10 0x000000000062282a in [[QgsLegend]]::qt_metacall ()
#3914 0x00002aaaaacd54db in QMetaObject::activate (sender=0xc29490,
    from_signal_index=4, to_signal_index=4, argv=0x0)
    at kernel/qobject.cpp:3080
#3915 0x00002aaaaacf2627 in QAbstractItemModel::dataChanged (this=0x30,
    _t1=<value optimized out>, _t2=<value optimized out>)
    at .moc/release-shared/moc_qabstractitemmodel.cpp:123
#3916 0x00002aaaab6b0498 in QTreeModel::itemChanged (this=0xc29490,
    item=0xce56e0) at itemviews/qtreewidget.cpp:726
#3917 0x00002aaaab6b3dfb in QTreeWidgetItemPrivate::propagateDisabled (
    this=<value optimized out>, item=0xce56e0)
    at itemviews/qtreewidget.cpp:1597
#3918 0x00002aaaab6b633a in QTreeWidgetItem::insertChild (this=0x1a3dde0,
    index=0, child=0xce56e0) at itemviews/qtreewidget.cpp:1862
#3919 0x00002aaaab6b6c46 in QTreeWidgetItem (this=0xce56e0, parent=0x1a3dde0,
    type=<value optimized out>) at itemviews/qtreewidget.cpp:1382
#3920 0x00000000005f70c3 in [[QgsLegendItem]]::QgsLegendItem ()
#3921 0x00000000005fea8b in [[QgsLegendLayerFileGroup]]::QgsLegendLayerFileGroup ()
#3922 0x00000000005ed8a1 in [[QgsLegend]]::readXML ()
#3923 0x00000000005ee003 in [[QgsLegend]]::readProject ()
#3924 0x00000000006229c1 in [[QgsLegend]]::qt_metacall ()
#3925 0x00002aaaaacd54db in QMetaObject::activate (sender=0xa8cde0,
    from_signal_index=4, to_signal_index=4, argv=0x0)
    at kernel/qobject.cpp:3080
#3926 0x00002aaaac7c93a7 in [[QgsProject]]::readProject ()
   from /usr/local/qgis09/lib/libqgis_core.so
#3927 0x00002aaaac764fa4 in [[QgsProject]]::read ()
   from /usr/local/qgis09/lib/libqgis_core.so
#3928 0x00002aaaac7651d5 in [[QgsProject]]::read ()
   from /usr/local/qgis09/lib/libqgis_core.so
#3929 0x00000000004ca9c7 in [[QgisApp]]::addProject ()
#3930 0x00000000004cb560 in [[QgisApp]]::openProject ()
#3931 0x000000000061cd7b in [[QgisApp]]::qt_metacall ()
#3932 0x00002aaaaacd54db in QMetaObject::activate (sender=0xa4c090,
    from_signal_index=29, to_signal_index=29, argv=0x0)
    at kernel/qobject.cpp:3080
#3933 0x00002aaaab580d12 in QMenu::triggered (this=0x30, _t1=0xa807b0)
    at moc_qmenu.cpp:155
#3934 0x00002aaaab58196c in QMenuPrivate::_q_actionTriggered (
    this=<value optimized out>) at widgets/qmenu.cpp:969
#3935 0x00002aaaab586e3b in QMenu::qt_metacall (this=0xa4c090,
    _c=QMetaObject::InvokeMetaMethod, _id=-3, _a=0x7fffffcc0630)
    at moc_qmenu.cpp:97
#3936 0x00002aaaaacd54db in QMetaObject::activate (sender=0xa807b0,
    from_signal_index=5, to_signal_index=6, argv=0x0)
    at kernel/qobject.cpp:3080
#3937 0x00002aaaab22a077 in QAction::triggered (this=0x30, _t1=false)
    at moc_qaction.cpp:208
#3938 0x00002aaaab22a90b in QAction::activate (this=0xa807b0,
    event=<value optimized out>) at kernel/qaction.cpp:1116
#36 0x00002aaaab588455 in QMenuPrivate::activateAction (this=0xa3c960,
    action=0xa807b0, action_e=QAction::Trigger, self=true)
    at widgets/qmenu.cpp:912
#37 0x00002aaaab2738fa in QWidget::event (this=0x30, event=0x7fffffcc0f40)
    at kernel/qwidget.cpp:6080
#38 0x00002aaaab586591 in QMenu::event (this=0xa4c090, e=0x7fffffcc0f40)
    at widgets/qmenu.cpp:2134
#39 0x00002aaaab23012f in QApplicationPrivate::notify_helper (this=0x0,
    receiver=0xa4c090, e=0x7fffffcc0f40) at kernel/qapplication.cpp:3558
#40 0x00002aaaab233d88 in QApplication::notify (this=<value optimized out>,
    receiver=0xa4c090, e=0x7fffffcc0f40) at kernel/qapplication.cpp:3257
#41 0x00002aaaaacc4440 in QCoreApplication::notifyInternal (
    this=0x7fffffcc1a70, receiver=0xa4c090, event=0x7fffffcc0f40)
    at kernel/qcoreapplication.cpp:532
#42 0x00002aaaab289e65 in QETWidget::translateMouseEvent (this=0xa4c090,
    event=<value optimized out>) at qcoreapplication.h:205
#43 0x00002aaaab28837c in QApplication::x11ProcessEvent (this=0x7b,
    event=0x7fffffcc1530) at kernel/qapplication_x11.cpp:3024
#44 0x00002aaaab2ac9c2 in x11EventSourceDispatch (s=0x8145a0, callback=0,
    user_data=0x0) at kernel/qguieventdispatcher_glib.cpp:137
#45 0x00002aaaae6e4bfd in g_main_context_dispatch ()
   from /usr/lib64/libglib-2.0.so.0
#46 0x00002aaaae6e7ec5 in g_main_context_check ()
   from /usr/lib64/libglib-2.0.so.0
#47 0x00002aaaae6e8374 in g_main_context_iteration ()
   from /usr/lib64/libglib-2.0.so.0
#48 0x00002aaaaace6cfe in QEventDispatcherGlib::processEvents (this=0x80fc40,
    flags=@0x7fffffcc1800) at kernel/qeventdispatcher_glib.cpp:340
#49 0x00002aaaab2ac59f in QGuiEventDispatcherGlib::processEvents (this=0x30,
    flags=<value optimized out>) at kernel/qguieventdispatcher_glib.cpp:193
#50 0x00002aaaaacc3da8 in QEventLoop::processEvents (
    this=<value optimized out>, flags=<value optimized out>)
    at kernel/qeventloop.cpp:141
#51 0x00002aaaaacc3ef6 in QEventLoop::exec (this=0x7fffffcc18a0,
    flags=@0x7fffffcc18b0) at kernel/qeventloop.cpp:187
#52 0x00002aaaaacc63f2 in QCoreApplication::exec ()
    at kernel/qcoreapplication.cpp:752
#53 0x00000000004aa44e in main ()


#1 Updated by Maciej Sieczka - over 16 years ago

And vice versa - projects created in 0.9 can't be used i 0.8.1.

#2 Updated by Magnus Homann over 16 years ago

  • Status changed from Open to In Progress

Two main issues:
1) They layers are markes as being shown, but they are not. Uncheck and check the 'shown' box in legend.
2) The layer projection is wrong. Set all projection layers, and the project projection.

Opening a 0.9 project in 0.8 will not be supported.

#3 Updated by Magnus Homann over 16 years ago

The crash might be fixed by 74cacbb8 (SVN r7400), please update and try if it crashes. The reading of older project files is still work in progress.

#4 Updated by Magnus Homann over 16 years ago

  • Resolution set to fixed
  • Status changed from In Progress to Closed

Reading of older projectm files should be fixed in

#5 Updated by Anonymous almost 15 years ago

Milestone Version 0.9.2 deleted

Also available in: Atom PDF