Skip to content

Add option to wait for GUI session#42

Merged
marmarek merged 1 commit intoQubesOS:mainfrom
marmarek:wait-for-gui
Mar 21, 2026
Merged

Add option to wait for GUI session#42
marmarek merged 1 commit intoQubesOS:mainfrom
marmarek:wait-for-gui

Conversation

@marmarek
Copy link
Copy Markdown
Member

Wait for GUI agent to report that GUI daemon has connected. This in
practice waits for the user to log into GUI domain (or dom0).
This is relevant if the qrexec policy for qubes.Input* is set to ask -
if the user is not logged in yet, the qrexec prompt cannot be displayed,
and the qrexec prompt would be denied.

Keep the change compatible with the old GUI agent (the same package may
be installed on R4.2) - if the status file is not there, skip the wait.
And to make the update least intrusive, only recommend pyinotify, but if
it's not there, fallback to polling the file.

QubesOS/qubes-issues#9940
QubesOS/qubes-gui-agent-linux#251 (comment)

Wait for GUI agent to report that GUI daemon has connected. This in
practice waits for the user to log into GUI domain (or dom0).
This is relevant if the qrexec policy for qubes.Input* is set to ask -
if the user is not logged in yet, the qrexec prompt cannot be displayed,
and the qrexec prompt would be denied.

Keep the change compatible with the old GUI agent (the same package may
be installed on R4.2) - if the status file is not there, skip the wait.
And to make the update least intrusive, only recommend pyinotify, but if
it's not there, fallback to polling the file.

QubesOS/qubes-issues#9940
QubesOS/qubes-gui-agent-linux#251 (comment)
@qubesos-bot
Copy link
Copy Markdown

qubesos-bot commented Dec 15, 2025

OpenQA test summary

Complete test suite and dependencies: https://openqa.qubes-os.org/tests/overview?distri=qubesos&version=4.3&build=2026031800-4.3&flavor=pull-requests

Test run included the following:

New failures, excluding unstable

Compared to: https://openqa.qubes-os.org/tests/overview?distri=qubesos&version=4.3&build=2026020304-devel&flavor=update

  • system_tests_pvgrub_salt_storage

  • system_tests_guivm_gui_interactive

    • collect_logs: wait_serial (wait serial expected)
      # wait_serial expected: qr/PXxYu-\d+-/...

    • collect_logs: Failed (test died + timed out)
      # Test died: command 'curl --form upload=@journalctl.log --form upn...

    • collect_logs: wait_serial (wait serial expected)
      # wait_serial expected: qr/y_zzX-\d+-/...

  • system_tests_network_ipv6

  • system_tests_network_updates

    • TC_11_QvmTemplateMgmtVM_debian-13-xfce: test_000_template_list (failure)
      qvm-template: error: No matching templates to list

    • TC_11_QvmTemplateMgmtVM_debian-13-xfce: test_010_template_install (failure)
      qvm-template: error: Template 'debian-12-minimal' not found.

    • TC_11_QvmTemplateMgmtVM_fedora-42-xfce: test_000_template_list (failure)
      qvm-template: error: No matching templates to list

    • TC_11_QvmTemplateMgmtVM_fedora-42-xfce: test_010_template_install (failure)
      qvm-template: error: Template 'debian-12-minimal' not found.

    • TC_11_QvmTemplateMgmtVM_whonix-gateway-18: test_000_template_list (failure)
      qvm-template: error: No matching templates to list

    • TC_11_QvmTemplateMgmtVM_whonix-gateway-18: test_010_template_install (failure)
      qvm-template: error: Template 'debian-12-minimal' not found.

  • system_tests_qwt_win10_seamless@hw13

    • windows_install: Failed (test died)
      # Test died: Install failed with code 1 at qubesos/tests/windows_in...
  • system_tests_qwt_win11@hw13

  • system_tests_basic_vm_qrexec_gui_xfs

    • TC_20_NonAudio_whonix-gateway-18-pool: test_010_run_xterm (error)
      subprocess.CalledProcessError: Command 'qubes.WaitForSession' retur...
  • system_tests_basic_vm_qrexec_gui@hw7

Failed tests

