[Qgis-developer] New GRASS plugin: a test drive
Pedro VenĂ¢ncio
pedrongvenancio at gmail.com
Thu Oct 8 16:11:26 PDT 2015
Hi Radim,
I'm getting a Segmentation fault (core dumped):
[Thread 0x8b6c3b40 (LWP 8667) exited]
[Thread 0x6c2ffb40 (LWP 8668) exited]
Program received signal SIGSEGV, Segmentation fault.
0x92c2b869 in Vect_cidx_get_cat_by_index ()
from /usr/lib/grass70/lib/libgrass_vector.so
(gdb) bt
#0 0x92c2b869 in Vect_cidx_get_cat_by_index ()
from /usr/lib/grass70/lib/libgrass_vector.so
#1 0x92d38357 in QgsGrassVectorMapLayer::insertCats (this=0x14639448,
error=...)
at
/home/pedro/qgis/QGIS-master/src/providers/grass/qgsgrassvectormaplayer.cpp:796
#2 0x92d36265 in QgsGrassVectorMapLayer::createTable (this=0x14639448,
fields=
..., error=...)
at
/home/pedro/qgis/QGIS-master/src/providers/grass/qgsgrassvectormaplayer.cpp:646
#3 0x92d367f8 in QgsGrassVectorMapLayer::addColumn (this=0x14639448,
field=..., error=...)
at
/home/pedro/qgis/QGIS-master/src/providers/grass/qgsgrassvectormaplayer.cpp:666
#4 0x92d221aa in QgsGrassProvider::onAttributeAdded (this=0x11448cb0,
idx=2)
at
/home/pedro/qgis/QGIS-master/src/providers/grass/qgsgrassprovider.cpp:1725
#5 0x92d3e5c3 in QgsGrassProvider::qt_static_metacall (_o=0x11448cb0,
_c=QMetaObject::InvokeMetaMethod, _id=4, _a=0xbfdf2118)
at
/home/pedro/qgis/QGIS-master/build-master/src/providers/grass/7/__/moc_qgsgrassprovider.cxx:72
#6 0xb60d50f7 in QMetaObject::activate(QObject*, QMetaObject const*, int,
void**) () from /usr/lib/i386-linux-gnu/libQtCore.so.4
---Type <return> to continue, or q <return> to quit---
#7 0xb6ee1fb0 in QgsVectorLayerEditBuffer::attributeAdded (this=0xc5df620,
_t1=2)
at
/home/pedro/qgis/QGIS-master/build-master/src/core/moc_qgsvectorlayereditbuffer.cxx:177
#8 0xb6d58dbd in QgsVectorLayerUndoCommandAddAttribute::redo
(this=0xcfc1480)
at
/home/pedro/qgis/QGIS-master/src/core/qgsvectorlayerundocommand.cpp:339
#9 0xb5caeed5 in QUndoStack::push(QUndoCommand*) ()
from /usr/lib/i386-linux-gnu/libQtGui.so.4
#10 0xb6d3cf70 in QgsVectorLayerEditBuffer::addAttribute (this=0xc5df620,
field=...)
at
/home/pedro/qgis/QGIS-master/src/core/qgsvectorlayereditbuffer.cpp:227
#11 0xb6d27476 in QgsVectorLayer::addAttribute (this=0xad72720, field=...)
at /home/pedro/qgis/QGIS-master/src/core/qgsvectorlayer.cpp:2181
#12 0xb726aae1 in QgsAttributeTableDialog::on_mAddAttribute_clicked (
this=0x14956a48)
at /home/pedro/qgis/QGIS-master/src/app/qgsattributetabledialog.cpp:689
#13 0xb7599a0f in QgsAttributeTableDialog::qt_static_metacall
(_o=0x14956a48,
_c=QMetaObject::InvokeMetaMethod, _id=12, _a=0xbfdf2458)
at
/home/pedro/qgis/QGIS-master/build-master/src/app/moc_qgsattributetabledialog.cxx:131
#14 0xb7599d86 in QgsAttributeTableDialog::qt_metacall (this=0x14956a48,
_c=QMetaObject::InvokeMetaMethod, _id=12, _a=0xbfdf2458)
at
/home/pedro/qgis/QGIS-master/build-master/src/app/moc_qgsattributetabledi---Type
<return> to continue, or q <return> to quit---
alog.cxx:194
#15 0xb60c6e85 in QMetaObject::metacall(QObject*, QMetaObject::Call, int,
void**) () from /usr/lib/i386-linux-gnu/libQtCore.so.4
#16 0xb60d540d in QMetaObject::activate(QObject*, QMetaObject const*, int,
void**) () from /usr/lib/i386-linux-gnu/libQtCore.so.4
#17 0xb5cc926d in QAbstractButton::clicked(bool) ()
from /usr/lib/i386-linux-gnu/libQtGui.so.4
#18 0xb59e3c21 in ?? () from /usr/lib/i386-linux-gnu/libQtGui.so.4
#19 0xb59e4fa7 in ?? () from /usr/lib/i386-linux-gnu/libQtGui.so.4
#20 0xb59e50ae in QAbstractButton::mouseReleaseEvent(QMouseEvent*) ()
from /usr/lib/i386-linux-gnu/libQtGui.so.4
#21 0xb5ab6977 in QToolButton::mouseReleaseEvent(QMouseEvent*) ()
from /usr/lib/i386-linux-gnu/libQtGui.so.4
#22 0xb562640a in QWidget::event(QEvent*) ()
from /usr/lib/i386-linux-gnu/libQtGui.so.4
#23 0xb59e60b2 in QAbstractButton::event(QEvent*) ()
from /usr/lib/i386-linux-gnu/libQtGui.so.4
#24 0xb5ab6a64 in QToolButton::event(QEvent*) ()
from /usr/lib/i386-linux-gnu/libQtGui.so.4
#25 0xb55cc7f4 in QApplicationPrivate::notify_helper(QObject*, QEvent*) ()
from /usr/lib/i386-linux-gnu/libQtGui.so.4
#26 0xb55d4ea0 in QApplication::notify(QObject*, QEvent*) ()
from /usr/lib/i386-linux-gnu/libQtGui.so.4
---Type <return> to continue, or q <return> to quit---
#27 0xb6b051c7 in QgsApplication::notify (this=0xbfdf3104,
receiver=0xa901438,
event=0xbfdf2954)
at /home/pedro/qgis/QGIS-master/src/core/qgsapplication.cpp:265
#28 0xb60bfe4a in QCoreApplication::notifyInternal(QObject*, QEvent*) ()
from /usr/lib/i386-linux-gnu/libQtCore.so.4
#29 0xb55d2b53 in QApplicationPrivate::sendMouseEvent(QWidget*,
QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer<QWidget>&, bool) ()
from /usr/lib/i386-linux-gnu/libQtGui.so.4
#30 0xb56567a8 in ?? () from /usr/lib/i386-linux-gnu/libQtGui.so.4
#31 0xb5655ef5 in QApplication::x11ProcessEvent(_XEvent*) ()
from /usr/lib/i386-linux-gnu/libQtGui.so.4
#32 0xb5681554 in ?? () from /usr/lib/i386-linux-gnu/libQtGui.so.4
#33 0xb14d11e3 in g_main_context_dispatch ()
from /lib/i386-linux-gnu/libglib-2.0.so.0
#34 0xb14d1468 in ?? () from /lib/i386-linux-gnu/libglib-2.0.so.0
#35 0xb14d1528 in g_main_context_iteration ()
from /lib/i386-linux-gnu/libglib-2.0.so.0
#36 0xb60ef93b in
QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>)
() from /usr/lib/i386-linux-gnu/libQtCore.so.4
#37 0xb568160e in ?? () from /usr/lib/i386-linux-gnu/libQtGui.so.4
#38 0xb60be823 in
QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from
/usr/lib/i386-linux-gnu/libQtCore.so.4
#39 0xb60beb49 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) ()
---Type <return> to continue, or q <return> to quit---
from /usr/lib/i386-linux-gnu/libQtCore.so.4
#40 0xb60c48fe in QCoreApplication::exec() ()
from /usr/lib/i386-linux-gnu/libQtCore.so.4
#41 0xb55caa24 in QApplication::exec() ()
from /usr/lib/i386-linux-gnu/libQtGui.so.4
#42 0x08050705 in main (argc=1, argv=0xbfdf3384)
at /home/pedro/qgis/QGIS-master/src/app/main.cpp:1229
(gdb)
(gdb) continue
Continuando.
[Thread 0x8d2eeb40 (LWP 8596) exited]
[Thread 0x69c04b40 (LWP 8663) exited]
Program terminated with signal SIGSEGV, Segmentation fault.
The program no longer exists.
(gdb)
To reproduce:
1. Open mapset;
2. New Point Layer or New Line Layer (I don't get crash with polygon
layers);
3. Digitize some features;
4. Save edits;
5. Open attribute table;
6. New column;
7. Add a name;
8. Ok. I get the crash and seg fault here. Just with point and line layers.
I also found that saving edits with "Save edits" button in the attribute
tabel takes no effect. With other layers (not GRASS layers), it works well.
I'm using QGIS master compiled after this commit
https://github.com/qgis/QGIS/commit/e703fc6044e3119c3b59fe9648f7dcf7edc2b714
Best regards!
Pedro
2015-10-08 21:47 GMT+01:00 Blumentrath, Stefan <Stefan.Blumentrath at nina.no>:
> >> Testing on windows
> >>>> GRASS LOCATION is "duplicated" displayed as a regular file system
> >>>> folder and as GRASS LOCATION with the GRASS icon
> >>> That is correct, the regular directory is left there so that is it
> >>> possible to go for example to dbf directory and load dbf files as
> >>> standard QGIS layers.
> >>
> >> IMHO: i find it's confusing, and GRASS 7 default database is SQLite, i
> >> think it could be smoother to expose only GRASS Locations and Mapset
> >> being evident that we're dealing with a GRASS Database, but i can live
> >> with that :-)
> >
> >You are not the first who is confused. Fix would be easy, so I remove
> regular dir if it is recognized as GRASS location?
>
> Indeed having the whole folder browseable might be confusing and users are
> not supposed to move files around in there anyway.
> Yet, having the SQLite DB (or dbfs) of a mapset (if existing) available in
> the browser would be nice. That way also related / non-spatial tables in
> there could be easily added to QGIS. Probably even better if a context menu
> entry would allow to add the DB to "DB manager", so one can actually run
> queries without using db.execute or v.db.update... But that`s for the
> future...
>
> Regarding the tools-widget UI, I noticed that the "Close Mapset" butten
> takes space from the module tabs. The old "Close mapset" button was much
> smaller. Would it be possible to move that to the bottom of the GRASS
> module UI, where the Debug buttons are located (if debugging is activated)?
> BTW, the tabs for the open modules can get pretty wide due to the icons
> (see e.g. v.db.join). Maybe better to use module names in the tabs?
>
> Finally, I was wondering if it could be an idea to place all mapset
> related buttons (open / close / new / change mapset) at the bottom of the
> Modules dialogue and to add a "manage mapset access" button, which runs the
> mapset picker for modifying the search path (g.mapsets -s) there as well?
> One (I if you like) can add g.mapsets with the s-flag as a module (I tested
> "g.mapsets -s" in the QGIS-GRASS-plugin and it starts the GRASS dialogue
> successfully), but it is probably better to have this option a bit more
> prominent (as it might come in handy with the new multiple map input
> option)?
>
> Anyway, great work you did and do with the plugin upgrade!
>
> Cheers
> Stefan
>
>
> _______________________________________________
> Qgis-developer mailing list
> Qgis-developer at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/qgis-developer
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20151009/5ab3966c/attachment-0001.html>
More information about the Qgis-developer
mailing list