Bug report #8988

"Export/Add geometry columns" error for layers with line geometries

Added by Andrey Isakov about 6 years ago. Updated over 2 years ago.

Status:Closed
Priority:Severe/Regression
Assignee:Giovanni Manghi
Category:Processing/QGIS
Affected QGIS version:master Regression?:
Operating System: Easy fix?:
Pull Request or Patch supplied:No Resolution:fixed/implemented
Crashes QGIS or corrupts data:Yes Copied to github as #:17647

Description

Log output:

An error has occured while executing Python code:

Traceback (most recent call last):
  File "/usr/share/qgis/python/plugins/fTools/tools/doGeometry.py", line 333, in run
    success = self.export_geometry_info()
  File "/usr/share/qgis/python/plugins/fTools/tools/doGeometry.py", line 572, in export_geometry_info
    atMap[ index1 ] = attr1
IndexError: list assignment index out of range

Python version:
2.7.5+ (default, Sep 17 2013, 15:33:59) 
[GCC 4.8.1]

QGIS version:
2.0.1-Dufour Dufour, exported

Python path: ['/usr/share/qgis/python/plugins/processing', '/usr/share/qgis/python', '/home/andrey/.qgis2/python', '/home/andrey/.qgis2/python/plugins', '/usr/share/qgis/python/plugins', '/usr/lib/python2.7', '/usr/lib/python2.7/plat-x86_64-linux-gnu', '/usr/lib/python2.7/lib-tk', '/usr/lib/python2.7/lib-old', '/usr/lib/python2.7/lib-dynload', '/usr/local/lib/python2.7/dist-packages', '/usr/lib/python2.7/dist-packages', '/usr/lib/python2.7/dist-packages/PIL', '/usr/lib/python2.7/dist-packages/gtk-2.0', '/usr/lib/pymodules/python2.7', '/home/andrey/.qgis2/python/plugins/mmqgis/forms', '/usr/share/qgis/python/plugins/fTools/tools']

linestest.tar.gz (1.05 MB) Giovanni Manghi, 2013-11-03 01:14 AM

doGeometry.py Magnifier - replace older with this one, but don't forget to backup older first (43.9 KB) Dedy Fuadi, 2014-05-25 02:12 AM

Associated revisions

History

#1 Updated by Giovanni Manghi about 6 years ago

  • Affected QGIS version changed from 2.0.1 to master
  • Crashes QGIS or corrupts data changed from No to Yes
  • Operating System deleted (all)
  • File linestest.tar.gz added
  • Target version set to Future Release - High Priority

It does not happen with all layers, but it happens with many (sample attached).

I even seen a crash. Definitely a regression

