qa: Disable Qt's glib event dispatcher for GUI tests on OpenBSD #35954

pull hebasto wants to merge 1 commits into bitcoin:master from hebasto:260811-openbsd-gui-test changing 1 files +11 −0
  1. hebasto commented at 8:36 AM on August 12, 2026: member

    When bitcoin-gui is built against OpenBSD's system Qt packages (which have GLib support), shutdown emits "GLib-CRITICAL **: g_main_context_pop_thread_default: assertion 'stack != NULL' failed" messages on stderr, which the test framework treats as a failure.

    Set QT_NO_GLIB=1 so Qt falls back to its poll-based event dispatcher, which avoids the GLib thread-default context entirely.

    Fixes #35851.

    See the CI log here: https://github.com/hebasto/bitcoin-core-nightly/actions/runs/31510478034.

  2. qa: Disable Qt's glib event dispatcher for GUI tests on OpenBSD
    When bitcoin-gui is built against OpenBSD's system Qt packages (which
    have GLib support), shutdown emits "GLib-CRITICAL **:
    g_main_context_pop_thread_default: assertion 'stack != NULL' failed"
    messages on stderr, which the test framework treats as a failure.
    
    Set `QT_NO_GLIB=1` so Qt falls back to its poll-based event dispatcher,
    which avoids the GLib thread-default context entirely.
    de2adc308a
  3. DrahtBot added the label Tests on Aug 12, 2026
  4. DrahtBot commented at 8:36 AM on August 12, 2026: contributor

    <!--e57a25ab6845829454e8d69fc972939a-->

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    <!--006a51241073e994b41acfe9ec718e94-->

    Code Coverage & Benchmarks

    For details see: https://corecheck.dev/bitcoin/bitcoin/pulls/35954.

    <!--021abf342d371248e50ceaed478a90ca-->

    Reviews

    See the guideline and AI policy for information on the review process.

    Type Reviewers
    ACK maflcko

    If your review is incorrectly listed, please copy-paste <code>&lt;!--meta-tag:bot-skip--&gt;</code> into the comment that the bot should ignore.

    <!--5faf32d7da4f0f540f40219e4f7537a3-->

  5. in test/functional/test_framework/test_node.py:290 in de2adc308a
     286 | @@ -287,6 +287,17 @@ def start(self, extra_args=None, *, cwd=None, stdout=None, stderr=None, env=None
     287 |                  # does not provide. In particular, painting a QGroupBox can make Qt call
     288 |                  # addSubview: on an invalid native object (QTBUG-49686).
     289 |                  subp_env.setdefault("QT_STYLE_OVERRIDE", "fusion")
     290 | +            if platform.system() == "OpenBSD":
    


    fanquake commented at 9:17 AM on August 12, 2026:

    Where is the actual bug here, I'm guessing it's in Qt (has it been reported?).

    so shutdown emits messages like (process:NNN): GLib-CRITICAL **: g_main_context_pop_thread_default: assertion 'stack != NULL' failed

    This might suppress the output for the test framework here, but does this mean any users who self-compile, might also see this output on shutdown?


    hebasto commented at 10:24 AM on August 12, 2026:

    so shutdown emits messages like (process:NNN): GLib-CRITICAL **: g_main_context_pop_thread_default: assertion 'stack != NULL' failed

    This might suppress the output for the test framework here, but does this mean any users who self-compile, might also see this output on shutdown?

    Yes, users building against OpenBSD's system Qt packages will still see this output on shutdown:

    openbsd$ ./build_dev_mode/bin/bitcoin-qt -regtest                                                                          
    
    (bitcoin-qt:63886): GLib-CRITICAL **: 12:14:30.507: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
    
    (bitcoin-qt:63886): GLib-CRITICAL **: 12:14:30.509: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
    
    (bitcoin-qt:63886): GLib-CRITICAL **: 12:14:30.510: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
    
    (bitcoin-qt:63886): GLib-CRITICAL **: 12:14:30.630: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
    
    (bitcoin-qt:63886): GLib-CRITICAL **: 12:14:30.676: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
    
    (bitcoin-qt:63886): GLib-CRITICAL **: 12:14:30.678: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
    
    (bitcoin-qt:63886): GLib-CRITICAL **: 12:14:30.679: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
    
    (bitcoin-qt:63886): GLib-CRITICAL **: 12:14:30.680: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
    
    (bitcoin-qt:63886): GLib-CRITICAL **: 12:14:30.691: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
    
    (bitcoin-qt:63886): GLib-CRITICAL **: 12:14:30.703: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
    openbsd$ ./build_dev_mode/bin/bitcoin-gui -regtest
    
    (bitcoin-gui:87818): GLib-CRITICAL **: 12:15:09.239: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
    
    (bitcoin-gui:87818): GLib-CRITICAL **: 12:15:09.241: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
    
    (bitcoin-gui:87818): GLib-CRITICAL **: 12:15:09.243: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
    
    (bitcoin-gui:87818): GLib-CRITICAL **: 12:15:09.345: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
    
    (bitcoin-gui:87818): GLib-CRITICAL **: 12:15:09.372: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
    
    (bitcoin-gui:87818): GLib-CRITICAL **: 12:15:09.373: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
    
    (bitcoin-gui:87818): GLib-CRITICAL **: 12:15:09.374: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
    
    (bitcoin-gui:87818): GLib-CRITICAL **: 12:15:09.376: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
    
    (bitcoin-gui:87818): GLib-CRITICAL **: 12:15:09.387: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
    
    (bitcoin-gui:87818): GLib-CRITICAL **: 12:15:09.400: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
    

    hebasto commented at 10:27 AM on August 12, 2026:

    Where is the actual bug here, I'm guessing it's in Qt...

    It seems so. FWIW, the release builds are not affected:https://github.com/bitcoin/bitcoin/blob/1f5c46f7ce2527b926a1517e8901dbccf1503560/depends/packages/qt.mk#L64


    hebasto commented at 10:32 AM on August 12, 2026:

    Where is the actual bug here, I'm guessing it's in Qt...

    However, this forum discussion states:

    That error message comes from glib, not from Qt.

  6. maflcko commented at 7:52 AM on August 18, 2026: member

    lgtm ACK de2adc308a421ea57414c4e28f9a75350df54f25

  7. fanquake merged this on Aug 18, 2026
  8. fanquake closed this on Aug 18, 2026


github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-08-21 04:51 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me