awesomeWM / awesome

awesome window manager
https://awesomewm.org/
GNU General Public License v2.0
6.33k stars 597 forks source link

Some integration tests are failing with unfocused Xephyr #2674

Open blueyed opened 5 years ago

blueyed commented 5 years ago

When alt-tabbing away from the Xephyr window that opense for the integration tests, I am seeing test failures.

E.g.

% make check-integration TEST_RUN_ARGS=tests/test-resize.lua
…
== Running tests/test-resize.lua ==
Error: running function for step 12/43 (@1): …/src/awesome/tests/test-resize.lua:241: assertion failed!
stack traceback:
        [C]: in function 'assert'
        …/src/awesome/tests/test-resize.lua:241: in function <…/src/awesome/tests/test-resize.lua:239>
        (...tail calls...)
        [C]: in function 'xpcall'
        …/src/awesome/tests/_runner.lua:73: in function <…/src/awesome/tests/_runner.lua:64>
        [C]: in function 'xpcall'
        lib/gears/protected_call.lua:36: in function <lib/gears/protected_call.lua:35>
        (...tail calls...)
        lib/gears/timer.lua:237: in function 'gears.timer.run_delayed_calls_now'!

Full output from make check-integration (with :g/W: awesome: a_glib_poll/d):

Running make check-integration in build…
[  0%] Built target generated_sources
[  0%] Built target version_stamp
[  5%] Built target lgi-check
[  5%] Checking for LGI...
Building for Lua 5.3.
Found lgi 0.9.2.
[  5%] Built target lgi-check-run
[  5%] Built target setup_directories
[ 11%] Built target generate_awesomerc
[ 94%] Built target awesome
[100%] Built target test-gravity
[100%] Running integration tests
awesome_log: /tmp/tmp.Eebn05o3WD/_awesome_test.log
The XKEYBOARD keymap compiler (xkbcomp) reports:
> Warning:          Unsupported high keycode 372 for name <I372> ignored
>                   X11 cannot support keycodes above 255.
>                   This warning only shows for the first high keycode.
> Internal error:   Could not resolve keysym XF86MonBrightnessCycle
Errors from xkbcomp are not fatal to the X server
== Running …/src/awesome/tests/test-awesomerc.lua ==
2019-02-18 21:51:36 W: awesome: beautiful: can't get colorscheme from xrdb for value 'background' (using fallback).
2019-02-18 21:51:36 W: awesome: beautiful: can't get colorscheme from xrdb for value 'foreground' (using fallback).
2019-02-18 21:51:36 W: awesome: beautiful: can't get colorscheme from xrdb for value 'color0' (using fallback).
2019-02-18 21:51:36 W: awesome: beautiful: can't get colorscheme from xrdb for value 'color1' (using fallback).
2019-02-18 21:51:36 W: awesome: beautiful: can't get colorscheme from xrdb for value 'color2' (using fallback).
2019-02-18 21:51:36 W: awesome: beautiful: can't get colorscheme from xrdb for value 'color3' (using fallback).
2019-02-18 21:51:36 W: awesome: beautiful: can't get colorscheme from xrdb for value 'color4' (using fallback).
2019-02-18 21:51:36 W: awesome: beautiful: can't get colorscheme from xrdb for value 'color5' (using fallback).
2019-02-18 21:51:36 W: awesome: beautiful: can't get colorscheme from xrdb for value 'color6' (using fallback).
2019-02-18 21:51:36 W: awesome: beautiful: can't get colorscheme from xrdb for value 'color7' (using fallback).
2019-02-18 21:51:36 W: awesome: beautiful: can't get colorscheme from xrdb for value 'color8' (using fallback).
2019-02-18 21:51:36 W: awesome: beautiful: can't get colorscheme from xrdb for value 'color9' (using fallback).
2019-02-18 21:51:36 W: awesome: beautiful: can't get colorscheme from xrdb for value 'color10' (using fallback).
2019-02-18 21:51:36 W: awesome: beautiful: can't get colorscheme from xrdb for value 'color11' (using fallback).
2019-02-18 21:51:36 W: awesome: beautiful: can't get colorscheme from xrdb for value 'color12' (using fallback).
2019-02-18 21:51:36 W: awesome: beautiful: can't get colorscheme from xrdb for value 'color13' (using fallback).
2019-02-18 21:51:36 W: awesome: beautiful: can't get colorscheme from xrdb for value 'color14' (using fallback).
2019-02-18 21:51:36 W: awesome: beautiful: can't get colorscheme from xrdb for value 'color15' (using fallback).
== Running …/src/awesome/tests/test-awful-client.lua ==
== Running …/src/awesome/tests/test-awful-layout.lua ==
== Running …/src/awesome/tests/test-awful-placement.lua ==
== Running …/src/awesome/tests/test-awful-rules.lua ==
== Running …/src/awesome/tests/test-awful-screen.lua ==
== Running …/src/awesome/tests/test-awful-tag.lua ==
== Running …/src/awesome/tests/test-awful-widget-button.lua ==
Error: running function for step 3/9 (@1): …/src/awesome/tests/test-awful-widget-button.lua:92: assertion failed!
stack traceback:
        [C]: in function 'assert'
        …/src/awesome/tests/test-awful-widget-button.lua:92: in function <…/src/awesome/tests/test-awful-widget-button.lua:91>
        (...tail calls...)
        [C]: in function 'xpcall'
        …/src/awesome/tests/_runner.lua:73: in function <…/src/awesome/tests/_runner.lua:64>
        [C]: in function 'xpcall'
        lib/gears/protected_call.lua:36: in function <lib/gears/protected_call.lua:35>
        (...tail calls...)
        lib/gears/timer.lua:237: in function 'gears.timer.run_delayed_calls_now'!