[email protected] ~ $ qgis
Warning: loading of qt translation failed [/usr/share/qt4/translations/qt_en_US]
Warning: Could not parse stylesheet of widget 0x2f03350
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 0x7f87d53ab700 (LWP 13764)]
[New Thread 0x7f87dd71d700 (LWP 13729)]
[New Thread 0x7f87de816700 (LWP 13728)]
[New Thread 0x7f87df239700 (LWP 13727)]
0x00007f880eb41a43 in poll () from /lib/x86_64-linux-gnu/libc.so.6
[Current thread is 1 (Thread 0x7f8815d6d7c0 (LWP 13722))]
#0 0x00007f880eb41a43 in poll () from /lib/x86_64-linux-gnu/libc.so.6
No symbol table info available.
#1 0x00007f880d5bbff6 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
No symbol table info available.
#2 0x00007f880d5bc124 in g_main_context_iteration () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
No symbol table info available.
#3 0x00007f881172e426 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
No symbol table info available.
#4 0x00007f8810b29d5e in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#5 0x00007f88116fdc82 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
No symbol table info available.
#6 0x00007f88116fded7 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
No symbol table info available.
#7 0x00007f8810f51936 in QDialog::exec() () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#8 0x00007f87e8a2c32c in ?? () from /usr/lib/python2.7/dist-packages/PyQt4/QtGui.so
No symbol table info available.
#9 0x00007f87e95a55d5 in PyEval_EvalFrameEx () from /usr/lib/libpython2.7.so.1.0
No symbol table info available.
#10 0x00007f87e95656b5 in PyEval_EvalCodeEx () from /usr/lib/libpython2.7.so.1.0
No symbol table info available.
#11 0x00007f87e956586d in ?? () from /usr/lib/libpython2.7.so.1.0
No symbol table info available.
#12 0x00007f87e964a053 in PyObject_Call () from /usr/lib/libpython2.7.so.1.0
No symbol table info available.
#13 0x00007f87e962e39f in ?? () from /usr/lib/libpython2.7.so.1.0
No symbol table info available.
#14 0x00007f87e964a053 in PyObject_Call () from /usr/lib/libpython2.7.so.1.0
No symbol table info available.
#15 0x00007f87e964a9a7 in PyEval_CallObjectWithKeywords () from /usr/lib/libpython2.7.so.1.0
No symbol table info available.
#16 0x00007f87e92fef80 in sip_api_invoke_slot () from /usr/lib/python2.7/dist-packages/sip.so
No symbol table info available.
#17 0x00007f87e9024396 in ?? () from /usr/lib/python2.7/dist-packages/PyQt4/QtCore.so
No symbol table info available.
#18 0x00007f87e9024690 in ?? () from /usr/lib/python2.7/dist-packages/PyQt4/QtCore.so
No symbol table info available.
#19 0x00007f87e9024772 in ?? () from /usr/lib/python2.7/dist-packages/PyQt4/QtCore.so
No symbol table info available.
#20 0x00007f8811713489 in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
No symbol table info available.
#21 0x00007f8810a7b132 in QAction::triggered(bool) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#22 0x00007f8810a7b31f in QAction::activate(QAction::ActionEvent) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#23 0x00007f8810ecd119 in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#24 0x00007f8810ed3272 in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#25 0x00007f87e891f201 in ?? () from /usr/lib/python2.7/dist-packages/PyQt4/QtGui.so
No symbol table info available.
#26 0x00007f8810ad2144 in QWidget::event(QEvent*) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#27 0x00007f8810ed480b in QMenu::event(QEvent*) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#28 0x00007f87e8922efd in ?? () from /usr/lib/python2.7/dist-packages/PyQt4/QtGui.so
No symbol table info available.
#29 0x00007f8810a81894 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#30 0x00007f8810a870bf in QApplication::notify(QObject*, QEvent*) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#31 0x00007f881265a546 in QgsApplication::notify(QObject*, QEvent*) () from /usr/lib/libqgis_core.so.2.1.0
No symbol table info available.
#32 0x00007f88116fee9c in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
No symbol table info available.
#33 0x00007f8810a82862 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.
#34 0x00007f8810b022c1 in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#35 0x00007f8810b00bae in QApplication::x11ProcessEvent(_XEvent*) () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#36 0x00007f8810b2a0d2 in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#37 0x00007f880d5bbd13 in g_main_context_dispatch () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
No symbol table info available.
#38 0x00007f880d5bc060 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
No symbol table info available.
#39 0x00007f880d5bc124 in g_main_context_iteration () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
No symbol table info available.
#40 0x00007f881172e3bf in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
No symbol table info available.
#41 0x00007f8810b29d5e in ?? () from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
No symbol table info available.
#42 0x00007f88116fdc82 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
No symbol table info available.
#43 0x00007f88116fded7 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
No symbol table info available.
#44 0x00007f8811702f67 in QCoreApplication::exec() () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
No symbol table info available.
#45 0x00000000004ea6c6 in main ()
No symbol table info available.
gdb returned 0
Aborted (core dumped)

#2 Updated by Salvatore Larosa about 6 years ago

  • Status changed from Open to Closed

#3 Updated by Dedy Fuadi over 5 years ago

  • File doGeometry.pyMagnifier added
  • % Done changed from 0 to 100
  • Assignee set to Giovanni Manghi

Hello friends, I have found the solution for this error (python error when we try to add geometry columns by qgis).

#4 Updated by Dedy Fuadi over 5 years ago

  • Assignee changed from Giovanni Manghi to Andrey Isakov

That file is for you too, Andrey Isakov . :D

#5 Updated by Giovanni Manghi over 5 years ago

  • Resolution set to fixed/implemented

Dedy Fuadi wrote:

Hello friends, I have found the solution for this error (python error when we try to add geometry columns by qgis).

what your patch brings more than the fix already committed for this issue?

#6 Updated by Dedy Fuadi over 5 years ago

  • Assignee changed from Andrey Isakov to Giovanni Manghi

Giovanni Manghi wrote:

Dedy Fuadi wrote:

Hello friends, I have found the solution for this error (python error when we try to add geometry columns by qgis).

what your patch brings more than the fix already committed for this issue?

So far, I'm comfort with file that I've uploaded for this problem. I using QGIS 2.0 Dufour, and when I trying to add geometry columns for some line is so far so good. No error founded there.

Sorry for my bad English skill.

#7 Updated by Giovanni Manghi over 2 years ago

The "ftools" category is being removed from the tracker, changing the category of this ticket to "Processing/QGIS" to not leave the category orphaned.

Also available in: Atom PDF