After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 782678 - Regularly crashes shortly after startup: gbp_flatpak_application_addin_has_runtime: assertion failed: (id != NULL)
Regularly crashes shortly after startup: gbp_flatpak_application_addin_has_ru...
Status: RESOLVED FIXED
Product: gnome-builder
Classification: Other
Component: general
Flatpak Stable Channel
Other Linux
: Normal normal
: ---
Assigned To: GNOME Builder Maintainers
GNOME Builder Maintainers
Depends on:
Blocks:
 
 
Reported: 2017-05-16 05:33 UTC by Adrien Plazas
Modified: 2017-05-18 03:15 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
flatpak: handle NULL parameters gracefully (1.39 KB, patch)
2017-05-18 03:14 UTC, Christian Hergert
committed Details | Review

Description Adrien Plazas 2017-05-16 05:33:07 UTC
Using the latest Stable Flatpak version, Build regularly crashes shortly after starting it with this error message:
gbp-flatpak-application-addin:ERROR:gbp-flatpak-application-addin.c:685:gbp_flatpak_application_addin_has_runtime: assertion failed: (id != NULL)
Comment 1 Christian Hergert 2017-05-16 06:44:26 UTC
Hrmm, it'd be really nice if we had a stack trace for this. I can easily work around the assertion, but without a stack trace I'm concerned we might be in a situation where we have a NULL runtime id floating around somewhere it shouldn't.
Comment 2 Adrien Plazas 2017-05-16 09:52:20 UTC
I tried to generate one before writing this report but with no success: 'coredumpctl gdb' -> 'bt' gave no symbols. Is there any way to work around that?
Comment 3 Christian Hergert 2017-05-17 02:58:08 UTC
You probably need to do something like the following to get debug symbols:

  flatpak install gnome-apps org.gnome.Builder.Debug

Then something like:

  flatpak run --command=bash org.gnome.Builder
  bash$ gdb --args gnome-builder -vvvv
  ... crash
  gdb) bt
Comment 4 Adrien Plazas 2017-05-17 09:26:03 UTC
Thanks, here is what I got:

gbp-flatpak-application-addin:ERROR:gbp-flatpak-application-addin.c:685:gbp_flatpak_application_addin_has_runtime: assertion failed: (id != NULL)

Thread 1 "gnome-builder" received signal SIGABRT, Aborted.
0x0000003cd003304f in raise () from /lib/libc.so.6
(gdb) bt
  • #0 raise
    from /lib/libc.so.6
  • #1 abort
    from /lib/libc.so.6
  • #2 g_assertion_message
    from /lib/libglib-2.0.so.0
  • #3 g_assertion_message_expr
    from /lib/libglib-2.0.so.0
  • #4 gbp_flatpak_application_addin_has_runtime
    at gbp-flatpak-application-addin.c line 685
  • #5 gbp_flatpak_runtime_provider_locate_sdk_cb
    at gbp-flatpak-runtime-provider.c line 325
  • #6 ??
    from /lib/libgio-2.0.so.0
  • #7 ??
    from /lib/libgio-2.0.so.0
  • #8 g_main_context_dispatch
    from /lib/libglib-2.0.so.0
  • #9 ??
    from /lib/libglib-2.0.so.0
  • #10 g_main_context_iteration
    from /lib/libglib-2.0.so.0
  • #11 g_application_run
    from /lib/libgio-2.0.so.0
  • #12 main
    at main.c line 119

Comment 5 Adrien Plazas 2017-05-17 09:27:20 UTC
Oh and just before that there is this debug message (dunno if it's related):
11:25:06.0190                                   flatpak[17]:    DEBUG: Using cached summary for remote org.gnome.Games-origin
Comment 6 Christian Hergert 2017-05-18 03:14:42 UTC
Created attachment 352058 [details] [review]
flatpak: handle NULL parameters gracefully

These can happen in various places where we read an id/branch/arch out of
ancillary data and it is empty. In most places we use g_strcmp0() to be
NULL-safe, to to simplify those code-paths, just handle NULL here.
Comment 7 Christian Hergert 2017-05-18 03:15:35 UTC
Thanks for tracking stuff down!

Based on the issue, I'm fine with just reducing our assertion shere and
gracefully handling NULL. The associated patch does just that.

Attachment 352058 [details] pushed as fc76d45 - flatpak: handle NULL parameters gracefully