Bug 390047 - SyncedCatalogComponent crash on startup
Summary: SyncedCatalogComponent crash on startup
Status: RESOLVED NOT A BUG
Alias: None
Product: kstars
Classification: Applications
Component: general (show other bugs)
Version: 2.9.2
Platform: Compiled Sources Linux
: NOR crash
Target Milestone: ---
Assignee: Jasem Mutlaq
URL:
Keywords: drkonqi
Depends on:
Blocks:
 
Reported: 2018-02-07 22:05 UTC by Hans Lambermont
Modified: 2018-02-08 21:09 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Hans Lambermont 2018-02-07 22:05:31 UTC
Application: kstars (2.9.2)
 (Compiled from sources)
Qt Version: 5.6.1
Frameworks Version: 5.36.0
Operating System: Linux 4.4.0-101-generic x86_64
Distribution: Ubuntu 16.04.3 LTS

-- Information about the crash:
startup after local compile
used http://www.indilib.org/forum/general/210-howto-building-latest-libindi-ekos.html to build kstars on 16.04

The crash can be reproduced every time.

-- Backtrace:
Application: KStars (kstars), signal: Aborted
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[Current thread is 1 (Thread 0x7f7c7adb6940 (LWP 28302))]

Thread 6 (Thread 0x7f7c6e4a5700 (LWP 28308)):
#0  pthread_cond_timedwait@@GLIBC_2.3.2 () at ../sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S:225
#1  0x00007f7c8b0195f6 in QWaitCondition::wait(QMutex*, unsigned long) () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#2  0x00007f7c8b014e2a in ?? () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#3  0x00007f7c8b018808 in ?? () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#4  0x00007f7c8a30e6ba in start_thread (arg=0x7f7c6e4a5700) at pthread_create.c:333
#5  0x00007f7c8918f3dd in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:109

Thread 5 (Thread 0x7f7c6eca6700 (LWP 28307)):
#0  pthread_cond_timedwait@@GLIBC_2.3.2 () at ../sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S:225
#1  0x00007f7c8b0195f6 in QWaitCondition::wait(QMutex*, unsigned long) () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#2  0x00007f7c8b014e2a in ?? () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#3  0x00007f7c8b018808 in ?? () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#4  0x00007f7c8a30e6ba in start_thread (arg=0x7f7c6eca6700) at pthread_create.c:333
#5  0x00007f7c8918f3dd in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:109

Thread 4 (Thread 0x7f7c6f4a7700 (LWP 28306)):
#0  pthread_cond_timedwait@@GLIBC_2.3.2 () at ../sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S:225
#1  0x00007f7c8b0195f6 in QWaitCondition::wait(QMutex*, unsigned long) () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#2  0x00007f7c8b014e2a in ?? () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#3  0x00007f7c8b018808 in ?? () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#4  0x00007f7c8a30e6ba in start_thread (arg=0x7f7c6f4a7700) at pthread_create.c:333
#5  0x00007f7c8918f3dd in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:109

Thread 3 (Thread 0x7f7c75a83700 (LWP 28304)):
#0  0x00007f7c8918370d in poll () at ../sysdeps/unix/syscall-template.S:84
#1  0x00007f7c8594c38c in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x00007f7c8594c49c in g_main_context_iteration () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#3  0x00007f7c8b24237b in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#4  0x00007f7c8b1eaffa in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#5  0x00007f7c8b0139e4 in QThread::exec() () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#6  0x00007f7c8f1e5515 in ?? () from /usr/lib/x86_64-linux-gnu/libQt5DBus.so.5
#7  0x00007f7c8b018808 in ?? () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#8  0x00007f7c8a30e6ba in start_thread (arg=0x7f7c75a83700) at pthread_create.c:333
#9  0x00007f7c8918f3dd in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:109

Thread 2 (Thread 0x7f7c77e50700 (LWP 28303)):
#0  0x00007f7c8918370d in poll () at ../sysdeps/unix/syscall-template.S:84
#1  0x00007f7c83743c62 in ?? () from /usr/lib/x86_64-linux-gnu/libxcb.so.1
#2  0x00007f7c837458d7 in xcb_wait_for_event () from /usr/lib/x86_64-linux-gnu/libxcb.so.1
#3  0x00007f7c7a9d8d29 in ?? () from /usr/lib/x86_64-linux-gnu/libQt5XcbQpa.so.5
#4  0x00007f7c8b018808 in ?? () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#5  0x00007f7c8a30e6ba in start_thread (arg=0x7f7c77e50700) at pthread_create.c:333
#6  0x00007f7c8918f3dd in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:109