===> ERROR running …/src/awesome/tests/test-awful-widget-button.lua <===
Error: running function for step 3/9 (@1): …/src/awesome/tests/test-awful-widget-button.lua:92: assertion failed!
== Running …/src/awesome/tests/test-awful-widget-calendar_popup.lua ==
== Running …/src/awesome/tests/test-awful-widget-only_on_screen.lua ==
== Running …/src/awesome/tests/test-awful-widget-watch.lua ==
== Running …/src/awesome/tests/test-benchmark.lua ==
Doing quick and inexact measurements. Set BENCHMARK_EXACT=1 as an environment variable when you actually want to look at the results.
   create&draw wibox: 0.167561   sec/iter (  1 iters, 0.1676 sec for benchmark)
    update textclock: 6.6e-05    sec/iter (  1 iters, 0.000107 sec for benchmark)
  relayout textclock: 3.9e-05    sec/iter (  1 iters, 8e-05 sec for benchmark)
    redraw textclock: 3e-05      sec/iter (  1 iters, 7.1e-05 sec for benchmark)
          tag switch: 0.038627   sec/iter (  1 iters, 0.03867 sec for benchmark)
== Running …/src/awesome/tests/test-client-shape.lua ==
== Running …/src/awesome/tests/test-client-swap.lua ==
== Running …/src/awesome/tests/test-current-desktop.lua ==
== Running …/src/awesome/tests/test-dbus-error.lua ==
== Running …/src/awesome/tests/test-drawable-bgimage.lua ==
== Running …/src/awesome/tests/test-focus.lua ==
== Running …/src/awesome/tests/test-geometry.lua ==
== Running …/src/awesome/tests/test-gravity.lua ==
== Running …/src/awesome/tests/test-keyboard-layout-changes.lua ==
== Running …/src/awesome/tests/test-leak-client.lua ==
== Running …/src/awesome/tests/test-leaks.lua ==
== Running …/src/awesome/tests/test-maximize.lua ==
testing gravity NORTH_WEST
testing gravity NORTH
testing gravity NORTH_EAST
testing gravity WEST
testing gravity CENTER
testing gravity EAST
testing gravity SOUTH_WEST
testing gravity SOUTH
testing gravity SOUTH_EAST
testing gravity STATIC
== Running …/src/awesome/tests/test-menubar.lua ==
Skipping this test since it would just fail.
== Running …/src/awesome/tests/test-miss-handlers.lua ==
== Running …/src/awesome/tests/test-naughty-legacy.lua ==
   uint32 38
   uint32 39