24 failures
  • system_tests_whonix

    • whonixcheck: fail (unknown)
      Whonixcheck for whonix-gateway-18 failed...

    • whonixcheck: fail (unknown)
      Whonixcheck for sys-whonix failed...

    • whonixcheck: fail (unknown)
      Whonixcheck for whonix-workstation-18 failed...

    • whonixcheck: Failed (test died)
      # Test died: systemcheck failed at qubesos/tests/whonixcheck.pm lin...

  • system_tests_network

  • system_tests_pvgrub_salt_storage

    • TC_41_HVMGrub_debian-13-xfce: test_010_template_based_vm (error)
      qubes.exc.QubesVMError: Cannot connect to qrexec agent for 120 seco...

    • TC_41_HVMGrub_debian-13-xfce: test_011_template_based_vm_dracut (error)
      qubes.exc.QubesVMError: Cannot connect to qrexec agent for 120 seco...

    • TC_41_HVMGrub_fedora-42-xfce: test_000_standalone_vm (error)
      qubes.exc.QubesVMError: Cannot connect to qrexec agent for 120 seco...

    • TC_41_HVMGrub_fedora-42-xfce: test_010_template_based_vm (error)
      qubes.exc.QubesVMError: Cannot connect to qrexec agent for 120 seco...

  • system_tests_guivm_gui_interactive

    • collect_logs: wait_serial (wait serial expected)
      # wait_serial expected: qr/PXxYu-\d+-/...

    • collect_logs: Failed (test died + timed out)
      # Test died: command 'curl --form upload=@journalctl.log --form upn...

    • collect_logs: wait_serial (wait serial expected)
      # wait_serial expected: qr/y_zzX-\d+-/...

  • system_tests_network_ipv6

  • system_tests_network_updates

    • TC_11_QvmTemplateMgmtVM_debian-13-xfce: test_000_template_list (failure)
      qvm-template: error: No matching templates to list

    • TC_11_QvmTemplateMgmtVM_debian-13-xfce: test_010_template_install (failure)
      qvm-template: error: Template 'debian-12-minimal' not found.

    • TC_11_QvmTemplateMgmtVM_fedora-42-xfce: test_000_template_list (failure)
      qvm-template: error: No matching templates to list

    • TC_11_QvmTemplateMgmtVM_fedora-42-xfce: test_010_template_install (failure)
      qvm-template: error: Template 'debian-12-minimal' not found.

    • TC_11_QvmTemplateMgmtVM_whonix-gateway-18: test_000_template_list (failure)
      qvm-template: error: No matching templates to list

    • TC_11_QvmTemplateMgmtVM_whonix-gateway-18: test_010_template_install (failure)
      qvm-template: error: Template 'debian-12-minimal' not found.

  • system_tests_qwt_win10_seamless@hw13

    • windows_install: Failed (test died)
      # Test died: Install failed with code 1 at qubesos/tests/windows_in...
  • system_tests_qwt_win11@hw13

    • windows_clipboard_and_filecopy: unnamed test (unknown)
    • windows_clipboard_and_filecopy: Failed (test died)
      # Test died: no candidate needle with tag(s) 'windows-apps-features...
  • system_tests_basic_vm_qrexec_gui_xfs

    • TC_20_NonAudio_whonix-gateway-18-pool: test_010_run_xterm (error)
      subprocess.CalledProcessError: Command 'qubes.WaitForSession' retur...
  • system_tests_basic_vm_qrexec_gui@hw7

Fixed failures

Compared to: https://openqa.qubes-os.org/tests/166096#dependencies