Thread 1 (Thread 0x7f7c7adb6940 (LWP 28302)):
[KCrash Handler]
#6  0x00007f7c890bd428 in __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:54
#7  0x00007f7c890bf02a in __GI_abort () at abort.c:89
#8  0x00007f7c8affff41 in QMessageLogger::fatal(char const*, ...) const () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#9  0x00007f7c8affb39e in qt_assert(char const*, char const*, int) () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#10 0x000055f2357ffa19 in SyncedCatalogComponent::SyncedCatalogComponent (this=0x55f238098230, parent=0x55f23635d260, catname=..., showerrs=true, index=0) at /home/hans/src/kstars/kstars/skycomponents/syncedcatalogcomponent.cpp:57
#11 0x000055f2357ca4f2 in SkyMapComposite::SkyMapComposite (this=0x55f23635d250, parent=0x0) at /home/hans/src/kstars/kstars/skycomponents/skymapcomposite.cpp:158
#12 0x000055f2352b60e8 in KStarsData::initialize (this=0x55f236209d90) at /home/hans/src/kstars/kstars/kstarsdata.cpp:206
#13 0x000055f2352f6191 in KStars::KStars (this=0x55f23619f750, doSplash=true, clockrun=true, startdate=..., __in_chrg=<optimized out>, __vtt_parm=<optimized out>) at /home/hans/src/kstars/kstars/kstars.cpp:241
#14 0x000055f2352f62ae in KStars::createInstance (doSplash=true, clockrun=true, startdate=...) at /home/hans/src/kstars/kstars/kstars.cpp:257
#15 0x000055f235294c6e in main (argc=1, argv=0x7fff0d4d3328) at /home/hans/src/kstars/kstars/main.cpp:305

Possible duplicates by query: bug 389875, bug 389801, bug 388864, bug 384983, bug 382788.

Reported using DrKonqi
Comment 1 Jasem Mutlaq 2018-02-08 05:25:48 UTC
Did you add any objects from the internet using the Find dialog?
Comment 2 Csaba Kertész 2018-02-08 07:00:48 UTC
What happens if you reinstall the bleeding version and run that instead of the locally compiled:

sudo apt-get remove kstars-bleeding
sudo apt-get install kstars-bleeding
kstars

Does it crash in the same way?

This line crashes, strange:

Q_ASSERT(m_catId >= 0);
Comment 3 Hans Lambermont 2018-02-08 18:06:16 UTC
(In reply to Jasem Mutlaq from comment #1)
> Did you add any objects from the internet using the Find dialog?

It did not get that far, kstars immediately crashes before making a window.

I've installed your ppa kstars bleeding, that one runs fine. The self compiled one still crashes immediately.
Comment 4 Hans Lambermont 2018-02-08 18:10:57 UTC
(In reply to Hans Lambermont from comment #3)
> (In reply to Jasem Mutlaq from comment #1)
> > Did you add any objects from the internet using the Find dialog?
> 
> It did not get that far, kstars immediately crashes before making a window.
> 
> I've installed your ppa kstars bleeding, that one runs fine. The self
> compiled one still crashes immediately.

not fine, but it does not crash. Here's what's on stdout/stderr :

kstars
org.kde.kstars.catalog: DSO DB does not exist!
org.kde.kstars.catalog: "Unable to open DSO database file!"
org.kde.kstars.catalog: QSqlError("-1", "Error opening database", "out of memory")
org.kde.kstars: Unable to open user database file.
org.kde.kstars: QSqlError("-1", "Error opening database", "out of memory")
org.kde.kstars: "Star HD20794 not found."
org.kde.kstars: "Star HD98230 not found."
File opened:  "/home/hans/.local/share/kstars/ngcic.dat"
Creating new catalog  "_Internet_Resolved"
QSqlQuery::prepare: database not open
""
QSqlError("", "Unable to fetch row", "No query")
Creating new catalog  "_Manual_Additions"
QSqlQuery::prepare: database not open
""
QSqlError("", "Unable to fetch row", "No query")
File opened:  "/home/hans/.local/share/kstars/asteroids.dat"
File opened:  "/home/hans/.local/share/kstars/comets.dat"
Could not open fov.dat.
org.kde.kstars: "Object named NGC 6050A not found"
org.kde.kstars: "Object named 2 Encke not found"
org.kde.kstars: "Object named 81 Wild 2 not found"
Daylight Saving Time inactive
Next Daylight Savings Time change (Local Time):  "zo mrt. 25 01:00:00 2018 GMT"
Next Daylight Savings Time change (UTC):  "za mrt. 24 00:00:00 2018 GMT"
The current Date/Time is:  "do feb. 8 18:58:01 2018"
glibc >= 2.1 detected.  Using GNU extension sincos()
QSqlQuery::exec: database not open
org.kde.kstars: "INSERT INTO profile (name) VALUES('jungle_lord_observatory')" " "
QSqlQuery::exec: database not open
org.kde.kstars: "" " "
QSqlQuery::exec: database not open
org.kde.kstars: "" " "
QSqlQuery::exec: database not open
org.kde.kstars: "" " "
QSqlQuery::exec: database not open
org.kde.kstars: "" " "
QSqlQuery::exec: database not open
org.kde.kstars: "" " "
QSqlQuery::exec: database not open
org.kde.kstars: "" " "
QSqlQuery::exec: database not open
org.kde.kstars: "" " "
QSqlQuery::exec: database not open
org.kde.kstars: "" " "
QSqlQuery::exec: database not open
org.kde.kstars: "" " "
QSqlQuery::exec: database not open
org.kde.kstars: "" " "
QSqlQuery::exec: database not open
org.kde.kstars: "" " "
QSqlQuery::exec: database not open
org.kde.kstars: "" " "
Comment 5 Hans Lambermont 2018-02-08 21:09:09 UTC
Found the issue !
citydb.sqlite and skycultures.sqlite were owned by root:root with 644 and the directory itself was also root:root so that userdb.sqlite could not even be made.
-> ticket closed as invalid. Better error handling like which .sqlite file could not be opened for writing would be welcome.