== Running …/src/awesome/tests/test-resize.lua ==
Error: running function for step 12/43 (@1): …/src/awesome/tests/test-resize.lua:241: assertion failed!
stack traceback:
        [C]: in function 'assert'
        …/src/awesome/tests/test-resize.lua:241: in function <…/src/awesome/tests/test-resize.lua:239>
        (...tail calls...)
        [C]: in function 'xpcall'
        …/src/awesome/tests/_runner.lua:73: in function <…/src/awesome/tests/_runner.lua:64>
        [C]: in function 'xpcall'
        lib/gears/protected_call.lua:36: in function <lib/gears/protected_call.lua:35>
        (...tail calls...)
        lib/gears/timer.lua:237: in function 'gears.timer.run_delayed_calls_now'!
NOTE: there were 1 clients left after the test.
===> ERROR running …/src/awesome/tests/test-resize.lua <===
Error: running function for step 12/43 (@1): …/src/awesome/tests/test-resize.lua:241: assertion failed!
== Running …/src/awesome/tests/test-screen-changes.lua ==
== Running …/src/awesome/tests/test-selection-getter.lua ==
== Running …/src/awesome/tests/test-selection-watcher.lua ==
== Running …/src/awesome/tests/test-signal.lua ==
== Running …/src/awesome/tests/test-spawn-fast.lua ==
== Running …/src/awesome/tests/test-spawn.lua ==
== Running …/src/awesome/tests/test-spawn-snid.lua ==
== Running …/src/awesome/tests/test-struts.lua ==
== Running …/src/awesome/tests/test-tag-gap-single-client.lua ==
== Running …/src/awesome/tests/test-titlebar.lua ==
== Running …/src/awesome/tests/test-tooltip.lua ==
== Running …/src/awesome/tests/test-urgent.lua ==
Error: timeout waiting for signal in step 2/5 (@5).
Awesome was killed due to timeout after 30 seconds
===> ERROR running …/src/awesome/tests/test-urgent.lua <===
Error: timeout waiting for signal in step 2/5 (@5).
== Running …/src/awesome/tests/test-use-after-gc.lua ==
== Running …/src/awesome/tests/test-wallpaper.lua ==
== Running …/src/awesome/tests/test-wibox-shape.lua ==
43 tests finished.
There were 3 errors:
 - …/src/awesome/tests/test-awful-widget-button.lua: Error: running function for step 3/9 (@1): …/src/awesome/tests/test-awful-widget-button.lua:92: assertion failed!
 - …/src/awesome/tests/test-resize.lua: Error: running function for step 12/43 (@1): …/src/awesome/tests/test-resize.lua:241: assertion failed!
 - …/src/awesome/tests/test-urgent.lua: Error: timeout waiting for signal in step 2/5 (@5).
make[4]: *** [CMakeFiles/check-integration.dir/build.make:58: CMakeFiles/check-integration] Error 1
make[3]: *** [CMakeFiles/Makefile2:205: CMakeFiles/check-integration.dir/all] Error 2
make[2]: *** [CMakeFiles/Makefile2:212: CMakeFiles/check-integration.dir/rule] Error 2
make[1]: *** [Makefile:216: check-integration] Error 2
make: *** [Makefile:45: check-integration] Error 2
  64.43s user 5.62s system 59% cpu 1:57.59 total
Elv13 commented 5 years ago

note: When executing tests in Xephyr, the "real" mouse needs to be away from the Xephyr window or it will never, ever, work. This is totally normal and to be expected.

That being said, it also fails for me regardless of where is the mouse. But not with the same asserts.

blueyed commented 5 years ago

@Elv13 Does it works normally for you, i.e. when running the command, and leaving it alone - or always?

Elv13 commented 5 years ago

Things like the leak checks never passed since the day they were added. test-awful-client timeout in step 11. All the suits using the test client stopped working a while back with a system upgrade. However that's unrelated to your issue. I never investigated.

(lua:4231): Lgi-WARNING **: 19:12:39.086: Error raised while calling 'lgi.cbk (function: 0x55e9f22a8b30): Gio': /tmp/foo.lua:85: /usr/share/lua/5.1/lgi/override/GObject-Object.lua:100: bad argument #8 to 'object_new' (string expected, got userdata)

from

{while true; do echo class;echo title;echo ; sleep 5 ;done} | lua /tmp/foo.lua

^^ zsh-ism

where foo.lua is the part between [[]] of _client.lua. Nothing shows up.

Before that, as long as the mouse cursor wasn't on top of Xephyr, it ran.

actionless commented 5 years ago

what about using xvfb[-run]?