25 fixed
  • system_tests_whonix

    • whonixcheck: wait_serial (wait serial expected)
      # wait_serial expected: qr/D8rIe-\d+-/...
  • system_tests_network

  • system_tests_gui_interactive

    • collect_logs: wait_serial (wait serial expected)
      # wait_serial expected: qr/m~uU4-\d+-/...

    • collect_logs: Failed (test died + timed out)
      # Test died: command 'curl --form upload=@journalctl.log --form upn...

  • system_tests_network_ipv6

  • system_tests_network_updates

    • TC_00_Dom0Upgrade_whonix-gateway-18: test_000_update_salt (failure)
      ?[0;31mDuration: 139139.863 ms?[0;0m... ?[0;31m Changes: ?[0;0m
  • system_tests_dispvm

    • system_tests: Fail (unknown)
      Tests qubes.tests.integ.dispvm failed (exit code 1), details report...

    • system_tests: Failed (test died)
      # Test died: Some tests failed at qubesos/tests/system_tests.pm lin...

    • TC_20_DispVM_whonix-workstation-18: test_015_preload_race_more (error)
      raise TimeoutError from exc_val... TimeoutError

  • system_tests_guivm_vnc_gui_interactive

    • guivm_manager: unnamed test (unknown)

    • guivm_manager: Failed (test died)
      # Test died: no candidate needle with tag(s) 'menu-qubes-tools' mat...

    • guivm_manager: wait_serial (wait serial expected)
      # wait_serial expected: qr/yp0HG-\d+-/...

  • system_tests_audio

    • system_tests: Fail (unknown)
      Tests qubes.tests.integ.audio failed (exit code 1), details reporte...

    • system_tests: Failed (test died)
      # Test died: Some tests failed at qubesos/tests/system_tests.pm lin...

    • TC_20_AudioVM_PipeWire_whonix-workstation-18: test_260_audio_mic_enabled_switch_audiovm (failure)
      AssertionError: Failed to get mic attach/detach status!

  • system_tests_qwt_win10@hw13

    • windows_clipboard_and_filecopy: unnamed test (unknown)
    • windows_clipboard_and_filecopy: Failed (test died)
      # Test died: no candidate needle with tag(s) 'windows-Edge-setup-no...
  • system_tests_qwt_win10_seamless@hw13

    • windows_clipboard_and_filecopy: unnamed test (unknown)
    • windows_clipboard_and_filecopy: Failed (test died)
      # Test died: no candidate needle with tag(s) 'windows-Edge-setup-no...
  • system_tests_qwt_win11@hw13

Unstable tests

Details
  • system_tests_gui_interactive

    collect_logs/Failed (1/5 times with errors)
    • job 169132 # Test died: command 'curl --form upload=@journalctl.log --form upn...
    collect_logs/wait_serial (1/5 times with errors)
    • job 169132 # wait_serial expected: qr/GJUz8-\d+-/...
    collect_logs/wait_serial (1/5 times with errors)
    • job 169132 # wait_serial expected: qr/EAW0M-\d+-/...
  • system_tests_gui_interactive@hw7

    collect_logs/Failed (1/5 times with errors)
    • job 169132 # Test died: command 'curl --form upload=@journalctl.log --form upn...
    collect_logs/wait_serial (1/5 times with errors)
    • job 169132 # wait_serial expected: qr/GJUz8-\d+-/...
    collect_logs/wait_serial (1/5 times with errors)
    • job 169132 # wait_serial expected: qr/EAW0M-\d+-/...

Performance Tests

Performance degradation:

4 performance degradations
  • debian-13-xfce_dom0-dispvm-preload-2-delay-minus-1d2-api (mean:4.595): 55.14 🔻 ( previous job: 47.01, degradation: 117.31%)
  • debian-13-xfce_dom0-vm-gui-api (mean:0.045): 0.54 🔻 ( previous job: 0.48, degradation: 112.06%)
  • fedora-42-xfce_dom0-dispvm-preload-4-api (mean:3.746): 44.95 🔻 ( previous job: 39.46, degradation: 113.93%)
  • whonix-workstation-18_dom0-vm-gui-api (mean:0.078): 0.93 🔻 ( previous job: 0.65, degradation: 144.58%)

Remaining performance tests:

35 tests
  • debian-13-xfce_dom0-dispvm-api (mean:6.937): 83.24 🔻 ( previous job: 79.83, degradation: 104.27%)
  • debian-13-xfce_dom0-dispvm-gui-api (mean:7.742): 92.91 🔻 ( previous job: 92.49, degradation: 100.45%)
  • debian-13-xfce_dom0-dispvm-preload-2-api (mean:3.615): 43.38 🟢 ( previous job: 44.94, improvement: 96.52%)
  • debian-13-xfce_dom0-dispvm-preload-2-delay-0-api (mean:3.586): 43.03 🔻 ( previous job: 41.46, degradation: 103.78%)
  • debian-13-xfce_dom0-dispvm-preload-4-api (mean:3.399): 40.79 🔻 ( previous job: 37.67, degradation: 108.26%)
  • debian-13-xfce_dom0-dispvm-preload-4-delay-0-api (mean:3.321): 39.86 🔻 ( previous job: 36.76, degradation: 108.42%)
  • debian-13-xfce_dom0-dispvm-preload-4-delay-minus-1d2-api (mean:3.471): 41.65 🔻 ( previous job: 37.87, degradation: 109.98%)
  • debian-13-xfce_dom0-dispvm-preload-2-gui-api (mean:4.845): 58.14 🔻 ( previous job: 55.58, degradation: 104.60%)
  • debian-13-xfce_dom0-dispvm-preload-4-gui-api (mean:3.533): 42.40 🟢 ( previous job: 47.73, improvement: 88.84%)
  • debian-13-xfce_dom0-dispvm-preload-6-gui-api (mean:3.649): 43.79 🟢 ( previous job: 47.11, improvement: 92.95%)
  • debian-13-xfce_dom0-vm-api (mean:0.037): 0.44 🔻 ( previous job: 0.41, degradation: 106.30%)
  • fedora-42-xfce_dom0-dispvm-api (mean:7.145): 85.74 🔻 ( previous job: 84.64, degradation: 101.29%)
  • fedora-42-xfce_dom0-dispvm-gui-api (mean:8.52): 102.23 🔻 ( previous job: 99.96, degradation: 102.27%)
  • fedora-42-xfce_dom0-dispvm-preload-2-api (mean:4.135): 49.62 🔻 ( previous job: 47.97, degradation: 103.45%)
  • fedora-42-xfce_dom0-dispvm-preload-2-delay-0-api (mean:4.095): 49.14 🔻 ( previous job: 48.54, degradation: 101.25%)
  • fedora-42-xfce_dom0-dispvm-preload-2-delay-minus-1d2-api (mean:4.328): 51.94 🔻 ( previous job: 50.22, degradation: 103.42%)
  • fedora-42-xfce_dom0-dispvm-preload-4-delay-0-api (mean:3.454): 41.44 🔻 ( previous job: 40.12, degradation: 103.30%)
  • fedora-42-xfce_dom0-dispvm-preload-4-delay-minus-1d2-api (mean:3.786): 45.43 🔻 ( previous job: 42.41, degradation: 107.12%)
  • fedora-42-xfce_dom0-dispvm-preload-2-gui-api (mean:4.72): 56.64 🟢 ( previous job: 62.27, improvement: 90.95%)
  • fedora-42-xfce_dom0-dispvm-preload-4-gui-api (mean:4.279): 51.35 🟢 ( previous job: 54.33, improvement: 94.52%)
  • fedora-42-xfce_dom0-dispvm-preload-6-gui-api (mean:3.755): 45.05 🟢 ( previous job: 54.25, improvement: 83.05%)
  • fedora-42-xfce_dom0-vm-api (mean:0.04): 0.48 🟢 ( previous job: 0.50, improvement: 95.24%)
  • fedora-42-xfce_dom0-vm-gui-api (mean:0.04): 0.48 🟢 ( previous job: 0.49, improvement: 97.15%)
  • whonix-workstation-18_dom0-dispvm-api (mean:9.044): 108.53 🟢 ( previous job: 110.52, improvement: 98.21%)
  • whonix-workstation-18_dom0-dispvm-gui-api (mean:10.518): 126.22 🔻 ( previous job: 121.96, degradation: 103.49%)
  • whonix-workstation-18_dom0-dispvm-preload-2-api (mean:5.59): 67.08 🔻 ( previous job: 64.20, degradation: 104.48%)
  • whonix-workstation-18_dom0-dispvm-preload-2-delay-0-api (mean:5.207): 62.49 🔻 ( previous job: 61.89, degradation: 100.97%)
  • whonix-workstation-18_dom0-dispvm-preload-2-delay-minus-1d2-api (mean:6.012): 72.15 🔻 ( previous job: 69.42, degradation: 103.93%)
  • whonix-workstation-18_dom0-dispvm-preload-4-api (mean:4.666): 55.99 🟢 ( previous job: 56.66, improvement: 98.83%)
  • whonix-workstation-18_dom0-dispvm-preload-4-delay-0-api (mean:5.22): 62.64 🔻 ( previous job: 60.57, degradation: 103.42%)
  • whonix-workstation-18_dom0-dispvm-preload-4-delay-minus-1d2-api (mean:4.673): 56.07 🟢 ( previous job: 59.37, improvement: 94.44%)
  • whonix-workstation-18_dom0-dispvm-preload-2-gui-api (mean:6.422): 77.06 🟢 ( previous job: 77.58, improvement: 99.32%)
  • whonix-workstation-18_dom0-dispvm-preload-4-gui-api (mean:4.942): 59.31 🟢 ( previous job: 69.81, improvement: 84.96%)
  • whonix-workstation-18_dom0-dispvm-preload-6-gui-api (mean:5.31): 63.72 🟢 ( previous job: 68.61, improvement: 92.87%)
  • whonix-workstation-18_dom0-vm-api (mean:0.031): 0.38 🟢 ( previous job: 0.42, improvement: 90.41%)

This was referenced Dec 15, 2025
@marmarek
Copy link
Copy Markdown
Member Author

PipelineRetry

@marmarek marmarek merged commit cd6d205 into QubesOS:main Mar 21, 2026
2 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants