Mock Version: 5.0 Mock Version: 5.0 Mock Version: 5.0 ENTER ['do_with_status'](['bash', '--login', '-c', '/usr/bin/rpmbuild -bs --noclean --target noarch --nodeps /builddir/build/SPECS/input-remapper.spec'], chrootPath='/var/lib/mock/f40-build-2399055-60549/root'env={'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'}shell=Falselogger=timeout=864000uid=996gid=135user='mockbuild'nspawn_args=[]unshare_net=TrueprintOutput=False) Executing command: ['bash', '--login', '-c', '/usr/bin/rpmbuild -bs --noclean --target noarch --nodeps /builddir/build/SPECS/input-remapper.spec'] with env {'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'} and shell False Building target platforms: noarch Building for target noarch setting SOURCE_DATE_EPOCH=1707782400 Wrote: /builddir/build/SRPMS/input-remapper-2.0.1-1.fc40.src.rpm Child return code was: 0 ENTER ['do_with_status'](['bash', '--login', '-c', '/usr/bin/rpmbuild -br --noclean --target noarch --nodeps /builddir/build/SPECS/input-remapper.spec'], chrootPath='/var/lib/mock/f40-build-2399055-60549/root'env={'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'}shell=Falselogger=timeout=864000uid=996gid=135user='mockbuild'nspawn_args=[]unshare_net=TrueraiseExc=FalseprintOutput=False) Executing command: ['bash', '--login', '-c', '/usr/bin/rpmbuild -br --noclean --target noarch --nodeps /builddir/build/SPECS/input-remapper.spec'] with env {'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'} and shell False Building target platforms: noarch Building for target noarch setting SOURCE_DATE_EPOCH=1707782400 Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.oqZnlM + umask 022 + cd /builddir/build/BUILD + cd /builddir/build/BUILD + rm -rf input-remapper-2.0.1 + /usr/lib/rpm/rpmuncompress -x /builddir/build/SOURCES/input-remapper-2.0.1.tar.gz + STATUS=0 + '[' 0 -ne 0 ']' + cd input-remapper-2.0.1 + rm -rf /builddir/build/BUILD/input-remapper-2.0.1-SPECPARTS + /usr/bin/mkdir -p /builddir/build/BUILD/input-remapper-2.0.1-SPECPARTS + /usr/bin/chmod -Rf a+rX,u+w,g-w,o-w . + cp /builddir/build/SOURCES/README.Fedora ./ + RPM_EC=0 ++ jobs -p + exit 0 Executing(%generate_buildrequires): /bin/sh -e /var/tmp/rpm-tmp.pf2IA2 + umask 022 + cd /builddir/build/BUILD + cd input-remapper-2.0.1 + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CFLAGS + CXXFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CXXFLAGS + FFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FFLAGS + FCFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FCFLAGS + VALAFLAGS=-g + export VALAFLAGS + RUSTFLAGS='-Copt-level=3 -Cdebuginfo=2 -Ccodegen-units=1 -Cstrip=none -Cforce-frame-pointers=yes -Clink-arg=-Wl,-z,relro -Clink-arg=-Wl,-z,now --cap-lints=warn' + export RUSTFLAGS + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + export LDFLAGS + LT_SYS_LIBRARY_PATH=/usr/lib: + export LT_SYS_LIBRARY_PATH + CC=gcc + export CC + CXX=g++ + export CXX + echo pyproject-rpm-macros + echo python3-devel + echo 'python3dist(pip) >= 19' + echo 'python3dist(packaging)' + '[' -f pyproject.toml ']' + '[' -f setup.py ']' + echo 'python3dist(setuptools) >= 40.8' + echo 'python3dist(wheel)' + rm -rfv '*.dist-info/' + '[' -f /usr/bin/python3 ']' + mkdir -p /builddir/build/BUILD/.pyproject-builddir + echo -n + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + TMPDIR=/builddir/build/BUILD/.pyproject-builddir + RPM_TOXENV=py312 + HOSTNAME=rpmbuild + /usr/bin/python3 -Bs /usr/lib/rpm/redhat/pyproject_buildrequires.py --generate-extras --python3_pkgversion 3 --wheeldir /builddir/build/BUILD/pyproject-wheeldir --output /builddir/build/BUILD/input-remapper-2.0.1-1.fc40.noarch-pyproject-buildrequires -r Handling setuptools >= 40.8 from default build backend Requirement satisfied: setuptools >= 40.8 (installed: setuptools 68.2.2) Handling wheel from default build backend Requirement satisfied: wheel (installed: wheel 0.41.2) running egg_info creating input_remapper.egg-info writing input_remapper.egg-info/PKG-INFO writing dependency_links to input_remapper.egg-info/dependency_links.txt writing requirements to input_remapper.egg-info/requires.txt writing top-level names to input_remapper.egg-info/top_level.txt writing manifest file 'input_remapper.egg-info/SOURCES.txt' reading manifest file 'input_remapper.egg-info/SOURCES.txt' adding license file 'LICENSE' writing manifest file 'input_remapper.egg-info/SOURCES.txt' Handling wheel from get_requires_for_build_wheel Requirement satisfied: wheel (installed: wheel 0.41.2) running dist_info writing input_remapper.egg-info/PKG-INFO writing dependency_links to input_remapper.egg-info/dependency_links.txt writing requirements to input_remapper.egg-info/requires.txt writing top-level names to input_remapper.egg-info/top_level.txt reading manifest file 'input_remapper.egg-info/SOURCES.txt' adding license file 'LICENSE' writing manifest file 'input_remapper.egg-info/SOURCES.txt' creating '/builddir/build/BUILD/input-remapper-2.0.1/input_remapper-2.0.1.dist-info' Handling setuptools from hook generated metadata: Requires-Dist (input-remapper) Requirement satisfied: setuptools (installed: setuptools 68.2.2) Handling evdev from hook generated metadata: Requires-Dist (input-remapper) Requirement not satisfied: evdev Handling pydbus from hook generated metadata: Requires-Dist (input-remapper) Requirement not satisfied: pydbus Handling pygobject from hook generated metadata: Requires-Dist (input-remapper) Requirement not satisfied: pygobject Handling pydantic from hook generated metadata: Requires-Dist (input-remapper) Requirement not satisfied: pydantic + cat /builddir/build/BUILD/input-remapper-2.0.1-1.fc40.noarch-pyproject-buildrequires + rm -rfv input_remapper-2.0.1.dist-info/ removed 'input_remapper-2.0.1.dist-info/LICENSE' removed 'input_remapper-2.0.1.dist-info/top_level.txt' removed 'input_remapper-2.0.1.dist-info/METADATA' removed directory 'input_remapper-2.0.1.dist-info/' + RPM_EC=0 ++ jobs -p + exit 0 Wrote: /builddir/build/SRPMS/input-remapper-2.0.1-1.fc40.buildreqs.nosrc.rpm Child return code was: 11 Dynamic buildrequires detected Going to install missing buildrequires. See root.log for details. ENTER ['do_with_status'](['bash', '--login', '-c', '/usr/bin/rpmbuild -br --noclean --target noarch --nodeps /builddir/build/SPECS/input-remapper.spec'], chrootPath='/var/lib/mock/f40-build-2399055-60549/root'env={'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'}shell=Falselogger=timeout=864000uid=996gid=135user='mockbuild'nspawn_args=[]unshare_net=TrueraiseExc=FalseprintOutput=False) Executing command: ['bash', '--login', '-c', '/usr/bin/rpmbuild -br --noclean --target noarch --nodeps /builddir/build/SPECS/input-remapper.spec'] with env {'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'} and shell False Building target platforms: noarch Building for target noarch setting SOURCE_DATE_EPOCH=1707782400 Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.xVMhHS + umask 022 + cd /builddir/build/BUILD + cd /builddir/build/BUILD + rm -rf input-remapper-2.0.1 + /usr/lib/rpm/rpmuncompress -x /builddir/build/SOURCES/input-remapper-2.0.1.tar.gz + STATUS=0 + '[' 0 -ne 0 ']' + cd input-remapper-2.0.1 + rm -rf /builddir/build/BUILD/input-remapper-2.0.1-SPECPARTS + /usr/bin/mkdir -p /builddir/build/BUILD/input-remapper-2.0.1-SPECPARTS + /usr/bin/chmod -Rf a+rX,u+w,g-w,o-w . + cp /builddir/build/SOURCES/README.Fedora ./ + RPM_EC=0 ++ jobs -p + exit 0 Executing(%generate_buildrequires): /bin/sh -e /var/tmp/rpm-tmp.TC8QfC + umask 022 + cd /builddir/build/BUILD + cd input-remapper-2.0.1 + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CFLAGS + CXXFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CXXFLAGS + FFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FFLAGS + FCFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FCFLAGS + VALAFLAGS=-g + export VALAFLAGS + RUSTFLAGS='-Copt-level=3 -Cdebuginfo=2 -Ccodegen-units=1 -Cstrip=none -Cforce-frame-pointers=yes -Clink-arg=-Wl,-z,relro -Clink-arg=-Wl,-z,now --cap-lints=warn' + export RUSTFLAGS + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + export LDFLAGS + LT_SYS_LIBRARY_PATH=/usr/lib: + export LT_SYS_LIBRARY_PATH + CC=gcc + export CC + CXX=g++ + export CXX + echo pyproject-rpm-macros + echo python3-devel + echo 'python3dist(pip) >= 19' + echo 'python3dist(packaging)' + '[' -f pyproject.toml ']' + '[' -f setup.py ']' + echo 'python3dist(setuptools) >= 40.8' + echo 'python3dist(wheel)' + rm -rfv '*.dist-info/' + '[' -f /usr/bin/python3 ']' + mkdir -p /builddir/build/BUILD/.pyproject-builddir + echo -n + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + TMPDIR=/builddir/build/BUILD/.pyproject-builddir + RPM_TOXENV=py312 + HOSTNAME=rpmbuild + /usr/bin/python3 -Bs /usr/lib/rpm/redhat/pyproject_buildrequires.py --generate-extras --python3_pkgversion 3 --wheeldir /builddir/build/BUILD/pyproject-wheeldir --output /builddir/build/BUILD/input-remapper-2.0.1-1.fc40.noarch-pyproject-buildrequires -r Handling setuptools >= 40.8 from default build backend Requirement satisfied: setuptools >= 40.8 (installed: setuptools 68.2.2) Handling wheel from default build backend Requirement satisfied: wheel (installed: wheel 0.41.2) running egg_info creating input_remapper.egg-info writing input_remapper.egg-info/PKG-INFO writing dependency_links to input_remapper.egg-info/dependency_links.txt writing requirements to input_remapper.egg-info/requires.txt writing top-level names to input_remapper.egg-info/top_level.txt writing manifest file 'input_remapper.egg-info/SOURCES.txt' reading manifest file 'input_remapper.egg-info/SOURCES.txt' adding license file 'LICENSE' writing manifest file 'input_remapper.egg-info/SOURCES.txt' Handling wheel from get_requires_for_build_wheel Requirement satisfied: wheel (installed: wheel 0.41.2) running dist_info writing input_remapper.egg-info/PKG-INFO writing dependency_links to input_remapper.egg-info/dependency_links.txt writing requirements to input_remapper.egg-info/requires.txt writing top-level names to input_remapper.egg-info/top_level.txt reading manifest file 'input_remapper.egg-info/SOURCES.txt' adding license file 'LICENSE' writing manifest file 'input_remapper.egg-info/SOURCES.txt' creating '/builddir/build/BUILD/input-remapper-2.0.1/input_remapper-2.0.1.dist-info' Handling setuptools from hook generated metadata: Requires-Dist (input-remapper) Requirement satisfied: setuptools (installed: setuptools 68.2.2) Handling evdev from hook generated metadata: Requires-Dist (input-remapper) Requirement satisfied: evdev (installed: evdev 1.6.1) Handling pydbus from hook generated metadata: Requires-Dist (input-remapper) Requirement satisfied: pydbus (installed: pydbus 0.6.0) Handling pygobject from hook generated metadata: Requires-Dist (input-remapper) Requirement satisfied: pygobject (installed: pygobject 3.46.0) Handling pydantic from hook generated metadata: Requires-Dist (input-remapper) Requirement satisfied: pydantic (installed: pydantic 1.10.2) + cat /builddir/build/BUILD/input-remapper-2.0.1-1.fc40.noarch-pyproject-buildrequires + rm -rfv input_remapper-2.0.1.dist-info/ removed 'input_remapper-2.0.1.dist-info/LICENSE' removed 'input_remapper-2.0.1.dist-info/top_level.txt' removed 'input_remapper-2.0.1.dist-info/METADATA' removed directory 'input_remapper-2.0.1.dist-info/' + RPM_EC=0 ++ jobs -p + exit 0 Wrote: /builddir/build/SRPMS/input-remapper-2.0.1-1.fc40.buildreqs.nosrc.rpm Child return code was: 11 Dynamic buildrequires detected Going to install missing buildrequires. See root.log for details. ENTER ['do_with_status'](['bash', '--login', '-c', '/usr/bin/rpmbuild -ba --noprep --noclean --target noarch --nodeps /builddir/build/SPECS/input-remapper.spec'], chrootPath='/var/lib/mock/f40-build-2399055-60549/root'env={'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'}shell=Falselogger=timeout=864000uid=996gid=135user='mockbuild'nspawn_args=[]unshare_net=TrueprintOutput=False) Executing command: ['bash', '--login', '-c', '/usr/bin/rpmbuild -ba --noprep --noclean --target noarch --nodeps /builddir/build/SPECS/input-remapper.spec'] with env {'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'} and shell False Building target platforms: noarch Building for target noarch setting SOURCE_DATE_EPOCH=1707782400 Executing(%generate_buildrequires): /bin/sh -e /var/tmp/rpm-tmp.qEg1OA + umask 022 + cd /builddir/build/BUILD + cd input-remapper-2.0.1 + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CFLAGS + CXXFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CXXFLAGS + FFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FFLAGS + FCFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FCFLAGS + VALAFLAGS=-g + export VALAFLAGS + RUSTFLAGS='-Copt-level=3 -Cdebuginfo=2 -Ccodegen-units=1 -Cstrip=none -Cforce-frame-pointers=yes -Clink-arg=-Wl,-z,relro -Clink-arg=-Wl,-z,now --cap-lints=warn' + export RUSTFLAGS + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + export LDFLAGS + LT_SYS_LIBRARY_PATH=/usr/lib: + export LT_SYS_LIBRARY_PATH + CC=gcc + export CC + CXX=g++ + export CXX + echo pyproject-rpm-macros + echo python3-devel + echo 'python3dist(pip) >= 19' + echo 'python3dist(packaging)' + '[' -f pyproject.toml ']' + '[' -f setup.py ']' + echo 'python3dist(setuptools) >= 40.8' + echo 'python3dist(wheel)' + rm -rfv '*.dist-info/' + '[' -f /usr/bin/python3 ']' + mkdir -p /builddir/build/BUILD/.pyproject-builddir + echo -n + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + TMPDIR=/builddir/build/BUILD/.pyproject-builddir + RPM_TOXENV=py312 + HOSTNAME=rpmbuild + /usr/bin/python3 -Bs /usr/lib/rpm/redhat/pyproject_buildrequires.py --generate-extras --python3_pkgversion 3 --wheeldir /builddir/build/BUILD/pyproject-wheeldir --output /builddir/build/BUILD/input-remapper-2.0.1-1.fc40.noarch-pyproject-buildrequires -r Handling setuptools >= 40.8 from default build backend Requirement satisfied: setuptools >= 40.8 (installed: setuptools 68.2.2) Handling wheel from default build backend Requirement satisfied: wheel (installed: wheel 0.41.2) running egg_info writing input_remapper.egg-info/PKG-INFO writing dependency_links to input_remapper.egg-info/dependency_links.txt writing requirements to input_remapper.egg-info/requires.txt writing top-level names to input_remapper.egg-info/top_level.txt reading manifest file 'input_remapper.egg-info/SOURCES.txt' adding license file 'LICENSE' writing manifest file 'input_remapper.egg-info/SOURCES.txt' Handling wheel from get_requires_for_build_wheel Requirement satisfied: wheel (installed: wheel 0.41.2) running dist_info writing input_remapper.egg-info/PKG-INFO writing dependency_links to input_remapper.egg-info/dependency_links.txt writing requirements to input_remapper.egg-info/requires.txt writing top-level names to input_remapper.egg-info/top_level.txt reading manifest file 'input_remapper.egg-info/SOURCES.txt' adding license file 'LICENSE' writing manifest file 'input_remapper.egg-info/SOURCES.txt' creating '/builddir/build/BUILD/input-remapper-2.0.1/input_remapper-2.0.1.dist-info' Handling setuptools from hook generated metadata: Requires-Dist (input-remapper) Requirement satisfied: setuptools (installed: setuptools 68.2.2) Handling evdev from hook generated metadata: Requires-Dist (input-remapper) Requirement satisfied: evdev (installed: evdev 1.6.1) Handling pydbus from hook generated metadata: Requires-Dist (input-remapper) Requirement satisfied: pydbus (installed: pydbus 0.6.0) Handling pygobject from hook generated metadata: Requires-Dist (input-remapper) Requirement satisfied: pygobject (installed: pygobject 3.46.0) Handling pydantic from hook generated metadata: Requires-Dist (input-remapper) Requirement satisfied: pydantic (installed: pydantic 1.10.2) + cat /builddir/build/BUILD/input-remapper-2.0.1-1.fc40.noarch-pyproject-buildrequires + rm -rfv input_remapper-2.0.1.dist-info/ removed 'input_remapper-2.0.1.dist-info/LICENSE' removed 'input_remapper-2.0.1.dist-info/top_level.txt' removed 'input_remapper-2.0.1.dist-info/METADATA' removed directory 'input_remapper-2.0.1.dist-info/' + RPM_EC=0 ++ jobs -p + exit 0 Executing(%build): /bin/sh -e /var/tmp/rpm-tmp.ZwsAko + umask 022 + cd /builddir/build/BUILD + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CFLAGS + CXXFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CXXFLAGS + FFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FFLAGS + FCFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FCFLAGS + VALAFLAGS=-g + export VALAFLAGS + RUSTFLAGS='-Copt-level=3 -Cdebuginfo=2 -Ccodegen-units=1 -Cstrip=none -Cforce-frame-pointers=yes -Clink-arg=-Wl,-z,relro -Clink-arg=-Wl,-z,now --cap-lints=warn' + export RUSTFLAGS + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + export LDFLAGS + LT_SYS_LIBRARY_PATH=/usr/lib: + export LT_SYS_LIBRARY_PATH + CC=gcc + export CC + CXX=g++ + export CXX + cd input-remapper-2.0.1 + mkdir -p /builddir/build/BUILD/input-remapper-2.0.1/.pyproject-builddir + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + TMPDIR=/builddir/build/BUILD/input-remapper-2.0.1/.pyproject-builddir + /usr/bin/python3 -Bs /usr/lib/rpm/redhat/pyproject_wheel.py /builddir/build/BUILD/input-remapper-2.0.1/pyproject-wheeldir Processing /builddir/build/BUILD/input-remapper-2.0.1 Preparing metadata (pyproject.toml): started Running command Preparing metadata (pyproject.toml) running dist_info creating /builddir/build/BUILD/input-remapper-2.0.1/.pyproject-builddir/pip-modern-metadata-5bnsks3v/input_remapper.egg-info writing /builddir/build/BUILD/input-remapper-2.0.1/.pyproject-builddir/pip-modern-metadata-5bnsks3v/input_remapper.egg-info/PKG-INFO writing dependency_links to /builddir/build/BUILD/input-remapper-2.0.1/.pyproject-builddir/pip-modern-metadata-5bnsks3v/input_remapper.egg-info/dependency_links.txt writing requirements to /builddir/build/BUILD/input-remapper-2.0.1/.pyproject-builddir/pip-modern-metadata-5bnsks3v/input_remapper.egg-info/requires.txt writing top-level names to /builddir/build/BUILD/input-remapper-2.0.1/.pyproject-builddir/pip-modern-metadata-5bnsks3v/input_remapper.egg-info/top_level.txt writing manifest file '/builddir/build/BUILD/input-remapper-2.0.1/.pyproject-builddir/pip-modern-metadata-5bnsks3v/input_remapper.egg-info/SOURCES.txt' reading manifest file '/builddir/build/BUILD/input-remapper-2.0.1/.pyproject-builddir/pip-modern-metadata-5bnsks3v/input_remapper.egg-info/SOURCES.txt' adding license file 'LICENSE' writing manifest file '/builddir/build/BUILD/input-remapper-2.0.1/.pyproject-builddir/pip-modern-metadata-5bnsks3v/input_remapper.egg-info/SOURCES.txt' creating '/builddir/build/BUILD/input-remapper-2.0.1/.pyproject-builddir/pip-modern-metadata-5bnsks3v/input_remapper-2.0.1.dist-info' Preparing metadata (pyproject.toml): finished with status 'done' Building wheels for collected packages: input-remapper Building wheel for input-remapper (pyproject.toml): started Running command Building wheel for input-remapper (pyproject.toml) running bdist_wheel running build running build_py creating build creating build/lib creating build/lib/inputremapper copying inputremapper/daemon.py -> build/lib/inputremapper copying inputremapper/groups.py -> build/lib/inputremapper copying inputremapper/input_event.py -> build/lib/inputremapper copying inputremapper/exceptions.py -> build/lib/inputremapper copying inputremapper/logger.py -> build/lib/inputremapper copying inputremapper/__init__.py -> build/lib/inputremapper copying inputremapper/user.py -> build/lib/inputremapper copying inputremapper/utils.py -> build/lib/inputremapper creating build/lib/inputremapper/configs copying inputremapper/configs/global_config.py -> build/lib/inputremapper/configs copying inputremapper/configs/base_config.py -> build/lib/inputremapper/configs copying inputremapper/configs/paths.py -> build/lib/inputremapper/configs copying inputremapper/configs/mapping.py -> build/lib/inputremapper/configs copying inputremapper/configs/data.py -> build/lib/inputremapper/configs copying inputremapper/configs/validation_errors.py -> build/lib/inputremapper/configs copying inputremapper/configs/migrations.py -> build/lib/inputremapper/configs copying inputremapper/configs/system_mapping.py -> build/lib/inputremapper/configs copying inputremapper/configs/__init__.py -> build/lib/inputremapper/configs copying inputremapper/configs/input_config.py -> build/lib/inputremapper/configs copying inputremapper/configs/preset.py -> build/lib/inputremapper/configs creating build/lib/inputremapper/injection copying inputremapper/injection/context.py -> build/lib/inputremapper/injection copying inputremapper/injection/injector.py -> build/lib/inputremapper/injection copying inputremapper/injection/global_uinputs.py -> build/lib/inputremapper/injection copying inputremapper/injection/numlock.py -> build/lib/inputremapper/injection copying inputremapper/injection/__init__.py -> build/lib/inputremapper/injection copying inputremapper/injection/event_reader.py -> build/lib/inputremapper/injection creating build/lib/inputremapper/injection/macros copying inputremapper/injection/macros/macro.py -> build/lib/inputremapper/injection/macros copying inputremapper/injection/macros/__init__.py -> build/lib/inputremapper/injection/macros copying inputremapper/injection/macros/parse.py -> build/lib/inputremapper/injection/macros creating build/lib/inputremapper/injection/mapping_handlers copying inputremapper/injection/mapping_handlers/axis_switch_handler.py -> build/lib/inputremapper/injection/mapping_handlers copying inputremapper/injection/mapping_handlers/hierarchy_handler.py -> build/lib/inputremapper/injection/mapping_handlers copying inputremapper/injection/mapping_handlers/abs_to_btn_handler.py -> build/lib/inputremapper/injection/mapping_handlers copying inputremapper/injection/mapping_handlers/abs_to_abs_handler.py -> build/lib/inputremapper/injection/mapping_handlers copying inputremapper/injection/mapping_handlers/axis_transform.py -> build/lib/inputremapper/injection/mapping_handlers copying inputremapper/injection/mapping_handlers/abs_to_rel_handler.py -> build/lib/inputremapper/injection/mapping_handlers copying inputremapper/injection/mapping_handlers/rel_to_abs_handler.py -> build/lib/inputremapper/injection/mapping_handlers copying inputremapper/injection/mapping_handlers/null_handler.py -> build/lib/inputremapper/injection/mapping_handlers copying inputremapper/injection/mapping_handlers/rel_to_rel_handler.py -> build/lib/inputremapper/injection/mapping_handlers copying inputremapper/injection/mapping_handlers/mapping_handler.py -> build/lib/inputremapper/injection/mapping_handlers copying inputremapper/injection/mapping_handlers/combination_handler.py -> build/lib/inputremapper/injection/mapping_handlers copying inputremapper/injection/mapping_handlers/__init__.py -> build/lib/inputremapper/injection/mapping_handlers copying inputremapper/injection/mapping_handlers/mapping_parser.py -> build/lib/inputremapper/injection/mapping_handlers copying inputremapper/injection/mapping_handlers/macro_handler.py -> build/lib/inputremapper/injection/mapping_handlers copying inputremapper/injection/mapping_handlers/key_handler.py -> build/lib/inputremapper/injection/mapping_handlers copying inputremapper/injection/mapping_handlers/rel_to_btn_handler.py -> build/lib/inputremapper/injection/mapping_handlers creating build/lib/inputremapper/gui copying inputremapper/gui/gettext.py -> build/lib/inputremapper/gui copying inputremapper/gui/controller.py -> build/lib/inputremapper/gui copying inputremapper/gui/data_manager.py -> build/lib/inputremapper/gui copying inputremapper/gui/autocompletion.py -> build/lib/inputremapper/gui copying inputremapper/gui/__init__.py -> build/lib/inputremapper/gui copying inputremapper/gui/reader_client.py -> build/lib/inputremapper/gui copying inputremapper/gui/user_interface.py -> build/lib/inputremapper/gui copying inputremapper/gui/utils.py -> build/lib/inputremapper/gui copying inputremapper/gui/reader_service.py -> build/lib/inputremapper/gui creating build/lib/inputremapper/gui/components copying inputremapper/gui/components/common.py -> build/lib/inputremapper/gui/components copying inputremapper/gui/components/main.py -> build/lib/inputremapper/gui/components copying inputremapper/gui/components/device_groups.py -> build/lib/inputremapper/gui/components copying inputremapper/gui/components/editor.py -> build/lib/inputremapper/gui/components copying inputremapper/gui/components/presets.py -> build/lib/inputremapper/gui/components copying inputremapper/gui/components/__init__.py -> build/lib/inputremapper/gui/components creating build/lib/inputremapper/gui/messages copying inputremapper/gui/messages/message_data.py -> build/lib/inputremapper/gui/messages copying inputremapper/gui/messages/__init__.py -> build/lib/inputremapper/gui/messages copying inputremapper/gui/messages/message_types.py -> build/lib/inputremapper/gui/messages copying inputremapper/gui/messages/message_broker.py -> build/lib/inputremapper/gui/messages creating build/lib/inputremapper/ipc copying inputremapper/ipc/shared_dict.py -> build/lib/inputremapper/ipc copying inputremapper/ipc/pipe.py -> build/lib/inputremapper/ipc copying inputremapper/ipc/__init__.py -> build/lib/inputremapper/ipc copying inputremapper/ipc/socket.py -> build/lib/inputremapper/ipc running egg_info writing input_remapper.egg-info/PKG-INFO writing dependency_links to input_remapper.egg-info/dependency_links.txt writing requirements to input_remapper.egg-info/requires.txt writing top-level names to input_remapper.egg-info/top_level.txt reading manifest file 'input_remapper.egg-info/SOURCES.txt' adding license file 'LICENSE' writing manifest file 'input_remapper.egg-info/SOURCES.txt' installing to build/bdist.linux-riscv64/wheel running install /bin/sh: line 1: git: command not found generating translation for sk_SK generating translation for pt generating translation for fr generating translation for ru_RU generating translation for zh generating translation for it_IT generating translation for uk_UA generating translation for pt_BR generating translation for zh_CN generating translation for fr_FR generating translation for sk generating translation for ru generating translation for it generating translation for uk running install_lib creating build/bdist.linux-riscv64 creating build/bdist.linux-riscv64/wheel creating build/bdist.linux-riscv64/wheel/inputremapper copying build/lib/inputremapper/daemon.py -> build/bdist.linux-riscv64/wheel/inputremapper copying build/lib/inputremapper/groups.py -> build/bdist.linux-riscv64/wheel/inputremapper creating build/bdist.linux-riscv64/wheel/inputremapper/configs copying build/lib/inputremapper/configs/global_config.py -> build/bdist.linux-riscv64/wheel/inputremapper/configs copying build/lib/inputremapper/configs/base_config.py -> build/bdist.linux-riscv64/wheel/inputremapper/configs copying build/lib/inputremapper/configs/paths.py -> build/bdist.linux-riscv64/wheel/inputremapper/configs copying build/lib/inputremapper/configs/mapping.py -> build/bdist.linux-riscv64/wheel/inputremapper/configs copying build/lib/inputremapper/configs/data.py -> build/bdist.linux-riscv64/wheel/inputremapper/configs copying build/lib/inputremapper/configs/validation_errors.py -> build/bdist.linux-riscv64/wheel/inputremapper/configs copying build/lib/inputremapper/configs/migrations.py -> build/bdist.linux-riscv64/wheel/inputremapper/configs copying build/lib/inputremapper/configs/system_mapping.py -> build/bdist.linux-riscv64/wheel/inputremapper/configs copying build/lib/inputremapper/configs/__init__.py -> build/bdist.linux-riscv64/wheel/inputremapper/configs copying build/lib/inputremapper/configs/input_config.py -> build/bdist.linux-riscv64/wheel/inputremapper/configs copying build/lib/inputremapper/configs/preset.py -> build/bdist.linux-riscv64/wheel/inputremapper/configs creating build/bdist.linux-riscv64/wheel/inputremapper/injection creating build/bdist.linux-riscv64/wheel/inputremapper/injection/macros copying build/lib/inputremapper/injection/macros/macro.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection/macros copying build/lib/inputremapper/injection/macros/__init__.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection/macros copying build/lib/inputremapper/injection/macros/parse.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection/macros copying build/lib/inputremapper/injection/context.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection copying build/lib/inputremapper/injection/injector.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection copying build/lib/inputremapper/injection/global_uinputs.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection copying build/lib/inputremapper/injection/numlock.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection creating build/bdist.linux-riscv64/wheel/inputremapper/injection/mapping_handlers copying build/lib/inputremapper/injection/mapping_handlers/axis_switch_handler.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection/mapping_handlers copying build/lib/inputremapper/injection/mapping_handlers/hierarchy_handler.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection/mapping_handlers copying build/lib/inputremapper/injection/mapping_handlers/abs_to_btn_handler.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection/mapping_handlers copying build/lib/inputremapper/injection/mapping_handlers/abs_to_abs_handler.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection/mapping_handlers copying build/lib/inputremapper/injection/mapping_handlers/axis_transform.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection/mapping_handlers copying build/lib/inputremapper/injection/mapping_handlers/abs_to_rel_handler.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection/mapping_handlers copying build/lib/inputremapper/injection/mapping_handlers/rel_to_abs_handler.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection/mapping_handlers copying build/lib/inputremapper/injection/mapping_handlers/null_handler.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection/mapping_handlers copying build/lib/inputremapper/injection/mapping_handlers/rel_to_rel_handler.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection/mapping_handlers copying build/lib/inputremapper/injection/mapping_handlers/mapping_handler.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection/mapping_handlers copying build/lib/inputremapper/injection/mapping_handlers/combination_handler.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection/mapping_handlers copying build/lib/inputremapper/injection/mapping_handlers/__init__.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection/mapping_handlers copying build/lib/inputremapper/injection/mapping_handlers/mapping_parser.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection/mapping_handlers copying build/lib/inputremapper/injection/mapping_handlers/macro_handler.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection/mapping_handlers copying build/lib/inputremapper/injection/mapping_handlers/key_handler.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection/mapping_handlers copying build/lib/inputremapper/injection/mapping_handlers/rel_to_btn_handler.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection/mapping_handlers copying build/lib/inputremapper/injection/__init__.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection copying build/lib/inputremapper/injection/event_reader.py -> build/bdist.linux-riscv64/wheel/inputremapper/injection copying build/lib/inputremapper/input_event.py -> build/bdist.linux-riscv64/wheel/inputremapper copying build/lib/inputremapper/exceptions.py -> build/bdist.linux-riscv64/wheel/inputremapper copying build/lib/inputremapper/logger.py -> build/bdist.linux-riscv64/wheel/inputremapper creating build/bdist.linux-riscv64/wheel/inputremapper/gui copying build/lib/inputremapper/gui/gettext.py -> build/bdist.linux-riscv64/wheel/inputremapper/gui creating build/bdist.linux-riscv64/wheel/inputremapper/gui/components copying build/lib/inputremapper/gui/components/common.py -> build/bdist.linux-riscv64/wheel/inputremapper/gui/components copying build/lib/inputremapper/gui/components/main.py -> build/bdist.linux-riscv64/wheel/inputremapper/gui/components copying build/lib/inputremapper/gui/components/device_groups.py -> build/bdist.linux-riscv64/wheel/inputremapper/gui/components copying build/lib/inputremapper/gui/components/editor.py -> build/bdist.linux-riscv64/wheel/inputremapper/gui/components copying build/lib/inputremapper/gui/components/presets.py -> build/bdist.linux-riscv64/wheel/inputremapper/gui/components copying build/lib/inputremapper/gui/components/__init__.py -> build/bdist.linux-riscv64/wheel/inputremapper/gui/components copying build/lib/inputremapper/gui/controller.py -> build/bdist.linux-riscv64/wheel/inputremapper/gui copying build/lib/inputremapper/gui/data_manager.py -> build/bdist.linux-riscv64/wheel/inputremapper/gui copying build/lib/inputremapper/gui/autocompletion.py -> build/bdist.linux-riscv64/wheel/inputremapper/gui copying build/lib/inputremapper/gui/__init__.py -> build/bdist.linux-riscv64/wheel/inputremapper/gui copying build/lib/inputremapper/gui/reader_client.py -> build/bdist.linux-riscv64/wheel/inputremapper/gui copying build/lib/inputremapper/gui/user_interface.py -> build/bdist.linux-riscv64/wheel/inputremapper/gui copying build/lib/inputremapper/gui/utils.py -> build/bdist.linux-riscv64/wheel/inputremapper/gui copying build/lib/inputremapper/gui/reader_service.py -> build/bdist.linux-riscv64/wheel/inputremapper/gui creating build/bdist.linux-riscv64/wheel/inputremapper/gui/messages copying build/lib/inputremapper/gui/messages/message_data.py -> build/bdist.linux-riscv64/wheel/inputremapper/gui/messages copying build/lib/inputremapper/gui/messages/__init__.py -> build/bdist.linux-riscv64/wheel/inputremapper/gui/messages copying build/lib/inputremapper/gui/messages/message_types.py -> build/bdist.linux-riscv64/wheel/inputremapper/gui/messages copying build/lib/inputremapper/gui/messages/message_broker.py -> build/bdist.linux-riscv64/wheel/inputremapper/gui/messages creating build/bdist.linux-riscv64/wheel/inputremapper/ipc copying build/lib/inputremapper/ipc/shared_dict.py -> build/bdist.linux-riscv64/wheel/inputremapper/ipc copying build/lib/inputremapper/ipc/pipe.py -> build/bdist.linux-riscv64/wheel/inputremapper/ipc copying build/lib/inputremapper/ipc/__init__.py -> build/bdist.linux-riscv64/wheel/inputremapper/ipc copying build/lib/inputremapper/ipc/socket.py -> build/bdist.linux-riscv64/wheel/inputremapper/ipc copying build/lib/inputremapper/__init__.py -> build/bdist.linux-riscv64/wheel/inputremapper copying build/lib/inputremapper/user.py -> build/bdist.linux-riscv64/wheel/inputremapper copying build/lib/inputremapper/utils.py -> build/bdist.linux-riscv64/wheel/inputremapper running install_data creating build/bdist.linux-riscv64/wheel/input_remapper-2.0.1.data creating build/bdist.linux-riscv64/wheel/input_remapper-2.0.1.data/data creating build/bdist.linux-riscv64/wheel/usr creating build/bdist.linux-riscv64/wheel/usr/share creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/sk_SK creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/sk_SK/LC_MESSAGES copying mo/sk_SK/input-remapper.mo -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/sk_SK/LC_MESSAGES creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/pt creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/pt/LC_MESSAGES copying mo/pt/input-remapper.mo -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/pt/LC_MESSAGES creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/fr creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/fr/LC_MESSAGES copying mo/fr/input-remapper.mo -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/fr/LC_MESSAGES creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/ru_RU creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/ru_RU/LC_MESSAGES copying mo/ru_RU/input-remapper.mo -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/ru_RU/LC_MESSAGES creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/zh creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/zh/LC_MESSAGES copying mo/zh/input-remapper.mo -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/zh/LC_MESSAGES creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/it_IT creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/it_IT/LC_MESSAGES copying mo/it_IT/input-remapper.mo -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/it_IT/LC_MESSAGES creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/uk_UA creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/uk_UA/LC_MESSAGES copying mo/uk_UA/input-remapper.mo -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/uk_UA/LC_MESSAGES creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/pt_BR creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/pt_BR/LC_MESSAGES copying mo/pt_BR/input-remapper.mo -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/pt_BR/LC_MESSAGES creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/zh_CN creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/zh_CN/LC_MESSAGES copying mo/zh_CN/input-remapper.mo -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/zh_CN/LC_MESSAGES creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/fr_FR creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/fr_FR/LC_MESSAGES copying mo/fr_FR/input-remapper.mo -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/fr_FR/LC_MESSAGES creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/sk creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/sk/LC_MESSAGES copying mo/sk/input-remapper.mo -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/sk/LC_MESSAGES creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/ru creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/ru/LC_MESSAGES copying mo/ru/input-remapper.mo -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/ru/LC_MESSAGES creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/it creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/it/LC_MESSAGES copying mo/it/input-remapper.mo -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/it/LC_MESSAGES creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/uk creating build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/uk/LC_MESSAGES copying mo/uk/input-remapper.mo -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/lang/uk/LC_MESSAGES copying data/input-remapper.service -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/ copying data/inputremapper.Control.conf -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/ copying data/input-remapper-autoload.desktop -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/ copying data/style.css -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/ copying data/input-remapper-large.png -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/ copying data/99-input-remapper.rules -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/ copying data/input-remapper.glade -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/ copying data/input-remapper-gtk.desktop -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/ copying data/input-remapper.policy -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/ copying data/input-remapper.svg -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/ copying data/io.github.sezanzeb.input_remapper.metainfo.xml -> build/bdist.linux-riscv64/wheel/usr/share/input-remapper/ creating build/bdist.linux-riscv64/wheel/usr/share/applications copying data/input-remapper-gtk.desktop -> build/bdist.linux-riscv64/wheel/usr/share/applications/ creating build/bdist.linux-riscv64/wheel/usr/share/metainfo copying data/io.github.sezanzeb.input_remapper.metainfo.xml -> build/bdist.linux-riscv64/wheel/usr/share/metainfo/ creating build/bdist.linux-riscv64/wheel/usr/share/polkit-1 creating build/bdist.linux-riscv64/wheel/usr/share/polkit-1/actions copying data/input-remapper.policy -> build/bdist.linux-riscv64/wheel/usr/share/polkit-1/actions/ creating build/bdist.linux-riscv64/wheel/usr/lib creating build/bdist.linux-riscv64/wheel/usr/lib/systemd creating build/bdist.linux-riscv64/wheel/usr/lib/systemd/system copying data/input-remapper.service -> build/bdist.linux-riscv64/wheel/usr/lib/systemd/system creating build/bdist.linux-riscv64/wheel/etc creating build/bdist.linux-riscv64/wheel/etc/dbus-1 creating build/bdist.linux-riscv64/wheel/etc/dbus-1/system.d copying data/inputremapper.Control.conf -> build/bdist.linux-riscv64/wheel/etc/dbus-1/system.d/ creating build/bdist.linux-riscv64/wheel/etc/xdg creating build/bdist.linux-riscv64/wheel/etc/xdg/autostart copying data/input-remapper-autoload.desktop -> build/bdist.linux-riscv64/wheel/etc/xdg/autostart/ creating build/bdist.linux-riscv64/wheel/usr/lib/udev creating build/bdist.linux-riscv64/wheel/usr/lib/udev/rules.d copying data/99-input-remapper.rules -> build/bdist.linux-riscv64/wheel/usr/lib/udev/rules.d creating build/bdist.linux-riscv64/wheel/usr/bin copying bin/input-remapper-gtk -> build/bdist.linux-riscv64/wheel/usr/bin/ copying bin/input-remapper-service -> build/bdist.linux-riscv64/wheel/usr/bin/ copying bin/input-remapper-control -> build/bdist.linux-riscv64/wheel/usr/bin/ copying bin/input-remapper-reader-service -> build/bdist.linux-riscv64/wheel/usr/bin/ running install_egg_info Copying input_remapper.egg-info to build/bdist.linux-riscv64/wheel/input_remapper-2.0.1-py3.12.egg-info running install_scripts creating build/bdist.linux-riscv64/wheel/input_remapper-2.0.1.dist-info/WHEEL creating '/builddir/build/BUILD/input-remapper-2.0.1/.pyproject-builddir/pip-wheel-ckotnpgh/.tmp-0j76zz5e/input_remapper-2.0.1-py3-none-any.whl' and adding 'build/bdist.linux-riscv64/wheel' to it adding 'etc/dbus-1/system.d/inputremapper.Control.conf' adding 'etc/xdg/autostart/input-remapper-autoload.desktop' adding 'inputremapper/__init__.py' adding 'inputremapper/daemon.py' adding 'inputremapper/exceptions.py' adding 'inputremapper/groups.py' adding 'inputremapper/input_event.py' adding 'inputremapper/logger.py' adding 'inputremapper/user.py' adding 'inputremapper/utils.py' adding 'inputremapper/configs/__init__.py' adding 'inputremapper/configs/base_config.py' adding 'inputremapper/configs/data.py' adding 'inputremapper/configs/global_config.py' adding 'inputremapper/configs/input_config.py' adding 'inputremapper/configs/mapping.py' adding 'inputremapper/configs/migrations.py' adding 'inputremapper/configs/paths.py' adding 'inputremapper/configs/preset.py' adding 'inputremapper/configs/system_mapping.py' adding 'inputremapper/configs/validation_errors.py' adding 'inputremapper/gui/__init__.py' adding 'inputremapper/gui/autocompletion.py' adding 'inputremapper/gui/controller.py' adding 'inputremapper/gui/data_manager.py' adding 'inputremapper/gui/gettext.py' adding 'inputremapper/gui/reader_client.py' adding 'inputremapper/gui/reader_service.py' adding 'inputremapper/gui/user_interface.py' adding 'inputremapper/gui/utils.py' adding 'inputremapper/gui/components/__init__.py' adding 'inputremapper/gui/components/common.py' adding 'inputremapper/gui/components/device_groups.py' adding 'inputremapper/gui/components/editor.py' adding 'inputremapper/gui/components/main.py' adding 'inputremapper/gui/components/presets.py' adding 'inputremapper/gui/messages/__init__.py' adding 'inputremapper/gui/messages/message_broker.py' adding 'inputremapper/gui/messages/message_data.py' adding 'inputremapper/gui/messages/message_types.py' adding 'inputremapper/injection/__init__.py' adding 'inputremapper/injection/context.py' adding 'inputremapper/injection/event_reader.py' adding 'inputremapper/injection/global_uinputs.py' adding 'inputremapper/injection/injector.py' adding 'inputremapper/injection/numlock.py' adding 'inputremapper/injection/macros/__init__.py' adding 'inputremapper/injection/macros/macro.py' adding 'inputremapper/injection/macros/parse.py' adding 'inputremapper/injection/mapping_handlers/__init__.py' adding 'inputremapper/injection/mapping_handlers/abs_to_abs_handler.py' adding 'inputremapper/injection/mapping_handlers/abs_to_btn_handler.py' adding 'inputremapper/injection/mapping_handlers/abs_to_rel_handler.py' adding 'inputremapper/injection/mapping_handlers/axis_switch_handler.py' adding 'inputremapper/injection/mapping_handlers/axis_transform.py' adding 'inputremapper/injection/mapping_handlers/combination_handler.py' adding 'inputremapper/injection/mapping_handlers/hierarchy_handler.py' adding 'inputremapper/injection/mapping_handlers/key_handler.py' adding 'inputremapper/injection/mapping_handlers/macro_handler.py' adding 'inputremapper/injection/mapping_handlers/mapping_handler.py' adding 'inputremapper/injection/mapping_handlers/mapping_parser.py' adding 'inputremapper/injection/mapping_handlers/null_handler.py' adding 'inputremapper/injection/mapping_handlers/rel_to_abs_handler.py' adding 'inputremapper/injection/mapping_handlers/rel_to_btn_handler.py' adding 'inputremapper/injection/mapping_handlers/rel_to_rel_handler.py' adding 'inputremapper/ipc/__init__.py' adding 'inputremapper/ipc/pipe.py' adding 'inputremapper/ipc/shared_dict.py' adding 'inputremapper/ipc/socket.py' adding 'usr/bin/input-remapper-control' adding 'usr/bin/input-remapper-gtk' adding 'usr/bin/input-remapper-reader-service' adding 'usr/bin/input-remapper-service' adding 'usr/lib/systemd/system/input-remapper.service' adding 'usr/lib/udev/rules.d/99-input-remapper.rules' adding 'usr/share/applications/input-remapper-gtk.desktop' adding 'usr/share/input-remapper/99-input-remapper.rules' adding 'usr/share/input-remapper/input-remapper-autoload.desktop' adding 'usr/share/input-remapper/input-remapper-gtk.desktop' adding 'usr/share/input-remapper/input-remapper-large.png' adding 'usr/share/input-remapper/input-remapper.glade' adding 'usr/share/input-remapper/input-remapper.policy' adding 'usr/share/input-remapper/input-remapper.service' adding 'usr/share/input-remapper/input-remapper.svg' adding 'usr/share/input-remapper/inputremapper.Control.conf' adding 'usr/share/input-remapper/io.github.sezanzeb.input_remapper.metainfo.xml' adding 'usr/share/input-remapper/style.css' adding 'usr/share/input-remapper/lang/fr/LC_MESSAGES/input-remapper.mo' adding 'usr/share/input-remapper/lang/fr_FR/LC_MESSAGES/input-remapper.mo' adding 'usr/share/input-remapper/lang/it/LC_MESSAGES/input-remapper.mo' adding 'usr/share/input-remapper/lang/it_IT/LC_MESSAGES/input-remapper.mo' adding 'usr/share/input-remapper/lang/pt/LC_MESSAGES/input-remapper.mo' adding 'usr/share/input-remapper/lang/pt_BR/LC_MESSAGES/input-remapper.mo' adding 'usr/share/input-remapper/lang/ru/LC_MESSAGES/input-remapper.mo' adding 'usr/share/input-remapper/lang/ru_RU/LC_MESSAGES/input-remapper.mo' adding 'usr/share/input-remapper/lang/sk/LC_MESSAGES/input-remapper.mo' adding 'usr/share/input-remapper/lang/sk_SK/LC_MESSAGES/input-remapper.mo' adding 'usr/share/input-remapper/lang/uk/LC_MESSAGES/input-remapper.mo' adding 'usr/share/input-remapper/lang/uk_UA/LC_MESSAGES/input-remapper.mo' adding 'usr/share/input-remapper/lang/zh/LC_MESSAGES/input-remapper.mo' adding 'usr/share/input-remapper/lang/zh_CN/LC_MESSAGES/input-remapper.mo' adding 'usr/share/metainfo/io.github.sezanzeb.input_remapper.metainfo.xml' adding 'usr/share/polkit-1/actions/input-remapper.policy' adding 'input_remapper-2.0.1.dist-info/LICENSE' adding 'input_remapper-2.0.1.dist-info/METADATA' adding 'input_remapper-2.0.1.dist-info/WHEEL' adding 'input_remapper-2.0.1.dist-info/top_level.txt' adding 'input_remapper-2.0.1.dist-info/RECORD' removing build/bdist.linux-riscv64/wheel Building wheel for input-remapper (pyproject.toml): finished with status 'done' Created wheel for input-remapper: filename=input_remapper-2.0.1-py3-none-any.whl size=267748 sha256=8a20e2d5589d3a99532a278bc8bf91bb7168311fbcea90a700be158821f99d69 Stored in directory: /builddir/.cache/pip/wheels/d6/13/20/9b5089c57903b4511db424a46fd5f8b0badd4b9a79f9c3dcf2 Successfully built input-remapper + RPM_EC=0 ++ jobs -p + exit 0 Executing(%install): /bin/sh -e /var/tmp/rpm-tmp.8V1KvV + umask 022 + cd /builddir/build/BUILD + '[' /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch '!=' / ']' + rm -rf /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch ++ dirname /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch + mkdir -p /builddir/build/BUILDROOT + mkdir /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CFLAGS + CXXFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CXXFLAGS + FFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FFLAGS + FCFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FCFLAGS + VALAFLAGS=-g + export VALAFLAGS + RUSTFLAGS='-Copt-level=3 -Cdebuginfo=2 -Ccodegen-units=1 -Cstrip=none -Cforce-frame-pointers=yes -Clink-arg=-Wl,-z,relro -Clink-arg=-Wl,-z,now --cap-lints=warn' + export RUSTFLAGS + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + export LDFLAGS + LT_SYS_LIBRARY_PATH=/usr/lib: + export LT_SYS_LIBRARY_PATH + CC=gcc + export CC + CXX=g++ + export CXX + cd input-remapper-2.0.1 ++ xargs basename --multiple ++ sed -E 's/([^-]+)-([^-]+)-.+\.whl/\1==\2/' ++ ls /builddir/build/BUILD/input-remapper-2.0.1/pyproject-wheeldir/input_remapper-2.0.1-py3-none-any.whl + specifier=input_remapper==2.0.1 + '[' -z input_remapper==2.0.1 ']' + TMPDIR=/builddir/build/BUILD/input-remapper-2.0.1/.pyproject-builddir + /usr/bin/python3 -m pip install --root /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch --prefix /usr --no-deps --disable-pip-version-check --progress-bar off --verbose --ignore-installed --no-warn-script-location --no-index --no-cache-dir --find-links /builddir/build/BUILD/input-remapper-2.0.1/pyproject-wheeldir input_remapper==2.0.1 Using pip 23.3.2 from /usr/lib/python3.12/site-packages/pip (python 3.12) Looking in links: /builddir/build/BUILD/input-remapper-2.0.1/pyproject-wheeldir Processing ./pyproject-wheeldir/input_remapper-2.0.1-py3-none-any.whl Installing collected packages: input_remapper Successfully installed input_remapper-2.0.1 + '[' -d /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/bin ']' + rm -f /builddir/build/BUILD/input-remapper-2.0.1-1.fc40.noarch-pyproject-ghost-distinfo + site_dirs=() + '[' -d /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib/python3.12/site-packages ']' + site_dirs+=("/usr/lib/python3.12/site-packages") + '[' /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib64/python3.12/site-packages '!=' /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib/python3.12/site-packages ']' + '[' -d /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib64/python3.12/site-packages ']' + for site_dir in ${site_dirs[@]} + for distinfo in /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch$site_dir/*.dist-info + echo '%ghost /usr/lib/python3.12/site-packages/input_remapper-2.0.1.dist-info' + sed -i s/pip/rpm/ /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib/python3.12/site-packages/input_remapper-2.0.1.dist-info/INSTALLER + PYTHONPATH=/usr/lib/rpm/redhat + /usr/bin/python3 -B /usr/lib/rpm/redhat/pyproject_preprocess_record.py --buildroot /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch --record /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib/python3.12/site-packages/input_remapper-2.0.1.dist-info/RECORD --output /builddir/build/BUILD/input-remapper-2.0.1-1.fc40.noarch-pyproject-record + rm -fv /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib/python3.12/site-packages/input_remapper-2.0.1.dist-info/RECORD removed '/builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib/python3.12/site-packages/input_remapper-2.0.1.dist-info/RECORD' + rm -fv /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib/python3.12/site-packages/input_remapper-2.0.1.dist-info/REQUESTED removed '/builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib/python3.12/site-packages/input_remapper-2.0.1.dist-info/REQUESTED' ++ wc -l /builddir/build/BUILD/input-remapper-2.0.1-1.fc40.noarch-pyproject-ghost-distinfo ++ cut -f1 '-d ' + lines=1 + '[' 1 -ne 1 ']' + RPM_PERCENTAGES_COUNT=2 + /usr/bin/python3 /usr/lib/rpm/redhat/pyproject_save_files.py --output-files /builddir/build/BUILD/input-remapper-2.0.1-1.fc40.noarch-pyproject-files --output-modules /builddir/build/BUILD/input-remapper-2.0.1-1.fc40.noarch-pyproject-modules --buildroot /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch --sitelib /usr/lib/python3.12/site-packages --sitearch /usr/lib64/python3.12/site-packages --python-version 3.12 --pyproject-record /builddir/build/BUILD/input-remapper-2.0.1-1.fc40.noarch-pyproject-record --prefix /usr inputremapper + mv /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib/python3.12/site-packages/etc /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/etc + mv /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib/python3.12/site-packages/usr/bin /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/bin + mv /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib/python3.12/site-packages/usr/lib/systemd /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib/systemd + mv /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib/python3.12/site-packages/usr/lib/udev /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib/udev + mv /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib/python3.12/site-packages/usr/share /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/share + mkdir -p /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/share/dbus-1/system.d/ + mv /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/etc/dbus-1/system.d/inputremapper.Control.conf /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/share/dbus-1/system.d/ + rm /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/share/input-remapper/inputremapper.Control.conf + rm /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/share/input-remapper/io.github.sezanzeb.input_remapper.metainfo.xml + rm /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/share/input-remapper/input-remapper-gtk.desktop + rm /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/share/input-remapper/input-remapper.policy + /usr/bin/find-debuginfo -j8 --strict-build-id -m -i --build-id-seed 2.0.1-1.fc40 --unique-debug-suffix -2.0.1-1.fc40.noarch --unique-debug-src-base input-remapper-2.0.1-1.fc40.noarch --run-dwz --dwz-low-mem-die-limit 10000000 --dwz-max-die-limit 50000000 -S debugsourcefiles.list /builddir/build/BUILD/input-remapper-2.0.1 find-debuginfo: starting Extracting debug info from 0 files Creating .debug symlinks for symlinks to ELF files find: ‘debug’: No such file or directory find-debuginfo: done + /usr/lib/rpm/check-buildroot + /usr/lib/rpm/redhat/brp-ldconfig + /usr/lib/rpm/brp-compress + /usr/lib/rpm/redhat/brp-strip-lto /usr/bin/strip + /usr/lib/rpm/brp-strip-static-archive /usr/bin/strip + /usr/lib/rpm/check-rpaths + /usr/lib/rpm/redhat/brp-mangle-shebangs + /usr/lib/rpm/brp-remove-la-files + env /usr/lib/rpm/redhat/brp-python-bytecompile '' 1 0 -j8 Bytecompiling .py files below /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib/python3.12 using python3.12 /usr/lib/python3.12/site-packages/inputremapper/gui/messages/message_data.py:45: SyntaxWarning: invalid escape sequence '\d' /usr/lib/python3.12/site-packages/inputremapper/gui/controller.py:304: SyntaxWarning: invalid escape sequence '\d' /usr/lib/python3.12/site-packages/inputremapper/gui/messages/message_data.py:45: SyntaxWarning: invalid escape sequence '\d' /usr/lib/python3.12/site-packages/inputremapper/gui/controller.py:304: SyntaxWarning: invalid escape sequence '\d' + /usr/lib/rpm/redhat/brp-python-hardlink Executing(%check): /bin/sh -e /var/tmp/rpm-tmp.SYrYsN + umask 022 + cd /builddir/build/BUILD + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CFLAGS + CXXFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + export CXXFLAGS + FFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FFLAGS + FCFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer -I/usr/lib/gfortran/modules ' + export FCFLAGS + VALAFLAGS=-g + export VALAFLAGS + RUSTFLAGS='-Copt-level=3 -Cdebuginfo=2 -Ccodegen-units=1 -Cstrip=none -Cforce-frame-pointers=yes -Clink-arg=-Wl,-z,relro -Clink-arg=-Wl,-z,now --cap-lints=warn' + export RUSTFLAGS + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + export LDFLAGS + LT_SYS_LIBRARY_PATH=/usr/lib: + export LT_SYS_LIBRARY_PATH + CC=gcc + export CC + CXX=g++ + export CXX + cd input-remapper-2.0.1 + desktop-file-validate /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch//usr/share/applications/input-remapper-gtk.desktop + appstream-util validate-relax --nonet /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/share/metainfo/io.github.sezanzeb.input_remapper.metainfo.xml /builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/share/metainfo/io.github.sezanzeb.input_remapper.metainfo.xml: OK + export TMPDIR=/builddir/build/BUILD/input-remapper-2.0.1/test_tmp + TMPDIR=/builddir/build/BUILD/input-remapper-2.0.1/test_tmp + mkdir -p /builddir/build/BUILD/input-remapper-2.0.1/test_tmp + export DATA_DIR=/builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/share/input-remapper + DATA_DIR=/builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/share/input-remapper + '[' '!' -f /builddir/build/BUILD/input-remapper-2.0.1-1.fc40.noarch-pyproject-modules ']' + PATH=/builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/sbin + PYTHONPATH=/builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib64/python3.12/site-packages:/builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib/python3.12/site-packages + _PYTHONSITE=/builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib64/python3.12/site-packages:/builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib/python3.12/site-packages + PYTHONDONTWRITEBYTECODE=1 + /usr/bin/python3 -sP /usr/lib/rpm/redhat/import_all_modules.py -f /builddir/build/BUILD/input-remapper-2.0.1-1.fc40.noarch-pyproject-modules Check import: inputremapper Check import: inputremapper.configs Check import: inputremapper.configs.base_config Check import: inputremapper.configs.data Check import: inputremapper.configs.global_config Check import: inputremapper.configs.input_config Check import: inputremapper.configs.mapping Check import: inputremapper.configs.migrations Check import: inputremapper.configs.paths Check import: inputremapper.configs.preset Check import: inputremapper.configs.system_mapping Check import: inputremapper.configs.validation_errors Check import: inputremapper.daemon Check import: inputremapper.exceptions Check import: inputremapper.groups Check import: inputremapper.gui Check import: inputremapper.gui.autocompletion Check import: inputremapper.gui.components Check import: inputremapper.gui.components.common Check import: inputremapper.gui.components.device_groups Check import: inputremapper.gui.components.editor Check import: inputremapper.gui.components.main Check import: inputremapper.gui.components.presets Check import: inputremapper.gui.controller Check import: inputremapper.gui.data_manager Check import: inputremapper.gui.gettext Check import: inputremapper.gui.messages Check import: inputremapper.gui.messages.message_broker Check import: inputremapper.gui.messages.message_data Check import: inputremapper.gui.messages.message_types Check import: inputremapper.gui.reader_client Check import: inputremapper.gui.reader_service Check import: inputremapper.gui.user_interface Check import: inputremapper.gui.utils Check import: inputremapper.injection Check import: inputremapper.injection.context Check import: inputremapper.injection.event_reader Check import: inputremapper.injection.global_uinputs Check import: inputremapper.injection.injector Check import: inputremapper.injection.macros Check import: inputremapper.injection.macros.macro Check import: inputremapper.injection.macros.parse Check import: inputremapper.injection.mapping_handlers Check import: inputremapper.injection.mapping_handlers.abs_to_abs_handler Check import: inputremapper.injection.mapping_handlers.abs_to_btn_handler Check import: inputremapper.injection.mapping_handlers.abs_to_rel_handler Check import: inputremapper.injection.mapping_handlers.axis_switch_handler Check import: inputremapper.injection.mapping_handlers.axis_transform Check import: inputremapper.injection.mapping_handlers.combination_handler Check import: inputremapper.injection.mapping_handlers.hierarchy_handler Check import: inputremapper.injection.mapping_handlers.key_handler Check import: inputremapper.injection.mapping_handlers.macro_handler Check import: inputremapper.injection.mapping_handlers.mapping_handler Check import: inputremapper.injection.mapping_handlers.mapping_parser Check import: inputremapper.injection.mapping_handlers.null_handler Check import: inputremapper.injection.mapping_handlers.rel_to_abs_handler Check import: inputremapper.injection.mapping_handlers.rel_to_btn_handler Check import: inputremapper.injection.mapping_handlers.rel_to_rel_handler Check import: inputremapper.injection.numlock Check import: inputremapper.input_event Check import: inputremapper.ipc Check import: inputremapper.ipc.pipe Check import: inputremapper.ipc.shared_dict Check import: inputremapper.ipc.socket Check import: inputremapper.logger Check import: inputremapper.user Check import: inputremapper.utils + ignore=' --ignore=tests/unit/test_daemon.py' + ignore=' --ignore=tests/unit/test_daemon.py --ignore=tests/unit/test_migrations.py' + k='not (TestRelToAbs and test_rel_to_abs)' + k='not (TestRelToAbs and test_rel_to_abs) and not (TestAbsToRel and test_abs_to_rel)' + k='not (TestRelToAbs and test_rel_to_abs) and not (TestAbsToRel and test_abs_to_rel) and not (TestIdk and test_axis_switch)' + k='not (TestRelToAbs and test_rel_to_abs) and not (TestAbsToRel and test_abs_to_rel) and not (TestIdk and test_axis_switch) and not (TestMacros and test_2)' + k='not (TestRelToAbs and test_rel_to_abs) and not (TestAbsToRel and test_abs_to_rel) and not (TestIdk and test_axis_switch) and not (TestMacros and test_2) and not (TestMacros and test_3)' + k='not (TestRelToAbs and test_rel_to_abs) and not (TestAbsToRel and test_abs_to_rel) and not (TestIdk and test_axis_switch) and not (TestMacros and test_2) and not (TestMacros and test_3) and not (TestMacros and test_5)' + k='not (TestRelToAbs and test_rel_to_abs) and not (TestAbsToRel and test_abs_to_rel) and not (TestIdk and test_axis_switch) and not (TestMacros and test_2) and not (TestMacros and test_3) and not (TestMacros and test_5) and not (TestMacros and test_mouse)' + CFLAGS='-O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Werror=implicit-function-declaration -Werror=implicit-int -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fno-omit-frame-pointer ' + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 ' + PATH=/builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/sbin + PYTHONPATH=/builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib64/python3.12/site-packages:/builddir/build/BUILDROOT/input-remapper-2.0.1-1.fc40.noarch/usr/lib/python3.12/site-packages + PYTHONDONTWRITEBYTECODE=1 + PYTEST_ADDOPTS=' --ignore=/builddir/build/BUILD/input-remapper-2.0.1/.pyproject-builddir' + PYTEST_XDIST_AUTO_NUM_WORKERS=8 + /usr/bin/pytest tests/unit --ignore=tests/unit/test_daemon.py --ignore=tests/unit/test_migrations.py -k 'not (TestRelToAbs and test_rel_to_abs) and not (TestAbsToRel and test_abs_to_rel) and not (TestIdk and test_axis_switch) and not (TestMacros and test_2) and not (TestMacros and test_3) and not (TestMacros and test_5) and not (TestMacros and test_mouse)' -v ============================= test session starts ============================== platform linux -- Python 3.12.0, pytest-7.3.2, pluggy-1.3.0 -- /usr/bin/python3 cachedir: .pytest_cache rootdir: /builddir/build/BUILD/input-remapper-2.0.1 collecting ... collected 405 items / 8 deselected / 397 selected tests/unit/test_config.py::TestConfig::test_autoload PASSED [ 0%] tests/unit/test_config.py::TestConfig::test_basic PASSED [ 0%] tests/unit/test_config.py::TestConfig::test_initial PASSED [ 0%] tests/unit/test_config.py::TestConfig::test_save_load PASSED [ 1%] tests/unit/test_context.py::TestContext::test_callbacks PASSED [ 1%] tests/unit/test_control.py::TestControl::test_autoload PASSED [ 1%] tests/unit/test_control.py::TestControl::test_autoload_config_dir PASSED [ 1%] tests/unit/test_control.py::TestControl::test_autoload_other_path PASSED [ 2%] tests/unit/test_control.py::TestControl::test_config_not_found PASSED [ 2%] tests/unit/test_control.py::TestControl::test_internals PASSED [ 2%] tests/unit/test_control.py::TestControl::test_start_stop PASSED [ 2%] tests/unit/test_controller.py::TestController::test_close PASSED [ 3%] tests/unit/test_controller.py::TestController::test_copy_preset PASSED [ 3%] tests/unit/test_controller.py::TestController::test_copy_preset_should_add_number PASSED [ 3%] tests/unit/test_controller.py::TestController::test_copy_preset_should_increment_existing_number PASSED [ 3%] tests/unit/test_controller.py::TestController::test_copy_preset_should_not_append_copy_to_copy_with_number PASSED [ 4%] tests/unit/test_controller.py::TestController::test_copy_preset_should_not_append_copy_twice PASSED [ 4%] tests/unit/test_controller.py::TestController::test_create_mapping_should_not_create_multiple_empty_mappings PASSED [ 4%] tests/unit/test_controller.py::TestController::test_create_mapping_will_load_the_created_mapping PASSED [ 4%] tests/unit/test_controller.py::TestController::test_delete_mapping_asks_for_confirmation PASSED [ 5%] tests/unit/test_controller.py::TestController::test_deletes_mapping_when_confirmed PASSED [ 5%] tests/unit/test_controller.py::TestController::test_deletes_preset_when_confirmed PASSED [ 5%] tests/unit/test_controller.py::TestController::test_does_not_delete_mapping_when_not_confirmed PASSED [ 5%] tests/unit/test_controller.py::TestController::test_does_not_delete_preset_when_not_confirmed PASSED [ 6%] tests/unit/test_controller.py::TestController::test_key_recording_disables_gui_shortcuts PASSED [ 6%] tests/unit/test_controller.py::TestController::test_key_recording_enables_gui_shortcuts_when_finished PASSED [ 6%] tests/unit/test_controller.py::TestController::test_key_recording_enables_gui_shortcuts_when_stopped PASSED [ 6%] tests/unit/test_controller.py::TestController::test_key_recording_stops_when_finished PASSED [ 7%] tests/unit/test_controller.py::TestController::test_key_recording_stops_when_stopped PASSED [ 7%] tests/unit/test_controller.py::TestController::test_key_recording_updates_mapping_combination PASSED [ 7%] tests/unit/test_controller.py::TestController::test_move_event_down PASSED [ 7%] tests/unit/test_controller.py::TestController::test_move_event_in_combination_of_len_1 PASSED [ 8%] tests/unit/test_controller.py::TestController::test_move_event_loads_it_again PASSED [ 8%] tests/unit/test_controller.py::TestController::test_move_event_up PASSED [ 8%] tests/unit/test_controller.py::TestController::test_no_key_recording_when_not_started PASSED [ 8%] tests/unit/test_controller.py::TestController::test_on_add_preset_shows_permission_error_status PASSED [ 9%] tests/unit/test_controller.py::TestController::test_on_add_preset_uses_default_name PASSED [ 9%] tests/unit/test_controller.py::TestController::test_on_add_preset_uses_provided_name PASSED [ 9%] tests/unit/test_controller.py::TestController::test_on_delete_preset_asks_for_confirmation PASSED [ 9%] tests/unit/test_controller.py::TestController::test_on_init_should_provide_a_default_mapping PASSED [ 10%] tests/unit/test_controller.py::TestController::test_on_init_should_provide_a_group PASSED [ 10%] tests/unit/test_controller.py::TestController::test_on_init_should_provide_a_mapping PASSED [ 10%] tests/unit/test_controller.py::TestController::test_on_init_should_provide_a_preset PASSED [ 10%] tests/unit/test_controller.py::TestController::test_on_init_should_provide_groups PASSED [ 11%] tests/unit/test_controller.py::TestController::test_on_init_should_provide_uinputs PASSED [ 11%] tests/unit/test_controller.py::TestController::test_on_load_group_should_provide_default_mapping PASSED [ 11%] tests/unit/test_controller.py::TestController::test_on_load_group_should_provide_mapping PASSED [ 11%] tests/unit/test_controller.py::TestController::test_on_load_group_should_provide_preset PASSED [ 12%] tests/unit/test_controller.py::TestController::test_on_load_preset_should_provide_default_mapping PASSED [ 12%] tests/unit/test_controller.py::TestController::test_on_load_preset_should_provide_mapping PASSED [ 12%] tests/unit/test_controller.py::TestController::test_on_update_mapping PASSED [ 12%] tests/unit/test_controller.py::TestController::test_recording_messages PASSED [ 13%] tests/unit/test_controller.py::TestController::test_remove_event_does_nothing_when_mapping_not_loaded PASSED [ 13%] tests/unit/test_controller.py::TestController::test_remove_event_loads_a_event PASSED [ 13%] tests/unit/test_controller.py::TestController::test_remove_event_reloads_mapping_and_event_when_update_fails PASSED [ 13%] tests/unit/test_controller.py::TestController::test_remove_event_removes_active_event PASSED [ 14%] tests/unit/test_controller.py::TestController::test_rename_preset PASSED [ 14%] tests/unit/test_controller.py::TestController::test_rename_preset_sanitized PASSED [ 14%] tests/unit/test_controller.py::TestController::test_rename_preset_should_not_rename_to_empty_name PASSED [ 14%] tests/unit/test_controller.py::TestController::test_rename_preset_should_not_update_same_name PASSED [ 15%] tests/unit/test_controller.py::TestController::test_rename_preset_should_pick_available_name PASSED [ 15%] tests/unit/test_controller.py::TestController::test_set_autoload_refreshes_service_config PASSED [ 15%] tests/unit/test_controller.py::TestController::test_set_event_as_analog_adds_abs_threshold PASSED [ 15%] tests/unit/test_controller.py::TestController::test_set_event_as_analog_adds_rel_threshold PASSED [ 16%] tests/unit/test_controller.py::TestController::test_set_event_as_analog_reloads_mapping_and_event_when_key_event PASSED [ 16%] tests/unit/test_controller.py::TestController::test_set_event_as_analog_reloads_when_setting_to_analog_fails PASSED [ 16%] tests/unit/test_controller.py::TestController::test_set_event_as_analog_reloads_when_setting_to_key_fails PASSED [ 16%] tests/unit/test_controller.py::TestController::test_set_event_as_analog_saves PASSED [ 17%] tests/unit/test_controller.py::TestController::test_set_event_as_analog_sets_input_to_analog PASSED [ 17%] tests/unit/test_controller.py::TestController::test_sets_input_to_analog PASSED [ 17%] tests/unit/test_controller.py::TestController::test_should_get_any_group PASSED [ 17%] tests/unit/test_controller.py::TestController::test_should_get_any_preset PASSED [ 18%] tests/unit/test_controller.py::TestController::test_should_get_newest_group PASSED [ 18%] tests/unit/test_controller.py::TestController::test_should_get_newest_preset PASSED [ 18%] tests/unit/test_controller.py::TestController::test_should_not_update_combination PASSED [ 18%] tests/unit/test_controller.py::TestController::test_should_update_combination PASSED [ 19%] tests/unit/test_controller.py::TestController::test_show_injection_result PASSED [ 19%] tests/unit/test_controller.py::TestController::test_start_injecting_adds_listener_to_update_injector_status PASSED [ 19%] tests/unit/test_controller.py::TestController::test_start_injecting_shows_failure_status PASSED [ 19%] tests/unit/test_controller.py::TestController::test_start_injecting_shows_status PASSED [ 20%] tests/unit/test_controller.py::TestController::test_start_injecting_shows_status_when_preset_empty PASSED [ 20%] tests/unit/test_controller.py::TestController::test_start_injecting_starts_with_btn_left_on_second_try PASSED [ 20%] tests/unit/test_controller.py::TestController::test_start_injecting_starts_with_btn_left_when_mapped_to_other_button PASSED [ 20%] tests/unit/test_controller.py::TestController::test_start_injecting_warns_about_btn_left PASSED [ 21%] tests/unit/test_controller.py::TestController::test_stop_injecting_shows_status PASSED [ 21%] tests/unit/test_controller.py::TestController::test_update_event PASSED [ 21%] tests/unit/test_controller.py::TestController::test_update_event_reloads_mapping_and_event_when_update_fails PASSED [ 21%] tests/unit/test_controller.py::TestController::test_update_mapping_type_will_abort_when_user_denys PASSED [ 22%] tests/unit/test_controller.py::TestController::test_update_mapping_type_will_ask_user_when_output_symbol_is_set PASSED [ 22%] tests/unit/test_controller.py::TestController::test_update_mapping_type_will_delete_output_symbol_when_user_confirms PASSED [ 22%] tests/unit/test_controller.py::TestController::test_update_mapping_type_will_notify_user_to_recorde_analog_input PASSED [ 22%] tests/unit/test_controller.py::TestController::test_update_mapping_type_will_tell_user_which_input_is_used_as_analog PASSED [ 23%] tests/unit/test_controller.py::TestController::test_update_mapping_type_will_will_autoconfigure_the_input PASSED [ 23%] tests/unit/test_controller.py::TestController::test_update_mapping_update_to_analog_without_asking PASSED [ 23%] tests/unit/test_controller.py::TestController::test_update_mapping_update_to_key_macro_without_asking PASSED [ 23%] tests/unit/test_controller.py::TestController::test_update_mapping_will_ask_user_to_set_trigger_threshold PASSED [ 24%] tests/unit/test_controller.py::TestController::test_update_mapping_will_remove_output_type_and_code PASSED [ 24%] tests/unit/test_data_manager.py::TestDataManager::test_add_preset PASSED [ 24%] tests/unit/test_data_manager.py::TestDataManager::test_available_preset_name__adds_number_to_provided_name PASSED [ 24%] tests/unit/test_data_manager.py::TestDataManager::test_available_preset_name_adds_number_to_default PASSED [ 25%] tests/unit/test_data_manager.py::TestDataManager::test_available_preset_name_default PASSED [ 25%] tests/unit/test_data_manager.py::TestDataManager::test_available_preset_name_increments_default PASSED [ 25%] tests/unit/test_data_manager.py::TestDataManager::test_available_preset_name_increments_provided_name PASSED [ 25%] tests/unit/test_data_manager.py::TestDataManager::test_available_preset_name_raises_data_management_error PASSED [ 26%] tests/unit/test_data_manager.py::TestDataManager::test_available_preset_name_returns_provided_name PASSED [ 26%] tests/unit/test_data_manager.py::TestDataManager::test_available_preset_name_sanitized PASSED [ 26%] tests/unit/test_data_manager.py::TestDataManager::test_cannot_add_preset PASSED [ 26%] tests/unit/test_data_manager.py::TestDataManager::test_cannot_add_preset_without_group PASSED [ 27%] tests/unit/test_data_manager.py::TestDataManager::test_cannot_copy_preset PASSED [ 27%] tests/unit/test_data_manager.py::TestDataManager::test_cannot_create_mapping_without_preset PASSED [ 27%] tests/unit/test_data_manager.py::TestDataManager::test_cannot_delete_mapping PASSED [ 27%] tests/unit/test_data_manager.py::TestDataManager::test_cannot_get_injector_state_without_group PASSED [ 28%] tests/unit/test_data_manager.py::TestDataManager::test_cannot_load_event_when_mapping_not_set PASSED [ 28%] tests/unit/test_data_manager.py::TestDataManager::test_cannot_load_event_when_not_in_mapping_combination PASSED [ 28%] tests/unit/test_data_manager.py::TestDataManager::test_cannot_load_mapping_without_preset PASSED [ 28%] tests/unit/test_data_manager.py::TestDataManager::test_cannot_load_non_existing_mapping PASSED [ 29%] tests/unit/test_data_manager.py::TestDataManager::test_cannot_load_non_existing_preset PASSED [ 29%] tests/unit/test_data_manager.py::TestDataManager::test_cannot_load_preset_without_group PASSED [ 29%] tests/unit/test_data_manager.py::TestDataManager::test_cannot_rename_preset PASSED [ 29%] tests/unit/test_data_manager.py::TestDataManager::test_cannot_rename_preset_without_preset PASSED [ 30%] tests/unit/test_data_manager.py::TestDataManager::test_cannot_set_autoload_without_preset PASSED [ 30%] tests/unit/test_data_manager.py::TestDataManager::test_cannot_start_injecting_without_preset PASSED [ 30%] tests/unit/test_data_manager.py::TestDataManager::test_cannot_stop_injecting_without_group PASSED [ 30%] tests/unit/test_data_manager.py::TestDataManager::test_cannot_update_event_when_not_loaded PASSED [ 31%] tests/unit/test_data_manager.py::TestDataManager::test_cannot_update_event_when_resulting_combination_exists PASSED [ 31%] tests/unit/test_data_manager.py::TestDataManager::test_cannot_update_mapping PASSED [ 31%] tests/unit/test_data_manager.py::TestDataManager::test_cannot_update_mapping_combination PASSED [ 31%] tests/unit/test_data_manager.py::TestDataManager::test_copy_preset PASSED [ 32%] tests/unit/test_data_manager.py::TestDataManager::test_copy_preset_to_existing_name_raises_error PASSED [ 32%] tests/unit/test_data_manager.py::TestDataManager::test_create_mapping PASSED [ 32%] tests/unit/test_data_manager.py::TestDataManager::test_delete_mapping PASSED [ 32%] tests/unit/test_data_manager.py::TestDataManager::test_delete_preset PASSED [ 33%] tests/unit/test_data_manager.py::TestDataManager::test_delete_preset_sanitized PASSED [ 33%] tests/unit/test_data_manager.py::TestDataManager::test_each_device_can_have_autoload PASSED [ 33%] tests/unit/test_data_manager.py::TestDataManager::test_finds_newest_group PASSED [ 34%] tests/unit/test_data_manager.py::TestDataManager::test_finds_newest_preset PASSED [ 34%] tests/unit/test_data_manager.py::TestDataManager::test_load_event PASSED [ 34%] tests/unit/test_data_manager.py::TestDataManager::test_load_group_provides_presets PASSED [ 34%] tests/unit/test_data_manager.py::TestDataManager::test_load_group_without_presets_provides_none PASSED [ 35%] tests/unit/test_data_manager.py::TestDataManager::test_load_mapping PASSED [ 35%] tests/unit/test_data_manager.py::TestDataManager::test_load_non_existing_group PASSED [ 35%] tests/unit/test_data_manager.py::TestDataManager::test_load_preset PASSED [ 35%] tests/unit/test_data_manager.py::TestDataManager::test_newest_group_and_preset_raises_file_not_found PASSED [ 36%] tests/unit/test_data_manager.py::TestDataManager::test_newest_group_ignores_unknon_groups PASSED [ 36%] tests/unit/test_data_manager.py::TestDataManager::test_newest_group_ignores_unknown_filetypes PASSED [ 36%] tests/unit/test_data_manager.py::TestDataManager::test_newest_preset_ignores_unknown_filetypes PASSED [ 36%] tests/unit/test_data_manager.py::TestDataManager::test_newest_preset_only_searches_active_group PASSED [ 37%] tests/unit/test_data_manager.py::TestDataManager::test_newest_preset_raises_data_management_error PASSED [ 37%] tests/unit/test_data_manager.py::TestDataManager::test_rename_preset PASSED [ 37%] tests/unit/test_data_manager.py::TestDataManager::test_rename_preset_sets_autoload_correct PASSED [ 37%] tests/unit/test_data_manager.py::TestDataManager::test_save_preset PASSED [ 38%] tests/unit/test_data_manager.py::TestDataManager::test_set_autoload PASSED [ 38%] tests/unit/test_data_manager.py::TestDataManager::test_should_load_group PASSED [ 38%] tests/unit/test_data_manager.py::TestDataManager::test_should_publish_groups PASSED [ 38%] tests/unit/test_data_manager.py::TestDataManager::test_should_send_uinputs PASSED [ 39%] tests/unit/test_data_manager.py::TestDataManager::test_should_start_reading_active_group PASSED [ 39%] tests/unit/test_data_manager.py::TestDataManager::test_update_event PASSED [ 39%] tests/unit/test_data_manager.py::TestDataManager::test_update_event_sends_messages PASSED [ 39%] tests/unit/test_data_manager.py::TestDataManager::test_update_mapping_combination_sends_massage PASSED [ 40%] tests/unit/test_data_manager.py::TestDataManager::test_update_mapping_emits_mapping_changed PASSED [ 40%] tests/unit/test_data_manager.py::TestDataManager::test_updated_mapping_can_be_saved PASSED [ 40%] tests/unit/test_data_manager.py::TestDataManager::test_updated_mapping_saves_invalid_mapping PASSED [ 40%] tests/unit/test_event_reader.py::TestEventReader::test_if_single_joystick_then FAILED [ 41%] tests/unit/test_event_reader.py::TestEventReader::test_if_single_joystick_under_threshold FAILED [ 41%] tests/unit/test_global_uinputs.py::TestFrontendUinput::test_init PASSED [ 41%] tests/unit/test_global_uinputs.py::TestGlobalUinputs::test_creates_frontend_uinputs PASSED [ 41%] tests/unit/test_global_uinputs.py::TestGlobalUinputs::test_iter PASSED [ 42%] tests/unit/test_global_uinputs.py::TestGlobalUinputs::test_write PASSED [ 42%] tests/unit/test_groups.py::TestGroups::test_classify PASSED [ 42%] tests/unit/test_groups.py::TestGroups::test_device_with_only_ev_abs PASSED [ 42%] tests/unit/test_groups.py::TestGroups::test_duplicate_device PASSED [ 43%] tests/unit/test_groups.py::TestGroups::test_filter PASSED [ 43%] tests/unit/test_groups.py::TestGroups::test_find_groups PASSED [ 43%] tests/unit/test_groups.py::TestGroups::test_group PASSED [ 43%] tests/unit/test_groups.py::TestGroups::test_list_group_names PASSED [ 44%] tests/unit/test_groups.py::TestGroups::test_skip_camera PASSED [ 44%] tests/unit/test_injector.py::TestInjector::test_capabilities_and_uinput_presence PASSED [ 44%] tests/unit/test_injector.py::TestInjector::test_fail_grab FAILED [ 44%] tests/unit/test_injector.py::TestInjector::test_fail_grab ERROR [ 44%] tests/unit/test_injector.py::TestInjector::test_forward_gamepad_events PASSED [ 45%] tests/unit/test_injector.py::TestInjector::test_get_udev_name PASSED [ 45%] tests/unit/test_injector.py::TestInjector::test_grab PASSED [ 45%] tests/unit/test_injector.py::TestInjector::test_grab_device_1 PASSED [ 45%] tests/unit/test_injector.py::TestInjector::test_injector FAILED [ 46%] tests/unit/test_injector.py::TestInjector::test_injector ERROR [ 46%] tests/unit/test_injector.py::TestInjector::test_is_in_capabilities PASSED [ 46%] tests/unit/test_injector.py::TestInjector::test_skip_unknown_device PASSED [ 46%] tests/unit/test_injector.py::TestInjector::test_skip_unused_device PASSED [ 46%] tests/unit/test_injector.py::TestModifyCapabilities::test_copy_capabilities PASSED [ 47%] tests/unit/test_input_config.py::TestInputConfig::test_input_config PASSED [ 47%] tests/unit/test_input_config.py::TestInputConfig::test_is_immutable PASSED [ 47%] tests/unit/test_input_config.py::TestInputCombination::test_beautify PASSED [ 47%] tests/unit/test_input_config.py::TestInputCombination::test_can_be_used_as_dict_key PASSED [ 48%] tests/unit/test_input_config.py::TestInputCombination::test_eq PASSED [ 48%] tests/unit/test_input_config.py::TestInputCombination::test_find_analog_input_config PASSED [ 48%] tests/unit/test_input_config.py::TestInputCombination::test_get_permutations PASSED [ 48%] tests/unit/test_input_config.py::TestInputCombination::test_init PASSED [ 49%] tests/unit/test_input_config.py::TestInputCombination::test_is_problematic PASSED [ 49%] tests/unit/test_input_config.py::TestInputCombination::test_not_eq PASSED [ 49%] tests/unit/test_input_config.py::TestInputCombination::test_to_config PASSED [ 49%] tests/unit/test_input_event.py::TestInputEvent::test_from_event PASSED [ 50%] tests/unit/test_input_event.py::TestInputEvent::test_from_event_tuple PASSED [ 50%] tests/unit/test_input_event.py::TestInputEvent::test_is_wheel_event PASSED [ 50%] tests/unit/test_input_event.py::TestInputEvent::test_modify PASSED [ 50%] tests/unit/test_input_event.py::TestInputEvent::test_properties PASSED [ 51%] tests/unit/test_ipc.py::TestSharedDict::test_returns_none PASSED [ 51%] tests/unit/test_ipc.py::TestSharedDict::test_set_get FAILED [ 51%] tests/unit/test_ipc.py::TestSocket::test_base_abstract PASSED [ 51%] tests/unit/test_ipc.py::TestSocket::test_not_connected_1 PASSED [ 52%] tests/unit/test_ipc.py::TestSocket::test_not_connected_2 PASSED [ 52%] tests/unit/test_ipc.py::TestSocket::test_select PASSED [ 52%] tests/unit/test_ipc.py::TestSocket::test_socket PASSED [ 52%] tests/unit/test_ipc.py::TestPipe::test_async_for_loop PASSED [ 53%] tests/unit/test_ipc.py::TestPipe::test_async_for_loop_duo PASSED [ 53%] tests/unit/test_ipc.py::TestPipe::test_pipe_duo PASSED [ 53%] tests/unit/test_ipc.py::TestPipe::test_pipe_single PASSED [ 53%] tests/unit/test_logger.py::TestLogger::test_debug PASSED [ 54%] tests/unit/test_logger.py::TestLogger::test_default PASSED [ 54%] tests/unit/test_logger.py::TestLogger::test_log_info PASSED [ 54%] tests/unit/test_logger.py::TestLogger::test_makes_path PASSED [ 54%] tests/unit/test_logger.py::TestLogger::test_write PASSED [ 55%] tests/unit/test_macros.py::TestMacros::test_0 PASSED [ 55%] tests/unit/test_macros.py::TestMacros::test_1 PASSED [ 55%] tests/unit/test_macros.py::TestMacros::test_4 PASSED [ 55%] tests/unit/test_macros.py::TestMacros::test_6 PASSED [ 56%] tests/unit/test_macros.py::TestMacros::test_add FAILED [ 56%] tests/unit/test_macros.py::TestMacros::test_add ERROR [ 56%] tests/unit/test_macros.py::TestMacros::test_count_brackets PASSED [ 56%] tests/unit/test_macros.py::TestMacros::test_dont_hold FAILED [ 56%] tests/unit/test_macros.py::TestMacros::test_dont_just_hold FAILED [ 57%] tests/unit/test_macros.py::TestMacros::test_duplicate_run FAILED [ 57%] tests/unit/test_macros.py::TestMacros::test_event_1 PASSED [ 57%] tests/unit/test_macros.py::TestMacros::test_event_2 PASSED [ 57%] tests/unit/test_macros.py::TestMacros::test_extract_params PASSED [ 58%] tests/unit/test_macros.py::TestMacros::test_get_macro_argument_names PASSED [ 58%] tests/unit/test_macros.py::TestMacros::test_get_num_parameters PASSED [ 58%] tests/unit/test_macros.py::TestMacros::test_handle_plus_syntax PASSED [ 58%] tests/unit/test_macros.py::TestMacros::test_hold FAILED [ 59%] tests/unit/test_macros.py::TestMacros::test_hold_down PASSED [ 59%] tests/unit/test_macros.py::TestMacros::test_hold_failing_child PASSED [ 59%] tests/unit/test_macros.py::TestMacros::test_hold_keys FAILED [ 59%] tests/unit/test_macros.py::TestMacros::test_hold_keys ERROR [ 59%] tests/unit/test_macros.py::TestMacros::test_hold_variable FAILED [ 60%] tests/unit/test_macros.py::TestMacros::test_hold_variable ERROR [ 60%] tests/unit/test_macros.py::TestMacros::test_is_this_a_macro PASSED [ 60%] tests/unit/test_macros.py::TestMacros::test_just_hold FAILED [ 60%] tests/unit/test_macros.py::TestMacros::test_key FAILED [ 60%] tests/unit/test_macros.py::TestMacros::test_key ERROR [ 60%] tests/unit/test_macros.py::TestMacros::test_key_down_up FAILED [ 61%] tests/unit/test_macros.py::TestMacros::test_key_down_up ERROR [ 61%] tests/unit/test_macros.py::TestMacros::test_macro_breaks FAILED [ 61%] tests/unit/test_macros.py::TestMacros::test_macro_breaks ERROR [ 61%] tests/unit/test_macros.py::TestMacros::test_modify FAILED [ 61%] tests/unit/test_macros.py::TestMacros::test_modify ERROR [ 61%] tests/unit/test_macros.py::TestMacros::test_multiline_macro_and_comments FAILED [ 61%] tests/unit/test_macros.py::TestMacros::test_multiline_macro_and_comments ERROR [ 61%] tests/unit/test_macros.py::TestMacros::test_named_parameter PASSED [ 62%] tests/unit/test_macros.py::TestMacros::test_parse_params PASSED [ 62%] tests/unit/test_macros.py::TestMacros::test_parse_plus_syntax PASSED [ 62%] tests/unit/test_macros.py::TestMacros::test_raises_error PASSED [ 62%] tests/unit/test_macros.py::TestMacros::test_remove_comments PASSED [ 63%] tests/unit/test_macros.py::TestMacros::test_remove_whitespaces PASSED [ 63%] tests/unit/test_macros.py::TestMacros::test_resolve FAILED [ 63%] tests/unit/test_macros.py::TestMacros::test_resolve ERROR [ 63%] tests/unit/test_macros.py::TestMacros::test_run_plus_syntax FAILED [ 63%] tests/unit/test_macros.py::TestMacros::test_set FAILED [ 64%] tests/unit/test_macros.py::TestMacros::test_set ERROR [ 64%] tests/unit/test_macros.py::TestMacros::test_split_keyword_arg PASSED [ 64%] tests/unit/test_macros.py::TestMacros::test_type_check PASSED [ 64%] tests/unit/test_macros.py::TestMacros::test_type_check_variablename PASSED [ 64%] tests/unit/test_macros.py::TestIfEq::test_if_eq FAILED [ 65%] tests/unit/test_macros.py::TestIfEq::test_if_eq ERROR [ 65%] tests/unit/test_macros.py::TestIfEq::test_if_eq_runs_multiprocessed FAILED [ 65%] tests/unit/test_macros.py::TestIfEq::test_if_eq_runs_multiprocessed ERROR [ 65%] tests/unit/test_macros.py::TestIfEq::test_ifeq_none FAILED [ 65%] tests/unit/test_macros.py::TestIfEq::test_ifeq_none ERROR [ 65%] tests/unit/test_macros.py::TestIfEq::test_ifeq_runs FAILED [ 65%] tests/unit/test_macros.py::TestIfEq::test_ifeq_runs ERROR [ 65%] tests/unit/test_macros.py::TestIfEq::test_ifeq_unknown_key FAILED [ 66%] tests/unit/test_macros.py::TestIfSingle::test_if_not_single FAILED [ 66%] tests/unit/test_macros.py::TestIfSingle::test_if_not_single_none PASSED [ 66%] tests/unit/test_macros.py::TestIfSingle::test_if_single FAILED [ 67%] tests/unit/test_macros.py::TestIfSingle::test_if_single_ignores_joystick FAILED [ 67%] tests/unit/test_macros.py::TestIfSingle::test_if_single_ignores_releases FAILED [ 67%] tests/unit/test_macros.py::TestIfSingle::test_if_single_times_out FAILED [ 67%] tests/unit/test_macros.py::TestIfSingle::test_if_single_times_out ERROR [ 67%] tests/unit/test_macros.py::TestIfTap::test_if_double_tap FAILED [ 68%] tests/unit/test_macros.py::TestIfTap::test_if_not_tap FAILED [ 68%] tests/unit/test_macros.py::TestIfTap::test_if_not_tap_named FAILED [ 68%] tests/unit/test_macros.py::TestIfTap::test_if_tap FAILED [ 68%] tests/unit/test_macros.py::TestIfTap::test_if_tap_2 FAILED [ 69%] tests/unit/test_macros.py::TestIfTap::test_if_tap_none FAILED [ 69%] tests/unit/test_mapping.py::TestMapping::test_combination_changed_callback PASSED [ 69%] tests/unit/test_mapping.py::TestMapping::test_get_output_type_code PASSED [ 69%] tests/unit/test_mapping.py::TestMapping::test_init PASSED [ 70%] tests/unit/test_mapping.py::TestMapping::test_init_fails PASSED [ 70%] tests/unit/test_mapping.py::TestMapping::test_is_valid PASSED [ 70%] tests/unit/test_mapping.py::TestMapping::test_is_wheel_output PASSED [ 70%] tests/unit/test_mapping.py::TestMapping::test_revalidate_at_assignment PASSED [ 71%] tests/unit/test_mapping.py::TestMapping::test_set_invalid_combination_with_callback PASSED [ 71%] tests/unit/test_mapping.py::TestMapping::test_strips_output_symbol PASSED [ 71%] tests/unit/test_mapping.py::TestMapping::test_wrong_target PASSED [ 71%] tests/unit/test_mapping.py::TestMapping::test_wrong_target_for_macro PASSED [ 72%] tests/unit/test_mapping.py::TestUIMapping::test_copy_returns_ui_mapping PASSED [ 72%] tests/unit/test_mapping.py::TestUIMapping::test_get_bus_massage PASSED [ 72%] tests/unit/test_mapping.py::TestUIMapping::test_has_input_defined PASSED [ 72%] tests/unit/test_mapping.py::TestUIMapping::test_init PASSED [ 73%] tests/unit/test_mapping.py::TestUIMapping::test_is_valid PASSED [ 73%] tests/unit/test_mapping.py::TestUIMapping::test_updates_validation_error PASSED [ 73%] tests/unit/test_message_broker.py::TestMessageBroker::test_calls_listeners PASSED [ 73%] tests/unit/test_message_broker.py::TestMessageBroker::test_preserves_order PASSED [ 74%] tests/unit/test_message_broker.py::TestMessageBroker::test_unsubscribe PASSED [ 74%] tests/unit/test_message_broker.py::TestMessageBroker::test_unsubscribe_unknown_listener PASSED [ 74%] tests/unit/test_message_broker.py::TestSignal::test_eq PASSED [ 74%] tests/unit/test_paths.py::TestPaths::test_get_config_path PASSED [ 75%] tests/unit/test_paths.py::TestPaths::test_get_preset_path PASSED [ 75%] tests/unit/test_paths.py::TestPaths::test_mkdir PASSED [ 75%] tests/unit/test_paths.py::TestPaths::test_split_all PASSED [ 75%] tests/unit/test_paths.py::TestPaths::test_touch PASSED [ 76%] tests/unit/test_preset.py::TestPreset::test_avoids_redundant_saves PASSED [ 76%] tests/unit/test_preset.py::TestPreset::test_clear PASSED [ 76%] tests/unit/test_preset.py::TestPreset::test_combinations PASSED [ 76%] tests/unit/test_preset.py::TestPreset::test_dangerously_mapped_btn_left PASSED [ 77%] tests/unit/test_preset.py::TestPreset::test_empty PASSED [ 77%] tests/unit/test_preset.py::TestPreset::test_has_unsaved_changes PASSED [ 77%] tests/unit/test_preset.py::TestPreset::test_is_mapped_multiple_times PASSED [ 77%] tests/unit/test_preset.py::TestPreset::test_modify_mapping PASSED [ 78%] tests/unit/test_preset.py::TestPreset::test_remove PASSED [ 78%] tests/unit/test_preset.py::TestPreset::test_save_load PASSED [ 78%] tests/unit/test_preset.py::TestPreset::test_save_load_with_invalid_mappings PASSED [ 78%] tests/unit/test_reader.py::TestReaderAsyncio::test_should_forward_to_dummy FAILED [ 79%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_are_new_groups_available Exception ignored in: Traceback (most recent call last): File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/ipc/pipe.py", line 107, in __del__ self._transport.close() File "/usr/lib64/python3.12/asyncio/unix_events.py", line 569, in close self._close(None) File "/usr/lib64/python3.12/asyncio/unix_events.py", line 593, in _close self._loop.call_soon(self._call_connection_lost, exc) File "/usr/lib64/python3.12/asyncio/base_events.py", line 772, in call_soon self._check_closed() File "/usr/lib64/python3.12/asyncio/base_events.py", line 519, in _check_closed raise RuntimeError('Event loop is closed') RuntimeError: Event loop is closed FAILED [ 79%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_blacklisted_events FAILED [ 79%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_change_device FAILED [ 79%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_ignore_value_2 FAILED [ 80%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_inputremapper_devices PASSED [ 80%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_reader_service_times_out FAILED [ 80%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_reader_service_waits_for_client_to_finish FAILED [ 80%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_reader_service_wont_start PASSED [ 81%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_reader_service_wont_wait_forever FAILED [ 81%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_reading FAILED [ 81%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_reading_2 FAILED [ 81%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_reading_ignore_up FAILED [ 82%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_should_change_direction FAILED [ 82%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_should_not_trigger_at_low_speed_for_rel_axis PASSED [ 82%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_should_read_absolut_axis FAILED [ 82%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_should_release_relative_axis FAILED [ 83%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_should_trigger_wheel_at_low_speed FAILED [ 83%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_starts_the_service PASSED [ 83%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_terminate PASSED [ 83%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_wont_emit_the_same_combination_twice FAILED [ 84%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_wont_start_the_service PASSED [ 84%] tests/unit/test_reader.py::TestReaderMultiprocessing::test_wrong_device PASSED [ 84%] tests/unit/test_system_mapping.py::TestSystemMapping::test_correct_case PASSED [ 84%] tests/unit/test_system_mapping.py::TestSystemMapping::test_empty_xmodmap PASSED [ 85%] tests/unit/test_system_mapping.py::TestSystemMapping::test_get_name_no_xmodmap PASSED [ 85%] tests/unit/test_system_mapping.py::TestSystemMapping::test_system_mapping PASSED [ 85%] tests/unit/test_system_mapping.py::TestSystemMapping::test_update PASSED [ 85%] tests/unit/test_system_mapping.py::TestSystemMapping::test_xmodmap_command_missing PASSED [ 86%] tests/unit/test_system_mapping.py::TestSystemMapping::test_xmodmap_file PASSED [ 86%] tests/unit/test_test.py::TestTest::test_device_hash_from_fixture_is_correct PASSED [ 86%] tests/unit/test_test.py::TestTest::test_fake_capabilities PASSED [ 86%] tests/unit/test_test.py::TestTest::test_push_events FAILED [ 87%] tests/unit/test_test.py::TestTest::test_restore_fixtures PASSED [ 87%] tests/unit/test_test.py::TestTest::test_restore_os_environ PASSED [ 87%] tests/unit/test_test.py::TestTest::test_stubs PASSED [ 87%] tests/unit/test_user.py::TestUser::test_get_home PASSED [ 88%] tests/unit/test_user.py::TestUser::test_get_user PASSED [ 88%] tests/unit/test_util.py::TestUtil::test_get_evdev_constant_name PASSED [ 88%] tests/unit/test_event_pipeline/test_axis_transformation.py::TestAxisTransformation::test_continuity_near_deadzone PASSED [ 88%] tests/unit/test_event_pipeline/test_axis_transformation.py::TestAxisTransformation::test_deadzone PASSED [ 89%] tests/unit/test_event_pipeline/test_axis_transformation.py::TestAxisTransformation::test_expo_out_of_range PASSED [ 89%] tests/unit/test_event_pipeline/test_axis_transformation.py::TestAxisTransformation::test_expo_symmetry PASSED [ 89%] tests/unit/test_event_pipeline/test_axis_transformation.py::TestAxisTransformation::test_gain PASSED [ 89%] tests/unit/test_event_pipeline/test_axis_transformation.py::TestAxisTransformation::test_origin_symmetry PASSED [ 90%] tests/unit/test_event_pipeline/test_axis_transformation.py::TestAxisTransformation::test_returns_one_for_range_between_minus_and_plus_one PASSED [ 90%] tests/unit/test_event_pipeline/test_axis_transformation.py::TestAxisTransformation::test_scale_to_range PASSED [ 90%] tests/unit/test_event_pipeline/test_event_pipeline.py::TestIdk::test_any_event_as_button PASSED [ 90%] tests/unit/test_event_pipeline/test_event_pipeline.py::TestIdk::test_can_not_map PASSED [ 91%] tests/unit/test_event_pipeline/test_event_pipeline.py::TestIdk::test_combination PASSED [ 91%] tests/unit/test_event_pipeline/test_event_pipeline.py::TestIdk::test_combination_keycode_macro_mix PASSED [ 91%] tests/unit/test_event_pipeline/test_event_pipeline.py::TestIdk::test_forward_abs PASSED [ 91%] tests/unit/test_event_pipeline/test_event_pipeline.py::TestIdk::test_forward_rel PASSED [ 92%] tests/unit/test_event_pipeline/test_event_pipeline.py::TestIdk::test_ignore_disabled PASSED [ 92%] tests/unit/test_event_pipeline/test_event_pipeline.py::TestIdk::test_ignore_hold PASSED [ 92%] tests/unit/test_event_pipeline/test_event_pipeline.py::TestIdk::test_key_axis_combination_to_disable PASSED [ 92%] tests/unit/test_event_pipeline/test_event_pipeline.py::TestIdk::test_reset_releases_keys PASSED [ 93%] tests/unit/test_event_pipeline/test_event_pipeline.py::TestIdk::test_wheel_combination_release_failure PASSED [ 93%] tests/unit/test_event_pipeline/test_event_pipeline.py::TestAbsToAbs::test_abs_to_abs PASSED [ 93%] tests/unit/test_event_pipeline/test_event_pipeline.py::TestAbsToAbs::test_abs_to_abs_with_input_switch PASSED [ 93%] tests/unit/test_event_pipeline/test_event_pipeline.py::TestAbsToRel::test_abs_to_wheel_hi_res_quirk PASSED [ 94%] tests/unit/test_event_pipeline/test_event_pipeline.py::TestRelToBtn::test_rel_to_btn FAILED [ 94%] tests/unit/test_event_pipeline/test_event_pipeline.py::TestRelToBtn::test_rel_trigger_threshold PASSED [ 94%] tests/unit/test_event_pipeline/test_event_pipeline.py::TestAbsToBtn::test_abs_trigger_threshold PASSED [ 94%] tests/unit/test_event_pipeline/test_event_pipeline.py::TestRelToRel::test_hi_res_wheel_to_y PASSED [ 95%] tests/unit/test_event_pipeline/test_event_pipeline.py::TestRelToRel::test_remainder PASSED [ 95%] tests/unit/test_event_pipeline/test_event_pipeline.py::TestRelToRel::test_wheel_to_y PASSED [ 95%] tests/unit/test_event_pipeline/test_event_pipeline.py::TestRelToRel::test_x_to_hwheel PASSED [ 95%] tests/unit/test_event_pipeline/test_mapping_handlers.py::TestAxisSwitchHandler::test_reset PASSED [ 96%] tests/unit/test_event_pipeline/test_mapping_handlers.py::TestAbsToBtnHandler::test_reset PASSED [ 96%] tests/unit/test_event_pipeline/test_mapping_handlers.py::TestAbsToAbsHandler::test_reset PASSED [ 96%] tests/unit/test_event_pipeline/test_mapping_handlers.py::TestRelToAbsHandler::test_rate_changes PASSED [ 96%] tests/unit/test_event_pipeline/test_mapping_handlers.py::TestRelToAbsHandler::test_rate_stays PASSED [ 97%] tests/unit/test_event_pipeline/test_mapping_handlers.py::TestRelToAbsHandler::test_reset PASSED [ 97%] tests/unit/test_event_pipeline/test_mapping_handlers.py::TestAbsToRelHandler::test_reset FAILED [ 97%] tests/unit/test_event_pipeline/test_mapping_handlers.py::TestCombinationHandler::test_forward_correctly PASSED [ 97%] tests/unit/test_event_pipeline/test_mapping_handlers.py::TestCombinationHandler::test_no_forwards PASSED [ 98%] tests/unit/test_event_pipeline/test_mapping_handlers.py::TestCombinationHandler::test_reset PASSED [ 98%] tests/unit/test_event_pipeline/test_mapping_handlers.py::TestHierarchyHandler::test_reset PASSED [ 98%] tests/unit/test_event_pipeline/test_mapping_handlers.py::TestKeyHandler::test_reset PASSED [ 98%] tests/unit/test_event_pipeline/test_mapping_handlers.py::TestMacroHandler::test_reset PASSED [ 99%] tests/unit/test_event_pipeline/test_mapping_handlers.py::TestRelToBtnHandler::test_reset PASSED [ 99%] tests/unit/test_event_pipeline/test_mapping_handlers.py::TestRelToRelHanlder::test_reset PASSED [ 99%] tests/unit/test_event_pipeline/test_mapping_handlers.py::TestRelToRelHanlder::test_should_map PASSED [100%] ==================================== ERRORS ==================================== _______________ ERROR at teardown of TestInjector.test_fail_grab _______________ self = def tearDown(self): if self.injector is not None and self.injector.is_alive(): self.injector.stop_injecting() time.sleep(0.2) > self.assertIn( self.injector.get_state(), (InjectorState.STOPPED, InjectorState.FAILED, InjectorState.NO_GRAB), ) E AssertionError: not found in (, , ) tests/unit/test_injector.py:107: AssertionError ----------------------------- Captured stderr call ----------------------------- 13:36:13.131128 435078 pytest WARNING input_config.py:272: No origin_hash set for {'type': 1, 'code': 10} 13:36:14.095748 435078 pytest WARNING context.py:87: Not forward_devices set 13:36:14.448960 435078 pytest WARNING context.py:90: Not source_devices set 13:36:14.521532 435078 pytest WARNING input_config.py:272: No origin_hash set for {'type': 1, 'code': 10} 13:36:14.862184 435078 pytest DEBUG combination_handler.py:56: {'input_combination': ) at 0xffffff935fed00>, 'target_uinput': 'keyboard'} 13:36:14.909820 435078 pytest DEBUG mapping_parser.py:133: event-pipeline with entry point: KEY_9 (1, 10, None) 13:36:14.928416 435078 pytest DEBUG logger.py:77: ) at 0xffffff960d3110>" ((1, 10, None),) at 0xffffff9364e360> 13:36:15.272793 435078 pytest DEBUG logger.py:77: 13:36:15.284951 435078 pytest DEBUG logger.py:77: 'maps to: KEY_A (1, 30) on keyboard' 13:36:15.301019 435078 pytest DEBUG context.py:110: Adding NotifyCallback for (1, 10, None) 13:36:15.320121 435078 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 1 13:36:15.838608 435078 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 2 13:36:15.898228 435078 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 3 13:36:16.238521 435078 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 4 13:36:16.507681 435078 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 5 13:36:16.621036 435078 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 6 13:36:19.244761 435078 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 7 13:36:19.644633 435078 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 8 13:36:19.705134 435078 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 9 13:36:20.241045 435078 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 10 13:36:20.308228 435078 pytest ERROR injector.py:307: Cannot grab /dev/input/event10, it is possibly in use 13:36:20.318834 435078 pytest ERROR injector.py:308: 13:36:20.338143 435078 pytest DEBUG injector.py:173: Injector state of "Foo Device 2", "None": InjectorState.UNKNOWN 13:36:21.530039 435078 pytest DEBUG injector.py:173: Injector state of "Foo Device 2", "None": InjectorState.STARTING 13:36:21.854888 435998 pytest INFO injector.py:394: Starting injecting the preset for "Foo Device 2" 13:36:23.189243 435998 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 1 13:36:23.657469 435998 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 2 13:36:23.729853 435998 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 3 13:36:24.042938 435998 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 4 13:36:24.452551 435998 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 5 13:36:24.684103 435998 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 6 13:36:25.042556 435998 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 7 13:36:25.276610 435998 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 8 13:36:25.644394 435998 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 9 13:36:25.711019 435998 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 10 13:36:26.297993 435998 pytest ERROR injector.py:307: Cannot grab /dev/input/event10, it is possibly in use 13:36:26.641136 435998 pytest ERROR injector.py:308: 13:36:26.649678 435078 pytest INFO injector.py:188: Stopping injecting keycodes for group "Foo Device 2" 13:36:26.652806 435998 pytest WARNING context.py:87: Not forward_devices set 13:36:26.660830 435998 pytest WARNING context.py:90: Not source_devices set 13:36:27.057911 435078 pytest DEBUG injector.py:173: Injector state of "Foo Device 2", "None": InjectorState.STARTING 13:36:27.064279 435998 pytest DEBUG combination_handler.py:56: {'input_combination': ) at 0xffffff935fe8a0>, 'target_uinput': 'keyboard'} 13:36:27.109056 435998 pytest DEBUG mapping_parser.py:133: event-pipeline with entry point: KEY_9 (1, 10, '698702013ccc49179d9669854f6c2b69') 13:36:27.660593 435998 pytest DEBUG logger.py:77: ) at 0xffffff935fe490>" ((1, 10, '698702013ccc49179d9669854f6c2b69'),) at 0xffffff95fb7d10> 13:36:27.669193 435998 pytest DEBUG logger.py:77: 13:36:27.676841 435998 pytest DEBUG logger.py:77: 'maps to: KEY_A (1, 30) on keyboard' 13:36:27.687378 435998 pytest DEBUG context.py:110: Adding NotifyCallback for (1, 10, '698702013ccc49179d9669854f6c2b69') 13:36:28.046911 435998 pytest ERROR injector.py:423: Did not grab any device ------------------------------ Captured log call ------------------------------- WARNING input-remapper:input_config.py:272 No origin_hash set for {'type': 1, 'code': 10} WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set WARNING input-remapper:input_config.py:272 No origin_hash set for {'type': 1, 'code': 10} DEBUG input-remapper:combination_handler.py:56 {'input_combination': ) at 0xffffff935fed00>, 'target_uinput': 'keyboard'} DEBUG input-remapper:mapping_parser.py:133 event-pipeline with entry point: KEY_9 (1, 10, None) DEBUG input-remapper:logger.py:77 ) at 0xffffff960d3110>" ((1, 10, None),) at 0xffffff9364e360> DEBUG input-remapper:logger.py:77 DEBUG input-remapper:logger.py:77 'maps to: KEY_A (1, 30) on keyboard' DEBUG input-remapper:context.py:110 Adding NotifyCallback for (1, 10, None) DEBUG input-remapper:injector.py:304 Failed attempts to grab /dev/input/event10: 1 DEBUG input-remapper:injector.py:304 Failed attempts to grab /dev/input/event10: 2 DEBUG input-remapper:injector.py:304 Failed attempts to grab /dev/input/event10: 3 DEBUG input-remapper:injector.py:304 Failed attempts to grab /dev/input/event10: 4 DEBUG input-remapper:injector.py:304 Failed attempts to grab /dev/input/event10: 5 DEBUG input-remapper:injector.py:304 Failed attempts to grab /dev/input/event10: 6 DEBUG input-remapper:injector.py:304 Failed attempts to grab /dev/input/event10: 7 DEBUG input-remapper:injector.py:304 Failed attempts to grab /dev/input/event10: 8 DEBUG input-remapper:injector.py:304 Failed attempts to grab /dev/input/event10: 9 DEBUG input-remapper:injector.py:304 Failed attempts to grab /dev/input/event10: 10 ERROR input-remapper:injector.py:307 Cannot grab /dev/input/event10, it is possibly in use ERROR input-remapper:injector.py:308 DEBUG input-remapper:injector.py:173 Injector state of "Foo Device 2", "None": InjectorState.UNKNOWN DEBUG input-remapper:injector.py:173 Injector state of "Foo Device 2", "None": InjectorState.STARTING WARNING asyncio:base_events.py:1946 Executing ) at /usr/lib64/python3.12/asyncio/base_events.py:180 created at /usr/lib64/python3.12/asyncio/events.py:84> took 0.374 seconds INFO input-remapper:injector.py:188 Stopping injecting keycodes for group "Foo Device 2" DEBUG input-remapper:injector.py:173 Injector state of "Foo Device 2", "None": InjectorState.STARTING WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.355 seconds _______________ ERROR at teardown of TestInjector.test_injector ________________ self = def tearDown(self): if self.injector is not None and self.injector.is_alive(): self.injector.stop_injecting() time.sleep(0.2) > self.assertIn( self.injector.get_state(), (InjectorState.STOPPED, InjectorState.FAILED, InjectorState.NO_GRAB), ) E AssertionError: not found in (, , ) tests/unit/test_injector.py:107: AssertionError ----------------------------- Captured stderr call ----------------------------- Test: Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" Test: Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" 13:38:13.669296 435078 pytest DEBUG parse.py:456: parsing macro k(KEY_Q).k(w) Test: Hash for fixture "/dev/input/event15" "Foo Device bar": "cee831d56755e4bac5b0f5d2fcfd5735" Test: Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" 13:38:15.077366 435078 pytest DEBUG injector.py:173: Injector state of "Foo Device 2", "None": InjectorState.UNKNOWN 13:38:16.113425 435078 pytest DEBUG injector.py:173: Injector state of "Foo Device 2", "None": InjectorState.STARTING 13:38:16.500457 436011 pytest INFO injector.py:394: Starting injecting the preset for "Foo Device 2" 13:38:17.516402 435078 pytest DEBUG injector.py:173: Injector state of "Foo Device 2", "None": InjectorState.STARTING 13:38:19.042525 436011 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 1 13:38:19.126077 436011 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 2 13:38:19.847792 436011 pytest DEBUG injector.py:298: Grab /dev/input/event10 13:38:19.893830 436011 pytest DEBUG injector.py:298: Grab /dev/input/event15 13:38:19.947584 436011 pytest DEBUG parse.py:456: parsing macro k(KEY_Q).k(w) 13:38:20.292912 436011 pytest DEBUG parse.py:244: calls k with KEY_Q 13:38:20.310099 436011 pytest DEBUG parse.py:244: string KEY_Q 13:38:20.320602 436011 pytest DEBUG parse.py:244: add call to k with ['KEY_Q'], {} 13:38:20.860644 436011 pytest DEBUG parse.py:244: followed by k(w) 13:38:20.869091 436011 pytest DEBUG parse.py:244: calls k with w 13:38:20.877289 436011 pytest DEBUG parse.py:244: string w 13:38:20.886624 436011 pytest DEBUG parse.py:244: add call to k with ['w'], {} 13:38:20.902274 435078 pytest INFO injector.py:188: Stopping injecting keycodes for group "Foo Device 2" 13:38:21.268508 436011 pytest DEBUG combination_handler.py:56: {'input_combination': , ) at 0xffffff9344ba70>, 'target_uinput': 'keyboard'} 13:38:21.273452 435078 pytest DEBUG injector.py:173: Injector state of "Foo Device 2", "None": InjectorState.STARTING 13:38:21.304192 436011 pytest DEBUG combination_handler.py:56: {'input_combination': ) at 0xffffff9344bac0>, 'target_uinput': 'keyboard'} 13:38:21.674442 436011 pytest DEBUG mapping_parser.py:133: event-pipeline with entry point: KEY_7 (1, 8, '698702013ccc49179d9669854f6c2b69') 13:38:21.691812 436011 pytest DEBUG logger.py:77: , ) at 0xffffff960d22b0>" ((1, 8, '698702013ccc49179d9669854f6c2b69'), (1, 9, '698702013ccc49179d9669854f6c2b69')) at 0xffffff9364c500> 13:38:21.702160 436011 pytest DEBUG logger.py:77: 13:38:21.708375 436011 pytest DEBUG logger.py:77: 'maps to on keyboard' 13:38:21.716456 436011 pytest DEBUG mapping_parser.py:133: event-pipeline with entry point: KEY_8 (1, 9, '698702013ccc49179d9669854f6c2b69') 13:38:21.728401 436011 pytest DEBUG logger.py:77: , ) at 0xffffff960d22b0>" ((1, 8, '698702013ccc49179d9669854f6c2b69'), (1, 9, '698702013ccc49179d9669854f6c2b69')) at 0xffffff9364c500> 13:38:21.736772 436011 pytest DEBUG logger.py:77: 13:38:21.743130 436011 pytest DEBUG logger.py:77: 'maps to on keyboard' 13:38:21.750173 436011 pytest DEBUG mapping_parser.py:133: event-pipeline with entry point: ABS_HAT0X (3, 16, 'cee831d56755e4bac5b0f5d2fcfd5735') 13:38:22.444722 436011 pytest DEBUG logger.py:77: 13:38:22.455093 436011 pytest DEBUG logger.py:77: ) at 0xffffff9363b9d0>" ((3, 16, 'cee831d56755e4bac5b0f5d2fcfd5735'),) at 0xffffff9364c860> 13:38:22.467214 436011 pytest DEBUG logger.py:77: 13:38:22.478541 436011 pytest DEBUG logger.py:77: 'maps to: KEY_RIGHTALT (1, 100) on keyboard' ------------------------------ Captured log call ------------------------------- INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" DEBUG input-remapper:parse.py:456 parsing macro k(KEY_Q).k(w) INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event15" "Foo Device bar": "cee831d56755e4bac5b0f5d2fcfd5735" INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" DEBUG input-remapper:injector.py:173 Injector state of "Foo Device 2", "None": InjectorState.UNKNOWN DEBUG input-remapper:injector.py:173 Injector state of "Foo Device 2", "None": InjectorState.STARTING DEBUG input-remapper:injector.py:173 Injector state of "Foo Device 2", "None": InjectorState.STARTING WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.344 seconds INFO input-remapper:injector.py:188 Stopping injecting keycodes for group "Foo Device 2" DEBUG input-remapper:injector.py:173 Injector state of "Foo Device 2", "None": InjectorState.STARTING --------------------------- Captured stderr teardown --------------------------- 13:38:22.492259 436011 pytest DEBUG context.py:110: Adding NotifyCallback for (1, 8, '698702013ccc49179d9669854f6c2b69') 13:38:22.506837 436011 pytest DEBUG context.py:110: Adding NotifyCallback for (1, 9, '698702013ccc49179d9669854f6c2b69') 13:38:22.516887 436011 pytest DEBUG context.py:110: Adding NotifyCallback for (3, 16, 'cee831d56755e4bac5b0f5d2fcfd5735') 13:38:24.067214 436011 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event10, fd 18 13:38:24.416035 436011 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event15, fd 24 13:38:24.475554 436011 pytest DEBUG injector.py:344: Received close signal 13:38:24.870835 436011 pytest DEBUG event_reader.py:108: read loop stopped 13:38:24.885916 436011 pytest DEBUG key_handler.py:81: resetting key_handler 13:38:24.897846 436011 pytest INFO event_reader.py:207: read loop for /dev/input/event10 stopped 13:38:24.913826 436011 pytest DEBUG event_reader.py:108: read loop stopped 13:38:24.924321 436011 pytest DEBUG key_handler.py:81: resetting key_handler 13:38:25.204710 436011 pytest INFO event_reader.py:207: read loop for /dev/input/event15 stopped 13:38:25.271192 436011 pytest DEBUG injector.py:462: Injector coroutines ended Test: ungrab Foo Device /dev/input/event10 Test: ungrab Foo Device bar /dev/input/event15 ___________________ ERROR at teardown of TestMacros.test_add ___________________ self = def tearDown(self): self.result = [] > quick_cleanup() tests/unit/test_macros.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ log = True def quick_cleanup(log=True): """Reset the applications state.""" # Reminder: before patches are applied in test.py, no inputremapper module # may be imported. So tests.lib imports them just-in-time in functions instead. from inputremapper.injection.macros.macro import macro_variables from inputremapper.configs.global_config import global_config from inputremapper.configs.system_mapping import system_mapping from inputremapper.gui.utils import debounce_manager from inputremapper.configs.paths import get_config_path from inputremapper.injection.global_uinputs import global_uinputs from tests.lib.global_uinputs import reset_global_uinputs_for_service if log: logger.info("Quick cleanup...") debounce_manager.stop_all() for device in list(pending_events.keys()): try: while pending_events[device][1].poll(): pending_events[device][1].recv() except (UnpicklingError, EOFError): pass # setup new pipes for the next test pending_events[device][1].close() pending_events[device][0].close() del pending_events[device] setup_pipe(device) try: if asyncio.get_event_loop().is_running(): for task in asyncio.all_tasks(): task.cancel() except RuntimeError: # happens when the event loop disappears for magical reasons # create a fresh event loop asyncio.set_event_loop(asyncio.new_event_loop()) if macro_variables.process is not None and not macro_variables.process.is_alive(): # nothing should stop the process during runtime, if it has been started by # the injector once raise AssertionError("the SharedDict manager is not running anymore") if macro_variables.process is not None: macro_variables._stop() join_children() macro_variables.start() if os.path.exists(tmp): shutil.rmtree(tmp) global_config.path = os.path.join(get_config_path(), "config.json") global_config.clear_config() global_config._save_config() system_mapping.populate() clear_write_history() for name in list(uinputs.keys()): del uinputs[name] # for device in list(active_macros.keys()): # del active_macros[device] # for device in list(unreleased.keys()): # del unreleased[device] fixtures.reset() os.environ.update(environ_copy) for device in list(os.environ.keys()): if device not in environ_copy: del os.environ[device] for _, pipe in pending_events.values(): assert not pipe.poll() > assert macro_variables.is_alive(1) E AssertionError tests/lib/cleanup.py:152: AssertionError ----------------------------- Captured stderr call ----------------------------- 13:43:51.696800 435078 pytest WARNING context.py:87: Not forward_devices set 13:43:51.717131 435078 pytest WARNING context.py:90: Not source_devices set 13:43:52.702742 435078 pytest DEBUG parse.py:456: parsing macro set(a, 1).add(a, 1) 13:43:53.260044 435078 pytest DEBUG parse.py:244: calls set with a,1 13:43:53.286362 435078 pytest DEBUG parse.py:244: string a 13:43:53.306286 435078 pytest DEBUG parse.py:244: number 1 13:43:53.326880 435078 pytest DEBUG parse.py:244: add call to set with ['a', 1], {} 13:43:54.005281 435078 pytest DEBUG parse.py:244: followed by add(a,1) 13:43:54.026039 435078 pytest DEBUG parse.py:244: calls add with a,1 13:43:54.044710 435078 pytest DEBUG parse.py:244: string a 13:43:54.690674 435078 pytest DEBUG parse.py:244: number 1 13:43:54.719618 435078 pytest DEBUG parse.py:244: add call to add with ['a', 1], {} 13:43:54.758358 435078 pytest DEBUG macro.py:533: "a" set to "1" 13:43:55.086486 436032 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'a', 1) 13:43:55.114641 435078 pytest ERROR shared_dict.py:118: select.select timed out 13:43:55.138091 435078 pytest DEBUG macro.py:546: "a" initialized with 0 13:43:55.139023 436032 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'a') 13:43:55.657329 435078 pytest DEBUG macro.py:563: "a" += "1" 13:43:55.665959 436032 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'a', 0) 13:43:55.692111 436032 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'a') 13:43:55.717387 436032 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'a', 2) 13:43:55.744288 436032 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'a') Test: Quick cleanup... 13:43:57.096670 436032 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 13:43:58.701861 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 13:43:59.722115 436033 pytest DEBUG shared_dict.py:63: SharedDict process started 13:43:59.732355 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 13:44:00.707322 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 13:44:01.121321 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 13:44:02.853343 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:44:02.904603 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:44:07.067055 436033 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(a, 1).add(a, 1) DEBUG input-remapper:parse.py:244 calls set with a,1 DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 number 1 DEBUG input-remapper:parse.py:244 add call to set with ['a', 1], {} DEBUG input-remapper:parse.py:244 followed by add(a,1) DEBUG input-remapper:parse.py:244 calls add with a,1 DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 number 1 DEBUG input-remapper:parse.py:244 add call to add with ['a', 1], {} DEBUG input-remapper:macro.py:533 "a" set to "1" ERROR input-remapper:shared_dict.py:118 select.select timed out DEBUG input-remapper:macro.py:546 "a" initialized with 0 DEBUG input-remapper:macro.py:563 "a" += "1" WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('0 != 2') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 3.032 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" ________________ ERROR at teardown of TestMacros.test_hold_keys ________________ self = def tearDown(self): self.result = [] > quick_cleanup() tests/unit/test_macros.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ log = True def quick_cleanup(log=True): """Reset the applications state.""" # Reminder: before patches are applied in test.py, no inputremapper module # may be imported. So tests.lib imports them just-in-time in functions instead. from inputremapper.injection.macros.macro import macro_variables from inputremapper.configs.global_config import global_config from inputremapper.configs.system_mapping import system_mapping from inputremapper.gui.utils import debounce_manager from inputremapper.configs.paths import get_config_path from inputremapper.injection.global_uinputs import global_uinputs from tests.lib.global_uinputs import reset_global_uinputs_for_service if log: logger.info("Quick cleanup...") debounce_manager.stop_all() for device in list(pending_events.keys()): try: while pending_events[device][1].poll(): pending_events[device][1].recv() except (UnpicklingError, EOFError): pass # setup new pipes for the next test pending_events[device][1].close() pending_events[device][0].close() del pending_events[device] setup_pipe(device) try: if asyncio.get_event_loop().is_running(): for task in asyncio.all_tasks(): task.cancel() except RuntimeError: # happens when the event loop disappears for magical reasons # create a fresh event loop asyncio.set_event_loop(asyncio.new_event_loop()) if macro_variables.process is not None and not macro_variables.process.is_alive(): # nothing should stop the process during runtime, if it has been started by # the injector once raise AssertionError("the SharedDict manager is not running anymore") if macro_variables.process is not None: macro_variables._stop() join_children() macro_variables.start() if os.path.exists(tmp): shutil.rmtree(tmp) global_config.path = os.path.join(get_config_path(), "config.json") global_config.clear_config() global_config._save_config() system_mapping.populate() clear_write_history() for name in list(uinputs.keys()): del uinputs[name] # for device in list(active_macros.keys()): # del active_macros[device] # for device in list(unreleased.keys()): # del unreleased[device] fixtures.reset() os.environ.update(environ_copy) for device in list(os.environ.keys()): if device not in environ_copy: del os.environ[device] for _, pipe in pending_events.values(): assert not pipe.poll() > assert macro_variables.is_alive(1) E AssertionError tests/lib/cleanup.py:152: AssertionError ----------------------------- Captured stderr call ----------------------------- 13:52:11.080945 435078 pytest WARNING context.py:87: Not forward_devices set 13:52:11.100500 435078 pytest WARNING context.py:90: Not source_devices set 13:52:11.684287 435078 pytest DEBUG parse.py:456: parsing macro set(foo, b).hold_keys(a, $foo, c) 13:52:12.082541 435078 pytest DEBUG parse.py:244: calls set with foo,b 13:52:12.124824 435078 pytest DEBUG parse.py:244: string foo 13:52:12.146254 435078 pytest DEBUG parse.py:244: string b 13:52:12.485803 435078 pytest DEBUG parse.py:244: add call to set with ['foo', 'b'], {} 13:52:12.524714 435078 pytest DEBUG parse.py:244: followed by hold_keys(a,$foo,c) 13:52:13.080919 435078 pytest DEBUG parse.py:244: calls hold_keys with a,$foo,c 13:52:13.102886 435078 pytest DEBUG parse.py:244: string a 13:52:13.126503 435078 pytest DEBUG parse.py:244: string c 13:52:13.147321 435078 pytest DEBUG parse.py:244: add call to hold_keys with ['a', , 'c'], {} 13:52:14.467042 435078 pytest DEBUG macro.py:533: "foo" set to "b" 13:52:14.497189 436053 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'foo', 'b') 13:52:14.520353 435078 pytest DEBUG macro.py:155: "" is "pong" 13:52:14.532097 436053 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'foo') Test: Quick cleanup... 13:52:17.549388 436053 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 13:52:20.336561 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 13:52:21.133225 436054 pytest DEBUG shared_dict.py:63: SharedDict process started 13:52:21.136053 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 13:52:22.106272 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 13:52:22.532178 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 13:52:24.269406 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:52:24.703932 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:52:27.892196 436054 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(foo, b).hold_keys(a, $foo, c) DEBUG input-remapper:parse.py:244 calls set with foo,b DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 string b DEBUG input-remapper:parse.py:244 add call to set with ['foo', 'b'], {} DEBUG input-remapper:parse.py:244 followed by hold_keys(a,$foo,c) DEBUG input-remapper:parse.py:244 calls hold_keys with a,$foo,c DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 string c DEBUG input-remapper:parse.py:244 add call to hold_keys with ['a', , 'c'], {} WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 2.381 seconds DEBUG input-remapper:macro.py:533 "foo" set to "b" DEBUG input-remapper:macro.py:155 "" is "pong" WARNING asyncio:base_events.py:1946 Executing exception=MacroParsingError('Unknown key "pong"') created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.435 seconds ERROR asyncio:base_events.py:1785 Task exception was never retrieved future: exception=MacroParsingError('Unknown key "pong"') created at /usr/lib64/python3.12/asyncio/tasks.py:685> source_traceback: Object created at (most recent call last): File "/usr/bin/pytest", line 8, in sys.exit(console_main()) File "/usr/lib/python3.12/site-packages/_pytest/config/__init__.py", line 189, in console_main code = main() File "/usr/lib/python3.12/site-packages/_pytest/config/__init__.py", line 166, in main ret: Union[ExitCode, int] = config.hook.pytest_cmdline_main( File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 316, in pytest_cmdline_main return wrap_session(config, _main) File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 269, in wrap_session session.exitstatus = doit(config, session) or 0 File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 323, in _main config.hook.pytest_runtestloop(session=session) File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 348, in pytest_runtestloop item.config.hook.pytest_runtest_protocol(item=item, nextitem=nextitem) File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 114, in pytest_runtest_protocol runtestprotocol(item, nextitem=nextitem) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 133, in runtestprotocol reports.append(call_and_report(item, "call", log)) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 222, in call_and_report call = call_runtest_hook(item, when, **kwds) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 261, in call_runtest_hook return CallInfo.from_call( File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 341, in from_call result: Optional[TResult] = func() File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 262, in lambda: ihook(item=item, **kwds), when=when, reraise=reraise File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 169, in pytest_runtest_call item.runtest() File "/usr/lib/python3.12/site-packages/_pytest/unittest.py", line 314, in runtest self._testcase(result=self) # type: ignore[arg-type] File "/usr/lib64/python3.12/unittest/case.py", line 690, in __call__ return self.run(*args, **kwds) File "/usr/lib64/python3.12/unittest/async_case.py", line 131, in run return super().run(result) File "/usr/lib64/python3.12/unittest/case.py", line 634, in run self._callTestMethod(testMethod) File "/usr/lib64/python3.12/unittest/async_case.py", line 90, in _callTestMethod if self._callMaybeAsync(method) is not None: File "/usr/lib64/python3.12/unittest/async_case.py", line 112, in _callMaybeAsync return self._asyncioRunner.run( File "/usr/lib64/python3.12/asyncio/runners.py", line 118, in run return self._loop.run_until_complete(task) File "/usr/lib64/python3.12/asyncio/base_events.py", line 651, in run_until_complete self.run_forever() File "/usr/lib64/python3.12/asyncio/base_events.py", line 618, in run_forever self._run_once() File "/usr/lib64/python3.12/asyncio/base_events.py", line 1943, in _run_once handle._run() File "/usr/lib64/python3.12/asyncio/events.py", line 84, in _run self._context.run(self._callback, *self._args) File "/builddir/build/BUILD/input-remapper-2.0.1/tests/unit/test_macros.py", line 636, in test_hold_keys asyncio.ensure_future(macro.run(self.handler)) File "/usr/lib64/python3.12/asyncio/tasks.py", line 685, in ensure_future return loop.create_task(coro_or_future) Traceback (most recent call last): File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py", line 267, in run await coroutine File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py", line 423, in task codes = [self._type_check_symbol(symbol) for symbol in resolved_symbols] ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py", line 708, in _type_check_symbol raise MacroParsingError(msg=f'Unknown key "{symbol}"') inputremapper.configs.validation_errors.MacroParsingError: Unknown key "pong" WARNING asyncio:base_events.py:1946 Executing , None) at /usr/lib64/python3.12/asyncio/futures.py:311 created at /usr/lib64/python3.12/asyncio/tasks.py:651> took 0.319 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" ______________ ERROR at teardown of TestMacros.test_hold_variable ______________ self = def tearDown(self): self.result = [] > quick_cleanup() tests/unit/test_macros.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ log = True def quick_cleanup(log=True): """Reset the applications state.""" # Reminder: before patches are applied in test.py, no inputremapper module # may be imported. So tests.lib imports them just-in-time in functions instead. from inputremapper.injection.macros.macro import macro_variables from inputremapper.configs.global_config import global_config from inputremapper.configs.system_mapping import system_mapping from inputremapper.gui.utils import debounce_manager from inputremapper.configs.paths import get_config_path from inputremapper.injection.global_uinputs import global_uinputs from tests.lib.global_uinputs import reset_global_uinputs_for_service if log: logger.info("Quick cleanup...") debounce_manager.stop_all() for device in list(pending_events.keys()): try: while pending_events[device][1].poll(): pending_events[device][1].recv() except (UnpicklingError, EOFError): pass # setup new pipes for the next test pending_events[device][1].close() pending_events[device][0].close() del pending_events[device] setup_pipe(device) try: if asyncio.get_event_loop().is_running(): for task in asyncio.all_tasks(): task.cancel() except RuntimeError: # happens when the event loop disappears for magical reasons # create a fresh event loop asyncio.set_event_loop(asyncio.new_event_loop()) if macro_variables.process is not None and not macro_variables.process.is_alive(): # nothing should stop the process during runtime, if it has been started by # the injector once raise AssertionError("the SharedDict manager is not running anymore") if macro_variables.process is not None: macro_variables._stop() join_children() macro_variables.start() if os.path.exists(tmp): shutil.rmtree(tmp) global_config.path = os.path.join(get_config_path(), "config.json") global_config.clear_config() global_config._save_config() system_mapping.populate() clear_write_history() for name in list(uinputs.keys()): del uinputs[name] # for device in list(active_macros.keys()): # del active_macros[device] # for device in list(unreleased.keys()): # del unreleased[device] fixtures.reset() os.environ.update(environ_copy) for device in list(os.environ.keys()): if device not in environ_copy: del os.environ[device] for _, pipe in pending_events.values(): assert not pipe.poll() > assert macro_variables.is_alive(1) E AssertionError tests/lib/cleanup.py:152: AssertionError ----------------------------- Captured stderr call ----------------------------- 13:53:24.144518 435078 pytest WARNING context.py:87: Not forward_devices set 13:53:24.691478 435078 pytest WARNING context.py:90: Not source_devices set 13:53:25.683704 435078 pytest DEBUG parse.py:456: parsing macro set(foo, a).hold($foo) 13:53:25.710938 435078 pytest DEBUG parse.py:244: calls set with foo,a 13:53:26.275389 435078 pytest DEBUG parse.py:244: string foo 13:53:26.325564 435078 pytest DEBUG parse.py:244: string a 13:53:26.366743 435078 pytest DEBUG parse.py:244: add call to set with ['foo', 'a'], {} 13:53:26.708795 435078 pytest DEBUG parse.py:244: followed by hold($foo) 13:53:27.288090 435078 pytest DEBUG parse.py:244: calls hold with $foo 13:53:27.342294 435078 pytest DEBUG parse.py:244: add call to hold with [], {} 13:53:27.897313 435078 pytest DEBUG macro.py:533: "foo" set to "a" 13:53:27.956799 436054 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'foo', 'a') 13:53:28.296402 435078 pytest DEBUG macro.py:155: "" is "pong" 13:53:28.299718 436054 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'foo') Test: Quick cleanup... 13:53:29.906810 436054 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 13:53:32.555836 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 13:53:34.059627 436057 pytest DEBUG shared_dict.py:63: SharedDict process started 13:53:34.060556 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 13:53:35.718731 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 13:53:35.764253 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 13:53:39.069866 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:53:39.125707 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:53:42.739877 436057 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(foo, a).hold($foo) DEBUG input-remapper:parse.py:244 calls set with foo,a DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 add call to set with ['foo', 'a'], {} DEBUG input-remapper:parse.py:244 followed by hold($foo) DEBUG input-remapper:parse.py:244 calls hold with $foo DEBUG input-remapper:parse.py:244 add call to hold with [], {} DEBUG input-remapper:macro.py:533 "foo" set to "a" DEBUG input-remapper:macro.py:155 "" is "pong" WARNING asyncio:base_events.py:1946 Executing exception=MacroParsingError('Unknown key "pong"') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 2.684 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" ___________________ ERROR at teardown of TestMacros.test_key ___________________ self = def tearDown(self): self.result = [] > quick_cleanup() tests/unit/test_macros.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ log = True def quick_cleanup(log=True): """Reset the applications state.""" # Reminder: before patches are applied in test.py, no inputremapper module # may be imported. So tests.lib imports them just-in-time in functions instead. from inputremapper.injection.macros.macro import macro_variables from inputremapper.configs.global_config import global_config from inputremapper.configs.system_mapping import system_mapping from inputremapper.gui.utils import debounce_manager from inputremapper.configs.paths import get_config_path from inputremapper.injection.global_uinputs import global_uinputs from tests.lib.global_uinputs import reset_global_uinputs_for_service if log: logger.info("Quick cleanup...") debounce_manager.stop_all() for device in list(pending_events.keys()): try: while pending_events[device][1].poll(): pending_events[device][1].recv() except (UnpicklingError, EOFError): pass # setup new pipes for the next test pending_events[device][1].close() pending_events[device][0].close() del pending_events[device] setup_pipe(device) try: if asyncio.get_event_loop().is_running(): for task in asyncio.all_tasks(): task.cancel() except RuntimeError: # happens when the event loop disappears for magical reasons # create a fresh event loop asyncio.set_event_loop(asyncio.new_event_loop()) if macro_variables.process is not None and not macro_variables.process.is_alive(): # nothing should stop the process during runtime, if it has been started by # the injector once raise AssertionError("the SharedDict manager is not running anymore") if macro_variables.process is not None: macro_variables._stop() join_children() macro_variables.start() if os.path.exists(tmp): shutil.rmtree(tmp) global_config.path = os.path.join(get_config_path(), "config.json") global_config.clear_config() global_config._save_config() system_mapping.populate() clear_write_history() for name in list(uinputs.keys()): del uinputs[name] # for device in list(active_macros.keys()): # del active_macros[device] # for device in list(unreleased.keys()): # del unreleased[device] fixtures.reset() os.environ.update(environ_copy) for device in list(os.environ.keys()): if device not in environ_copy: del os.environ[device] for _, pipe in pending_events.values(): assert not pipe.poll() > assert macro_variables.is_alive(1) E AssertionError tests/lib/cleanup.py:152: AssertionError ----------------------------- Captured stderr call ----------------------------- 13:56:06.513235 435078 pytest WARNING context.py:87: Not forward_devices set 13:56:06.533075 435078 pytest WARNING context.py:90: Not source_devices set 13:56:07.356595 435078 pytest DEBUG parse.py:456: parsing macro set(foo, b).key($foo).key(a) 13:56:07.717299 435078 pytest DEBUG parse.py:244: calls set with foo,b 13:56:07.746213 435078 pytest DEBUG parse.py:244: string foo 13:56:08.104618 435078 pytest DEBUG parse.py:244: string b 13:56:08.665985 435078 pytest DEBUG parse.py:244: add call to set with ['foo', 'b'], {} 13:56:08.717215 435078 pytest DEBUG parse.py:244: followed by key($foo).key(a) 13:56:08.739710 435078 pytest DEBUG parse.py:244: calls key with $foo 13:56:09.315069 435078 pytest DEBUG parse.py:244: add call to key with [], {} 13:56:09.351515 435078 pytest DEBUG parse.py:244: followed by key(a) 13:56:09.875924 435078 pytest DEBUG parse.py:244: calls key with a 13:56:09.918836 435078 pytest DEBUG parse.py:244: string a 13:56:09.952059 435078 pytest DEBUG parse.py:244: add call to key with ['a'], {} 13:56:10.284409 435078 pytest DEBUG macro.py:533: "foo" set to "b" 13:56:10.667346 436061 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'foo', 'b') 13:56:10.673230 435078 pytest DEBUG macro.py:155: "" is "pong" 13:56:10.700112 436061 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'foo') Test: Quick cleanup... 13:56:11.555689 436061 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 13:56:12.845180 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 13:56:14.160479 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 13:56:14.682897 436062 pytest DEBUG shared_dict.py:63: SharedDict process started 13:56:15.314406 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 13:56:15.688786 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 13:56:17.537625 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:56:18.101475 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:56:20.982711 436062 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(foo, b).key($foo).key(a) DEBUG input-remapper:parse.py:244 calls set with foo,b DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 string b DEBUG input-remapper:parse.py:244 add call to set with ['foo', 'b'], {} DEBUG input-remapper:parse.py:244 followed by key($foo).key(a) DEBUG input-remapper:parse.py:244 calls key with $foo DEBUG input-remapper:parse.py:244 add call to key with [], {} DEBUG input-remapper:parse.py:244 followed by key(a) DEBUG input-remapper:parse.py:244 calls key with a DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 add call to key with ['a'], {} DEBUG input-remapper:macro.py:533 "foo" set to "b" DEBUG input-remapper:macro.py:155 "" is "pong" WARNING asyncio:base_events.py:1946 Executing exception=MacroParsingError('Unknown key "pong"') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 3.367 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" _______________ ERROR at teardown of TestMacros.test_key_down_up _______________ self = def tearDown(self): self.result = [] > quick_cleanup() tests/unit/test_macros.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ log = True def quick_cleanup(log=True): """Reset the applications state.""" # Reminder: before patches are applied in test.py, no inputremapper module # may be imported. So tests.lib imports them just-in-time in functions instead. from inputremapper.injection.macros.macro import macro_variables from inputremapper.configs.global_config import global_config from inputremapper.configs.system_mapping import system_mapping from inputremapper.gui.utils import debounce_manager from inputremapper.configs.paths import get_config_path from inputremapper.injection.global_uinputs import global_uinputs from tests.lib.global_uinputs import reset_global_uinputs_for_service if log: logger.info("Quick cleanup...") debounce_manager.stop_all() for device in list(pending_events.keys()): try: while pending_events[device][1].poll(): pending_events[device][1].recv() except (UnpicklingError, EOFError): pass # setup new pipes for the next test pending_events[device][1].close() pending_events[device][0].close() del pending_events[device] setup_pipe(device) try: if asyncio.get_event_loop().is_running(): for task in asyncio.all_tasks(): task.cancel() except RuntimeError: # happens when the event loop disappears for magical reasons # create a fresh event loop asyncio.set_event_loop(asyncio.new_event_loop()) if macro_variables.process is not None and not macro_variables.process.is_alive(): # nothing should stop the process during runtime, if it has been started by # the injector once raise AssertionError("the SharedDict manager is not running anymore") if macro_variables.process is not None: macro_variables._stop() join_children() macro_variables.start() if os.path.exists(tmp): shutil.rmtree(tmp) global_config.path = os.path.join(get_config_path(), "config.json") global_config.clear_config() global_config._save_config() system_mapping.populate() clear_write_history() for name in list(uinputs.keys()): del uinputs[name] # for device in list(active_macros.keys()): # del active_macros[device] # for device in list(unreleased.keys()): # del unreleased[device] fixtures.reset() os.environ.update(environ_copy) for device in list(os.environ.keys()): if device not in environ_copy: del os.environ[device] for _, pipe in pending_events.values(): assert not pipe.poll() > assert macro_variables.is_alive(1) E AssertionError tests/lib/cleanup.py:152: AssertionError ----------------------------- Captured stderr call ----------------------------- 13:57:30.735816 435078 pytest WARNING context.py:87: Not forward_devices set 13:57:31.076389 435078 pytest WARNING context.py:90: Not source_devices set 13:57:31.687158 435078 pytest DEBUG parse.py:456: parsing macro set(foo, b).key_down($foo).key_up($foo).key_up(a).key_down(a) 13:57:31.717247 435078 pytest DEBUG parse.py:244: calls set with foo,b 13:57:31.738893 435078 pytest DEBUG parse.py:244: string foo 13:57:31.960696 435078 pytest DEBUG parse.py:244: string b 13:57:32.279460 435078 pytest DEBUG parse.py:244: add call to set with ['foo', 'b'], {} 13:57:32.556237 435078 pytest DEBUG parse.py:244: followed by key_down($foo).key_up($foo).key_up(a).key_down(a) 13:57:32.579376 435078 pytest DEBUG parse.py:244: calls key_down with $foo 13:57:32.602414 435078 pytest DEBUG parse.py:244: add call to key_down with [], {} 13:57:33.083751 435078 pytest DEBUG parse.py:244: followed by key_up($foo).key_up(a).key_down(a) 13:57:33.122542 435078 pytest DEBUG parse.py:244: calls key_up with $foo 13:57:33.160709 435078 pytest DEBUG parse.py:244: add call to key_up with [], {} 13:57:33.483761 435078 pytest DEBUG parse.py:244: followed by key_up(a).key_down(a) 13:57:33.513945 435078 pytest DEBUG parse.py:244: calls key_up with a 13:57:33.872927 435078 pytest DEBUG parse.py:244: string a 13:57:33.896717 435078 pytest DEBUG parse.py:244: add call to key_up with ['a'], {} 13:57:33.935504 435078 pytest DEBUG parse.py:244: followed by key_down(a) 13:57:34.480379 435078 pytest DEBUG parse.py:244: calls key_down with a 13:57:34.508232 435078 pytest DEBUG parse.py:244: string a 13:57:34.534559 435078 pytest DEBUG parse.py:244: add call to key_down with ['a'], {} 13:57:34.570414 435078 pytest DEBUG macro.py:533: "foo" set to "b" 13:57:34.887653 436062 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'foo', 'b') 13:57:34.893359 435078 pytest DEBUG macro.py:155: "" is "pong" 13:57:34.947176 436062 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'foo') Test: Quick cleanup... 13:57:36.143594 436062 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 13:57:38.908496 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 13:57:40.670485 436064 pytest DEBUG shared_dict.py:63: SharedDict process started 13:57:40.710652 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 13:57:42.489944 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 13:57:42.893351 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 13:57:46.142802 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:57:46.216959 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:57:49.095071 436064 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(foo, b).key_down($foo).key_up($foo).key_up(a).key_down(a) DEBUG input-remapper:parse.py:244 calls set with foo,b DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 string b DEBUG input-remapper:parse.py:244 add call to set with ['foo', 'b'], {} DEBUG input-remapper:parse.py:244 followed by key_down($foo).key_up($foo).key_up(a).key_down(a) DEBUG input-remapper:parse.py:244 calls key_down with $foo DEBUG input-remapper:parse.py:244 add call to key_down with [], {} DEBUG input-remapper:parse.py:244 followed by key_up($foo).key_up(a).key_down(a) DEBUG input-remapper:parse.py:244 calls key_up with $foo DEBUG input-remapper:parse.py:244 add call to key_up with [], {} DEBUG input-remapper:parse.py:244 followed by key_up(a).key_down(a) DEBUG input-remapper:parse.py:244 calls key_up with a DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 add call to key_up with ['a'], {} DEBUG input-remapper:parse.py:244 followed by key_down(a) DEBUG input-remapper:parse.py:244 calls key_down with a DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 add call to key_down with ['a'], {} DEBUG input-remapper:macro.py:533 "foo" set to "b" DEBUG input-remapper:macro.py:155 "" is "pong" WARNING asyncio:base_events.py:1946 Executing exception=MacroParsingError('Unknown key "pong"') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 3.253 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" ______________ ERROR at teardown of TestMacros.test_macro_breaks _______________ self = def tearDown(self): self.result = [] > quick_cleanup() tests/unit/test_macros.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ log = True def quick_cleanup(log=True): """Reset the applications state.""" # Reminder: before patches are applied in test.py, no inputremapper module # may be imported. So tests.lib imports them just-in-time in functions instead. from inputremapper.injection.macros.macro import macro_variables from inputremapper.configs.global_config import global_config from inputremapper.configs.system_mapping import system_mapping from inputremapper.gui.utils import debounce_manager from inputremapper.configs.paths import get_config_path from inputremapper.injection.global_uinputs import global_uinputs from tests.lib.global_uinputs import reset_global_uinputs_for_service if log: logger.info("Quick cleanup...") debounce_manager.stop_all() for device in list(pending_events.keys()): try: while pending_events[device][1].poll(): pending_events[device][1].recv() except (UnpicklingError, EOFError): pass # setup new pipes for the next test pending_events[device][1].close() pending_events[device][0].close() del pending_events[device] setup_pipe(device) try: if asyncio.get_event_loop().is_running(): for task in asyncio.all_tasks(): task.cancel() except RuntimeError: # happens when the event loop disappears for magical reasons # create a fresh event loop asyncio.set_event_loop(asyncio.new_event_loop()) if macro_variables.process is not None and not macro_variables.process.is_alive(): # nothing should stop the process during runtime, if it has been started by # the injector once raise AssertionError("the SharedDict manager is not running anymore") if macro_variables.process is not None: macro_variables._stop() join_children() macro_variables.start() if os.path.exists(tmp): shutil.rmtree(tmp) global_config.path = os.path.join(get_config_path(), "config.json") global_config.clear_config() global_config._save_config() system_mapping.populate() clear_write_history() for name in list(uinputs.keys()): del uinputs[name] # for device in list(active_macros.keys()): # del active_macros[device] # for device in list(unreleased.keys()): # del unreleased[device] fixtures.reset() os.environ.update(environ_copy) for device in list(os.environ.keys()): if device not in environ_copy: del os.environ[device] for _, pipe in pending_events.values(): assert not pipe.poll() > assert macro_variables.is_alive(1) E AssertionError tests/lib/cleanup.py:152: AssertionError ----------------------------- Captured stderr call ----------------------------- 13:58:52.581228 435078 pytest WARNING context.py:87: Not forward_devices set 13:58:52.893693 435078 pytest WARNING context.py:90: Not source_devices set 13:58:53.707943 435078 pytest DEBUG parse.py:456: parsing macro set(a, "foo").repeat($a, key(KEY_A)).key(KEY_B) 13:58:53.748459 435078 pytest DEBUG parse.py:244: calls set with a,"foo" 13:58:54.092396 435078 pytest DEBUG parse.py:244: string a 13:58:54.114020 435078 pytest DEBUG parse.py:244: string foo 13:58:54.472068 435078 pytest DEBUG parse.py:244: add call to set with ['a', 'foo'], {} 13:58:54.511927 435078 pytest DEBUG parse.py:244: followed by repeat($a,key(KEY_A)).key(KEY_B) 13:58:54.533776 435078 pytest DEBUG parse.py:244: calls repeat with $a,key(KEY_A) 13:58:54.557900 435078 pytest DEBUG parse.py:244: calls key with KEY_A 13:58:55.080781 435078 pytest DEBUG parse.py:244: string KEY_A 13:58:55.115074 435078 pytest DEBUG parse.py:244: add call to key with ['KEY_A'], {} 13:58:55.485352 435078 pytest DEBUG parse.py:244: add call to repeat with [, ], {} 13:58:55.516022 435078 pytest DEBUG parse.py:244: followed by key(KEY_B) 13:58:55.537575 435078 pytest DEBUG parse.py:244: calls key with KEY_B 13:58:55.563154 435078 pytest DEBUG parse.py:244: string KEY_B 13:58:56.072679 435078 pytest DEBUG parse.py:244: add call to key with ['KEY_B'], {} 13:58:56.129587 435078 pytest DEBUG macro.py:533: "a" set to "foo" 13:58:56.686205 435078 pytest DEBUG macro.py:155: "" is "pong" 13:58:56.684968 436064 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'a', 'foo') 13:58:56.725184 436064 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'a') Test: Quick cleanup... 13:58:57.773287 436064 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 13:59:01.303288 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 13:59:02.318658 436067 pytest DEBUG shared_dict.py:63: SharedDict process started 13:59:02.317885 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 13:59:03.157044 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 13:59:03.695482 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 13:59:06.327117 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:59:06.906102 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:59:10.097618 436067 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(a, "foo").repeat($a, key(KEY_A)).key(KEY_B) DEBUG input-remapper:parse.py:244 calls set with a,"foo" DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 add call to set with ['a', 'foo'], {} DEBUG input-remapper:parse.py:244 followed by repeat($a,key(KEY_A)).key(KEY_B) DEBUG input-remapper:parse.py:244 calls repeat with $a,key(KEY_A) DEBUG input-remapper:parse.py:244 calls key with KEY_A DEBUG input-remapper:parse.py:244 string KEY_A DEBUG input-remapper:parse.py:244 add call to key with ['KEY_A'], {} DEBUG input-remapper:parse.py:244 add call to repeat with [, ], {} DEBUG input-remapper:parse.py:244 followed by key(KEY_B) DEBUG input-remapper:parse.py:244 calls key with KEY_B DEBUG input-remapper:parse.py:244 string KEY_B DEBUG input-remapper:parse.py:244 add call to key with ['KEY_B'], {} DEBUG input-remapper:macro.py:533 "a" set to "foo" DEBUG input-remapper:macro.py:155 "" is "pong" WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('\'foo\' not found in "Expected parameter to be one of [], but got pong"') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 3.050 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" _________________ ERROR at teardown of TestMacros.test_modify __________________ self = def tearDown(self): self.result = [] > quick_cleanup() tests/unit/test_macros.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ log = True def quick_cleanup(log=True): """Reset the applications state.""" # Reminder: before patches are applied in test.py, no inputremapper module # may be imported. So tests.lib imports them just-in-time in functions instead. from inputremapper.injection.macros.macro import macro_variables from inputremapper.configs.global_config import global_config from inputremapper.configs.system_mapping import system_mapping from inputremapper.gui.utils import debounce_manager from inputremapper.configs.paths import get_config_path from inputremapper.injection.global_uinputs import global_uinputs from tests.lib.global_uinputs import reset_global_uinputs_for_service if log: logger.info("Quick cleanup...") debounce_manager.stop_all() for device in list(pending_events.keys()): try: while pending_events[device][1].poll(): pending_events[device][1].recv() except (UnpicklingError, EOFError): pass # setup new pipes for the next test pending_events[device][1].close() pending_events[device][0].close() del pending_events[device] setup_pipe(device) try: if asyncio.get_event_loop().is_running(): for task in asyncio.all_tasks(): task.cancel() except RuntimeError: # happens when the event loop disappears for magical reasons # create a fresh event loop asyncio.set_event_loop(asyncio.new_event_loop()) if macro_variables.process is not None and not macro_variables.process.is_alive(): # nothing should stop the process during runtime, if it has been started by # the injector once raise AssertionError("the SharedDict manager is not running anymore") if macro_variables.process is not None: macro_variables._stop() join_children() macro_variables.start() if os.path.exists(tmp): shutil.rmtree(tmp) global_config.path = os.path.join(get_config_path(), "config.json") global_config.clear_config() global_config._save_config() system_mapping.populate() clear_write_history() for name in list(uinputs.keys()): del uinputs[name] # for device in list(active_macros.keys()): # del active_macros[device] # for device in list(unreleased.keys()): # del unreleased[device] fixtures.reset() os.environ.update(environ_copy) for device in list(os.environ.keys()): if device not in environ_copy: del os.environ[device] for _, pipe in pending_events.values(): assert not pipe.poll() > assert macro_variables.is_alive(1) E AssertionError tests/lib/cleanup.py:152: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:00:32.553604 435078 pytest WARNING context.py:87: Not forward_devices set 14:00:32.931067 435078 pytest WARNING context.py:90: Not source_devices set 14:00:33.898909 435078 pytest DEBUG parse.py:456: parsing macro set(foo, b).modify($foo, modify(a, key(c))) 14:00:33.936237 435078 pytest DEBUG parse.py:244: calls set with foo,b 14:00:34.315124 435078 pytest DEBUG parse.py:244: string foo 14:00:34.344493 435078 pytest DEBUG parse.py:244: string b 14:00:34.364833 435078 pytest DEBUG parse.py:244: add call to set with ['foo', 'b'], {} 14:00:34.786442 435078 pytest DEBUG parse.py:244: followed by modify($foo,modify(a,key(c))) 14:00:35.292472 435078 pytest DEBUG parse.py:244: calls modify with $foo,modify(a,key(c)) 14:00:35.352123 435078 pytest DEBUG parse.py:244: calls modify with a,key(c) 14:00:35.394208 435078 pytest DEBUG parse.py:244: string a 14:00:35.686353 435078 pytest DEBUG parse.py:244: calls key with c 14:00:35.707523 435078 pytest DEBUG parse.py:244: string c 14:00:35.728039 435078 pytest DEBUG parse.py:244: add call to key with ['c'], {} 14:00:36.277182 435078 pytest DEBUG parse.py:244: add call to modify with ['a', ], {} 14:00:36.342012 435078 pytest DEBUG parse.py:244: add call to modify with [, ], {} 14:00:36.891437 435078 pytest DEBUG macro.py:533: "foo" set to "b" 14:00:36.927631 435078 pytest DEBUG macro.py:155: "" is "pong" 14:00:36.927328 436067 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'foo', 'b') 14:00:36.983454 436067 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'foo') Test: Quick cleanup... 14:00:37.984546 436067 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:00:40.531902 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:00:41.267178 436071 pytest DEBUG shared_dict.py:63: SharedDict process started 14:00:41.258328 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:00:42.699048 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:00:43.099046 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:00:45.548496 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:00:46.138712 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:00:49.771460 436071 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(foo, b).modify($foo, modify(a, key(c))) DEBUG input-remapper:parse.py:244 calls set with foo,b DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 string b DEBUG input-remapper:parse.py:244 add call to set with ['foo', 'b'], {} DEBUG input-remapper:parse.py:244 followed by modify($foo,modify(a,key(c))) DEBUG input-remapper:parse.py:244 calls modify with $foo,modify(a,key(c)) DEBUG input-remapper:parse.py:244 calls modify with a,key(c) DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 calls key with c DEBUG input-remapper:parse.py:244 string c DEBUG input-remapper:parse.py:244 add call to key with ['c'], {} DEBUG input-remapper:parse.py:244 add call to modify with ['a', ], {} DEBUG input-remapper:parse.py:244 add call to modify with [, ], {} DEBUG input-remapper:macro.py:533 "foo" set to "b" DEBUG input-remapper:macro.py:155 "" is "pong" WARNING asyncio:base_events.py:1946 Executing exception=MacroParsingError('Unknown key "pong"') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 3.068 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.398 seconds ______ ERROR at teardown of TestMacros.test_multiline_macro_and_comments _______ self = def tearDown(self): self.result = [] > quick_cleanup() tests/unit/test_macros.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ log = True def quick_cleanup(log=True): """Reset the applications state.""" # Reminder: before patches are applied in test.py, no inputremapper module # may be imported. So tests.lib imports them just-in-time in functions instead. from inputremapper.injection.macros.macro import macro_variables from inputremapper.configs.global_config import global_config from inputremapper.configs.system_mapping import system_mapping from inputremapper.gui.utils import debounce_manager from inputremapper.configs.paths import get_config_path from inputremapper.injection.global_uinputs import global_uinputs from tests.lib.global_uinputs import reset_global_uinputs_for_service if log: logger.info("Quick cleanup...") debounce_manager.stop_all() for device in list(pending_events.keys()): try: while pending_events[device][1].poll(): pending_events[device][1].recv() except (UnpicklingError, EOFError): pass # setup new pipes for the next test pending_events[device][1].close() pending_events[device][0].close() del pending_events[device] setup_pipe(device) try: if asyncio.get_event_loop().is_running(): for task in asyncio.all_tasks(): task.cancel() except RuntimeError: # happens when the event loop disappears for magical reasons # create a fresh event loop asyncio.set_event_loop(asyncio.new_event_loop()) if macro_variables.process is not None and not macro_variables.process.is_alive(): # nothing should stop the process during runtime, if it has been started by # the injector once raise AssertionError("the SharedDict manager is not running anymore") if macro_variables.process is not None: macro_variables._stop() join_children() macro_variables.start() if os.path.exists(tmp): shutil.rmtree(tmp) global_config.path = os.path.join(get_config_path(), "config.json") global_config.clear_config() global_config._save_config() system_mapping.populate() clear_write_history() for name in list(uinputs.keys()): del uinputs[name] # for device in list(active_macros.keys()): # del active_macros[device] # for device in list(unreleased.keys()): # del unreleased[device] fixtures.reset() os.environ.update(environ_copy) for device in list(os.environ.keys()): if device not in environ_copy: del os.environ[device] for _, pipe in pending_events.values(): assert not pipe.poll() > assert macro_variables.is_alive(1) E AssertionError tests/lib/cleanup.py:152: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:02:03.164015 435078 pytest WARNING context.py:87: Not forward_devices set 14:02:03.678394 435078 pytest WARNING context.py:90: Not source_devices set 14:02:04.152983 435078 pytest DEBUG parse.py:456: parsing macro # repeat(1,key(KEY_D)).set(a,"#b") key(KEY_A).# repeat(1,key(KEY_D)).set(a,"#b") key(KEY_B). # repeat(1,key(KEY_D)).set(a,"#b") repeat(# repeat(1,key(KEY_D)).set(a,"#b") 1, # repeat(1,key(KEY_D)).set(a,"#b") key(KEY_C)# repeat(1,key(KEY_D)).set(a,"#b") ). # repeat(1,key(KEY_D)).set(a,"#b") # repeat(1,key(KEY_D)).set(a,"#b") set(a, "#").# repeat(1,key(KEY_D)).set(a,"#b") if_eq($a, "#", key(KEY_E), key(KEY_F)) # repeat(1,key(KEY_D)).set(a,"#b") # repeat(1,key(KEY_D)).set(a,"#b") 14:02:04.708868 435078 pytest DEBUG parse.py:244: calls key with KEY_A 14:02:04.734924 435078 pytest DEBUG parse.py:244: string KEY_A 14:02:05.028440 435078 pytest DEBUG parse.py:244: add call to key with ['KEY_A'], {} 14:02:05.088935 435078 pytest DEBUG parse.py:244: followed by key(KEY_B).repeat(1,key(KEY_C)).set(a,"#").if_eq($a,"#",key(KEY_E),key(KEY_F)) 14:02:05.113537 435078 pytest DEBUG parse.py:244: calls key with KEY_B 14:02:05.138051 435078 pytest DEBUG parse.py:244: string KEY_B 14:02:05.711232 435078 pytest DEBUG parse.py:244: add call to key with ['KEY_B'], {} 14:02:05.748590 435078 pytest DEBUG parse.py:244: followed by repeat(1,key(KEY_C)).set(a,"#").if_eq($a,"#",key(KEY_E),key(KEY_F)) 14:02:06.285031 435078 pytest DEBUG parse.py:244: calls repeat with 1,key(KEY_C) 14:02:06.313865 435078 pytest DEBUG parse.py:244: number 1 14:02:06.338645 435078 pytest DEBUG parse.py:244: calls key with KEY_C 14:02:06.717842 435078 pytest DEBUG parse.py:244: string KEY_C 14:02:06.748691 435078 pytest DEBUG parse.py:244: add call to key with ['KEY_C'], {} 14:02:06.776622 435078 pytest DEBUG parse.py:244: add call to repeat with [1, ], {} 14:02:07.306075 435078 pytest DEBUG parse.py:244: followed by set(a,"#").if_eq($a,"#",key(KEY_E),key(KEY_F)) 14:02:07.328781 435078 pytest DEBUG parse.py:244: calls set with a,"#" 14:02:07.675290 435078 pytest DEBUG parse.py:244: string a 14:02:07.713429 435078 pytest DEBUG parse.py:244: string # 14:02:07.736918 435078 pytest DEBUG parse.py:244: add call to set with ['a', '#'], {} 14:02:07.764051 435078 pytest DEBUG parse.py:244: followed by if_eq($a,"#",key(KEY_E),key(KEY_F)) 14:02:08.086390 435078 pytest DEBUG parse.py:244: calls if_eq with $a,"#",key(KEY_E),key(KEY_F) 14:02:08.118218 435078 pytest DEBUG parse.py:244: string # 14:02:08.493039 435078 pytest DEBUG parse.py:244: calls key with KEY_E 14:02:08.516948 435078 pytest DEBUG parse.py:244: string KEY_E 14:02:08.539116 435078 pytest DEBUG parse.py:244: add call to key with ['KEY_E'], {} 14:02:09.083035 435078 pytest DEBUG parse.py:244: calls key with KEY_F 14:02:09.125923 435078 pytest DEBUG parse.py:244: string KEY_F 14:02:09.157396 435078 pytest DEBUG parse.py:244: add call to key with ['KEY_F'], {} 14:02:09.676250 435078 pytest DEBUG parse.py:244: add call to if_eq with [, '#', , ], {} Test: macro wrote(1, 30, 1) Test: macro wrote(1, 30, 0) Test: macro wrote(1, 48, 1) Test: macro wrote(1, 48, 0) Test: macro wrote(1, 46, 1) Test: macro wrote(1, 46, 0) 14:02:11.789663 435078 pytest DEBUG macro.py:533: "a" set to "#" 14:02:11.823495 435078 pytest DEBUG macro.py:155: "" is "pong" 14:02:11.822455 436071 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'a', '#') Test: macro wrote(1, 33, 1) 14:02:11.846919 436071 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'a') Test: macro wrote(1, 33, 0) Test: Quick cleanup... 14:02:14.917124 436071 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:02:18.412511 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:02:19.741906 436073 pytest DEBUG shared_dict.py:63: SharedDict process started 14:02:19.737816 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:02:20.896056 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:02:20.933576 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:02:25.346349 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:02:25.916140 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:02:28.709359 436073 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro # repeat(1,key(KEY_D)).set(a,"#b") key(KEY_A).# repeat(1,key(KEY_D)).set(a,"#b") key(KEY_B). # repeat(1,key(KEY_D)).set(a,"#b") repeat(# repeat(1,key(KEY_D)).set(a,"#b") 1, # repeat(1,key(KEY_D)).set(a,"#b") key(KEY_C)# repeat(1,key(KEY_D)).set(a,"#b") ). # repeat(1,key(KEY_D)).set(a,"#b") # repeat(1,key(KEY_D)).set(a,"#b") set(a, "#").# repeat(1,key(KEY_D)).set(a,"#b") if_eq($a, "#", key(KEY_E), key(KEY_F)) # repeat(1,key(KEY_D)).set(a,"#b") # repeat(1,key(KEY_D)).set(a,"#b") DEBUG input-remapper:parse.py:244 calls key with KEY_A DEBUG input-remapper:parse.py:244 string KEY_A DEBUG input-remapper:parse.py:244 add call to key with ['KEY_A'], {} DEBUG input-remapper:parse.py:244 followed by key(KEY_B).repeat(1,key(KEY_C)).set(a,"#").if_eq($a,"#",key(KEY_E),key(KEY_F)) DEBUG input-remapper:parse.py:244 calls key with KEY_B DEBUG input-remapper:parse.py:244 string KEY_B DEBUG input-remapper:parse.py:244 add call to key with ['KEY_B'], {} DEBUG input-remapper:parse.py:244 followed by repeat(1,key(KEY_C)).set(a,"#").if_eq($a,"#",key(KEY_E),key(KEY_F)) DEBUG input-remapper:parse.py:244 calls repeat with 1,key(KEY_C) DEBUG input-remapper:parse.py:244 number 1 DEBUG input-remapper:parse.py:244 calls key with KEY_C DEBUG input-remapper:parse.py:244 string KEY_C DEBUG input-remapper:parse.py:244 add call to key with ['KEY_C'], {} DEBUG input-remapper:parse.py:244 add call to repeat with [1, ], {} DEBUG input-remapper:parse.py:244 followed by set(a,"#").if_eq($a,"#",key(KEY_E),key(KEY_F)) DEBUG input-remapper:parse.py:244 calls set with a,"#" DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 string # DEBUG input-remapper:parse.py:244 add call to set with ['a', '#'], {} DEBUG input-remapper:parse.py:244 followed by if_eq($a,"#",key(KEY_E),key(KEY_F)) DEBUG input-remapper:parse.py:244 calls if_eq with $a,"#",key(KEY_E),key(KEY_F) DEBUG input-remapper:parse.py:244 string # DEBUG input-remapper:parse.py:244 calls key with KEY_E DEBUG input-remapper:parse.py:244 string KEY_E DEBUG input-remapper:parse.py:244 add call to key with ['KEY_E'], {} DEBUG input-remapper:parse.py:244 calls key with KEY_F DEBUG input-remapper:parse.py:244 string KEY_F DEBUG input-remapper:parse.py:244 add call to key with ['KEY_F'], {} DEBUG input-remapper:parse.py:244 add call to if_eq with [, '#', , ], {} INFO input-remapper-test:test_macros.py:96 macro wrote(1, 30, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 6.176 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 30, 0) INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 1) INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 0) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.339 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 46, 1) INFO input-remapper-test:test_macros.py:96 macro wrote(1, 46, 0) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.576 seconds DEBUG input-remapper:macro.py:533 "a" set to "#" DEBUG input-remapper:macro.py:155 "" is "pong" INFO input-remapper-test:test_macros.py:96 macro wrote(1, 33, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.345 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 33, 0) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.547 seconds WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('Lists differ: [(1, [28 chars]1), (1, 48, 0), (1, 46, 1), (1, 46, 0), (1, 33, 1), (1, 33, 0)] != [(1, [28 chars]1), (1, 48, 0), (1, 46, 1), (1, 46, 0), (1, 18, 1), (1, 18, 0)]\n\nFirst differing element 6:\n(1, 33, 1)\n(1, 18, 1)\n\n [(1, 30, 1),\n (1, 30, 0),\n (1, 48, 1),\n (1, 48, 0),\n (1, 46, 1),\n (1, 46, 0),\n- (1, 33, 1),\n? ^^\n\n+ (1, 18, 1),\n? ^^\n\n- (1, 33, 0)]\n? ^^\n\n+ (1, 18, 0)]\n? ^^\n') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.510 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" _________________ ERROR at teardown of TestMacros.test_resolve _________________ self = def tearDown(self): self.result = [] > quick_cleanup() tests/unit/test_macros.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ log = True def quick_cleanup(log=True): """Reset the applications state.""" # Reminder: before patches are applied in test.py, no inputremapper module # may be imported. So tests.lib imports them just-in-time in functions instead. from inputremapper.injection.macros.macro import macro_variables from inputremapper.configs.global_config import global_config from inputremapper.configs.system_mapping import system_mapping from inputremapper.gui.utils import debounce_manager from inputremapper.configs.paths import get_config_path from inputremapper.injection.global_uinputs import global_uinputs from tests.lib.global_uinputs import reset_global_uinputs_for_service if log: logger.info("Quick cleanup...") debounce_manager.stop_all() for device in list(pending_events.keys()): try: while pending_events[device][1].poll(): pending_events[device][1].recv() except (UnpicklingError, EOFError): pass # setup new pipes for the next test pending_events[device][1].close() pending_events[device][0].close() del pending_events[device] setup_pipe(device) try: if asyncio.get_event_loop().is_running(): for task in asyncio.all_tasks(): task.cancel() except RuntimeError: # happens when the event loop disappears for magical reasons # create a fresh event loop asyncio.set_event_loop(asyncio.new_event_loop()) if macro_variables.process is not None and not macro_variables.process.is_alive(): # nothing should stop the process during runtime, if it has been started by # the injector once raise AssertionError("the SharedDict manager is not running anymore") if macro_variables.process is not None: macro_variables._stop() join_children() macro_variables.start() if os.path.exists(tmp): shutil.rmtree(tmp) global_config.path = os.path.join(get_config_path(), "config.json") global_config.clear_config() global_config._save_config() system_mapping.populate() clear_write_history() for name in list(uinputs.keys()): del uinputs[name] # for device in list(active_macros.keys()): # del active_macros[device] # for device in list(unreleased.keys()): # del unreleased[device] fixtures.reset() os.environ.update(environ_copy) for device in list(os.environ.keys()): if device not in environ_copy: del os.environ[device] for _, pipe in pending_events.values(): assert not pipe.poll() > assert macro_variables.is_alive(1) E AssertionError tests/lib/cleanup.py:152: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:06:23.117617 435078 pytest WARNING context.py:87: Not forward_devices set 14:06:23.151814 435078 pytest WARNING context.py:90: Not source_devices set 14:06:23.978163 436085 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'a') 14:06:24.507323 435078 pytest DEBUG macro.py:155: "" is "pong" Test: Quick cleanup... 14:06:25.347136 436085 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:06:27.777963 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:06:29.302991 436087 pytest DEBUG shared_dict.py:63: SharedDict process started 14:06:29.302369 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:06:30.288589 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:06:30.326384 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:06:33.153531 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:06:33.695736 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:06:37.309126 436087 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:macro.py:155 "" is "pong" INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.478 seconds ___________________ ERROR at teardown of TestMacros.test_set ___________________ self = def tearDown(self): self.result = [] > quick_cleanup() tests/unit/test_macros.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ log = True def quick_cleanup(log=True): """Reset the applications state.""" # Reminder: before patches are applied in test.py, no inputremapper module # may be imported. So tests.lib imports them just-in-time in functions instead. from inputremapper.injection.macros.macro import macro_variables from inputremapper.configs.global_config import global_config from inputremapper.configs.system_mapping import system_mapping from inputremapper.gui.utils import debounce_manager from inputremapper.configs.paths import get_config_path from inputremapper.injection.global_uinputs import global_uinputs from tests.lib.global_uinputs import reset_global_uinputs_for_service if log: logger.info("Quick cleanup...") debounce_manager.stop_all() for device in list(pending_events.keys()): try: while pending_events[device][1].poll(): pending_events[device][1].recv() except (UnpicklingError, EOFError): pass # setup new pipes for the next test pending_events[device][1].close() pending_events[device][0].close() del pending_events[device] setup_pipe(device) try: if asyncio.get_event_loop().is_running(): for task in asyncio.all_tasks(): task.cancel() except RuntimeError: # happens when the event loop disappears for magical reasons # create a fresh event loop asyncio.set_event_loop(asyncio.new_event_loop()) if macro_variables.process is not None and not macro_variables.process.is_alive(): # nothing should stop the process during runtime, if it has been started by # the injector once raise AssertionError("the SharedDict manager is not running anymore") if macro_variables.process is not None: macro_variables._stop() join_children() macro_variables.start() if os.path.exists(tmp): shutil.rmtree(tmp) global_config.path = os.path.join(get_config_path(), "config.json") global_config.clear_config() global_config._save_config() system_mapping.populate() clear_write_history() for name in list(uinputs.keys()): del uinputs[name] # for device in list(active_macros.keys()): # del active_macros[device] # for device in list(unreleased.keys()): # del unreleased[device] fixtures.reset() os.environ.update(environ_copy) for device in list(os.environ.keys()): if device not in environ_copy: del os.environ[device] for _, pipe in pending_events.values(): assert not pipe.poll() > assert macro_variables.is_alive(1) E AssertionError tests/lib/cleanup.py:152: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:08:32.382764 435078 pytest WARNING context.py:87: Not forward_devices set 14:08:32.705486 435078 pytest WARNING context.py:90: Not source_devices set 14:08:33.184601 435078 pytest DEBUG parse.py:456: parsing macro set(a, "foo") 14:08:33.899942 435078 pytest DEBUG parse.py:244: calls set with a,"foo" 14:08:33.947021 435078 pytest DEBUG parse.py:244: string a 14:08:34.284701 435078 pytest DEBUG parse.py:244: string foo 14:08:34.306900 435078 pytest DEBUG parse.py:244: add call to set with ['a', 'foo'], {} 14:08:34.752001 435078 pytest DEBUG macro.py:533: "a" set to "foo" 14:08:34.781377 436089 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'a', 'foo') 14:08:35.110944 436089 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'a') Test: Quick cleanup... 14:08:36.313280 436089 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:08:39.093217 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:08:40.139016 436091 pytest DEBUG shared_dict.py:63: SharedDict process started 14:08:40.137839 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:08:41.518479 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:08:41.552388 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:08:44.493155 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:08:44.554826 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:08:48.377997 436091 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(a, "foo") DEBUG input-remapper:parse.py:244 calls set with a,"foo" DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 add call to set with ['a', 'foo'], {} DEBUG input-remapper:macro.py:533 "a" set to "foo" WARNING asyncio:base_events.py:1946 Executing exception=AssertionError("'pong' != 'foo'\n- pong\n+ foo\n") created at /usr/lib64/python3.12/asyncio/runners.py:100> took 1.935 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" ___________________ ERROR at teardown of TestIfEq.test_if_eq ___________________ self = def tearDown(self): self.result = [] > quick_cleanup() tests/unit/test_macros.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ log = True def quick_cleanup(log=True): """Reset the applications state.""" # Reminder: before patches are applied in test.py, no inputremapper module # may be imported. So tests.lib imports them just-in-time in functions instead. from inputremapper.injection.macros.macro import macro_variables from inputremapper.configs.global_config import global_config from inputremapper.configs.system_mapping import system_mapping from inputremapper.gui.utils import debounce_manager from inputremapper.configs.paths import get_config_path from inputremapper.injection.global_uinputs import global_uinputs from tests.lib.global_uinputs import reset_global_uinputs_for_service if log: logger.info("Quick cleanup...") debounce_manager.stop_all() for device in list(pending_events.keys()): try: while pending_events[device][1].poll(): pending_events[device][1].recv() except (UnpicklingError, EOFError): pass # setup new pipes for the next test pending_events[device][1].close() pending_events[device][0].close() del pending_events[device] setup_pipe(device) try: if asyncio.get_event_loop().is_running(): for task in asyncio.all_tasks(): task.cancel() except RuntimeError: # happens when the event loop disappears for magical reasons # create a fresh event loop asyncio.set_event_loop(asyncio.new_event_loop()) if macro_variables.process is not None and not macro_variables.process.is_alive(): # nothing should stop the process during runtime, if it has been started by # the injector once raise AssertionError("the SharedDict manager is not running anymore") if macro_variables.process is not None: macro_variables._stop() join_children() macro_variables.start() if os.path.exists(tmp): shutil.rmtree(tmp) global_config.path = os.path.join(get_config_path(), "config.json") global_config.clear_config() global_config._save_config() system_mapping.populate() clear_write_history() for name in list(uinputs.keys()): del uinputs[name] # for device in list(active_macros.keys()): # del active_macros[device] # for device in list(unreleased.keys()): # del unreleased[device] fixtures.reset() os.environ.update(environ_copy) for device in list(os.environ.keys()): if device not in environ_copy: del os.environ[device] for _, pipe in pending_events.values(): assert not pipe.poll() > assert macro_variables.is_alive(1) E AssertionError tests/lib/cleanup.py:152: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:10:42.737698 435078 pytest WARNING context.py:87: Not forward_devices set 14:10:43.010417 435078 pytest WARNING context.py:90: Not source_devices set Test: Testing if_eq(1, 1, key(a), key(b)) 14:10:43.556011 436095 pytest DEBUG shared_dict.py:67: SharedDict got ('clear',) 14:10:43.877916 436095 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'a') Test: Quick cleanup... 14:10:45.375417 436095 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:10:48.188567 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:10:49.103229 436097 pytest DEBUG shared_dict.py:63: SharedDict process started 14:10:49.485219 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:10:50.742314 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:10:50.791551 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:10:53.129704 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:10:53.696404 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:10:56.129671 436097 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set INFO input-remapper-test:test_macros.py:1210 Testing if_eq(1, 1, key(a), key(b)) INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.387 seconds _________ ERROR at teardown of TestIfEq.test_if_eq_runs_multiprocessed _________ self = def tearDown(self): self.result = [] > quick_cleanup() tests/unit/test_macros.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ log = True def quick_cleanup(log=True): """Reset the applications state.""" # Reminder: before patches are applied in test.py, no inputremapper module # may be imported. So tests.lib imports them just-in-time in functions instead. from inputremapper.injection.macros.macro import macro_variables from inputremapper.configs.global_config import global_config from inputremapper.configs.system_mapping import system_mapping from inputremapper.gui.utils import debounce_manager from inputremapper.configs.paths import get_config_path from inputremapper.injection.global_uinputs import global_uinputs from tests.lib.global_uinputs import reset_global_uinputs_for_service if log: logger.info("Quick cleanup...") debounce_manager.stop_all() for device in list(pending_events.keys()): try: while pending_events[device][1].poll(): pending_events[device][1].recv() except (UnpicklingError, EOFError): pass # setup new pipes for the next test pending_events[device][1].close() pending_events[device][0].close() del pending_events[device] setup_pipe(device) try: if asyncio.get_event_loop().is_running(): for task in asyncio.all_tasks(): task.cancel() except RuntimeError: # happens when the event loop disappears for magical reasons # create a fresh event loop asyncio.set_event_loop(asyncio.new_event_loop()) if macro_variables.process is not None and not macro_variables.process.is_alive(): # nothing should stop the process during runtime, if it has been started by # the injector once raise AssertionError("the SharedDict manager is not running anymore") if macro_variables.process is not None: macro_variables._stop() join_children() macro_variables.start() if os.path.exists(tmp): shutil.rmtree(tmp) global_config.path = os.path.join(get_config_path(), "config.json") global_config.clear_config() global_config._save_config() system_mapping.populate() clear_write_history() for name in list(uinputs.keys()): del uinputs[name] # for device in list(active_macros.keys()): # del active_macros[device] # for device in list(unreleased.keys()): # del unreleased[device] fixtures.reset() os.environ.update(environ_copy) for device in list(os.environ.keys()): if device not in environ_copy: del os.environ[device] for _, pipe in pending_events.values(): assert not pipe.poll() > assert macro_variables.is_alive(1) E AssertionError tests/lib/cleanup.py:152: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:11:57.700607 435078 pytest WARNING context.py:87: Not forward_devices set 14:11:57.729341 435078 pytest WARNING context.py:90: Not source_devices set 14:11:58.783987 435078 pytest DEBUG parse.py:456: parsing macro if_eq($foo, 3, key(a), key(b)) 14:11:59.237917 435078 pytest DEBUG parse.py:244: calls if_eq with $foo,3,key(a),key(b) 14:11:59.294561 435078 pytest DEBUG parse.py:244: number 3 14:11:59.698166 435078 pytest DEBUG parse.py:244: calls key with a 14:11:59.719844 435078 pytest DEBUG parse.py:244: string a 14:11:59.738910 435078 pytest DEBUG parse.py:244: add call to key with ['a'], {} 14:12:00.302854 435078 pytest DEBUG parse.py:244: calls key with b 14:12:00.327193 435078 pytest DEBUG parse.py:244: string b 14:12:00.346284 435078 pytest DEBUG parse.py:244: add call to key with ['b'], {} 14:12:00.897693 435078 pytest DEBUG parse.py:244: add call to if_eq with [, 3, , ], {} 14:12:02.171167 436100 pytest DEBUG parse.py:456: parsing macro set(foo, 2) 14:12:02.764825 436100 pytest DEBUG parse.py:244: calls set with foo,2 14:12:03.321612 436100 pytest DEBUG parse.py:244: string foo 14:12:03.354982 436100 pytest DEBUG parse.py:244: number 2 14:12:05.284671 436100 pytest DEBUG parse.py:244: add call to set with ['foo', 2], {} 14:12:05.779700 436100 pytest DEBUG macro.py:533: "foo" set to "2" 14:12:06.126739 436097 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'foo', 2) 14:12:06.920046 436097 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'foo') 14:12:06.931182 435078 pytest DEBUG macro.py:155: "" is "pong" Test: macro wrote(1, 48, 1) Test: macro wrote(1, 48, 0) 14:12:10.917040 436101 pytest DEBUG parse.py:456: parsing macro set(foo, 3) 14:12:11.332172 436101 pytest DEBUG parse.py:244: calls set with foo,3 14:12:11.372759 436101 pytest DEBUG parse.py:244: string foo 14:12:11.893724 436101 pytest DEBUG parse.py:244: number 3 14:12:11.915908 436101 pytest DEBUG parse.py:244: add call to set with ['foo', 3], {} 14:12:12.726247 436101 pytest DEBUG macro.py:533: "foo" set to "3" 14:12:13.116529 436097 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'foo', 3) 14:12:13.567357 436097 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'foo') 14:12:13.574839 435078 pytest DEBUG macro.py:155: "" is "2" Test: macro wrote(1, 48, 1) Test: macro wrote(1, 48, 0) Test: Quick cleanup... 14:12:17.958258 436097 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:12:21.336846 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:12:22.543433 436103 pytest DEBUG shared_dict.py:63: SharedDict process started 14:12:22.543074 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:12:23.557211 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:12:23.960452 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:12:26.701158 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:12:26.755976 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:12:29.747733 436103 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro if_eq($foo, 3, key(a), key(b)) DEBUG input-remapper:parse.py:244 calls if_eq with $foo,3,key(a),key(b) DEBUG input-remapper:parse.py:244 number 3 DEBUG input-remapper:parse.py:244 calls key with a DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 add call to key with ['a'], {} DEBUG input-remapper:parse.py:244 calls key with b DEBUG input-remapper:parse.py:244 string b DEBUG input-remapper:parse.py:244 add call to key with ['b'], {} DEBUG input-remapper:parse.py:244 add call to if_eq with [, 3, , ], {} DEBUG input-remapper:macro.py:155 "" is "pong" INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 8.973 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 0) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.773 seconds DEBUG input-remapper:macro.py:155 "" is "2" INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 5.843 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 0) WARNING asyncio:base_events.py:1946 Executing , None) at /usr/lib64/python3.12/asyncio/futures.py:311 created at /usr/lib64/python3.12/asyncio/tasks.py:651> took 0.338 seconds WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('Lists differ: [(1, 48, 1), (1, 48, 0), (1, 48, 1), (1, 48, 0)] != [(1, 48, 1), (1, 48, 0), (1, 30, 1), (1, 30, 0)]\n\nFirst differing element 2:\n(1, 48, 1)\n(1, 30, 1)\n\n- [(1, 48, 1), (1, 48, 0), (1, 48, 1), (1, 48, 0)]\n? ^^ ^^\n\n+ [(1, 48, 1), (1, 48, 0), (1, 30, 1), (1, 30, 0)]\n? ^^ ^^\n') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.838 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.254 seconds _________________ ERROR at teardown of TestIfEq.test_ifeq_none _________________ self = def tearDown(self): self.result = [] > quick_cleanup() tests/unit/test_macros.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ log = True def quick_cleanup(log=True): """Reset the applications state.""" # Reminder: before patches are applied in test.py, no inputremapper module # may be imported. So tests.lib imports them just-in-time in functions instead. from inputremapper.injection.macros.macro import macro_variables from inputremapper.configs.global_config import global_config from inputremapper.configs.system_mapping import system_mapping from inputremapper.gui.utils import debounce_manager from inputremapper.configs.paths import get_config_path from inputremapper.injection.global_uinputs import global_uinputs from tests.lib.global_uinputs import reset_global_uinputs_for_service if log: logger.info("Quick cleanup...") debounce_manager.stop_all() for device in list(pending_events.keys()): try: while pending_events[device][1].poll(): pending_events[device][1].recv() except (UnpicklingError, EOFError): pass # setup new pipes for the next test pending_events[device][1].close() pending_events[device][0].close() del pending_events[device] setup_pipe(device) try: if asyncio.get_event_loop().is_running(): for task in asyncio.all_tasks(): task.cancel() except RuntimeError: # happens when the event loop disappears for magical reasons # create a fresh event loop asyncio.set_event_loop(asyncio.new_event_loop()) if macro_variables.process is not None and not macro_variables.process.is_alive(): # nothing should stop the process during runtime, if it has been started by # the injector once raise AssertionError("the SharedDict manager is not running anymore") if macro_variables.process is not None: macro_variables._stop() join_children() macro_variables.start() if os.path.exists(tmp): shutil.rmtree(tmp) global_config.path = os.path.join(get_config_path(), "config.json") global_config.clear_config() global_config._save_config() system_mapping.populate() clear_write_history() for name in list(uinputs.keys()): del uinputs[name] # for device in list(active_macros.keys()): # del active_macros[device] # for device in list(unreleased.keys()): # del unreleased[device] fixtures.reset() os.environ.update(environ_copy) for device in list(os.environ.keys()): if device not in environ_copy: del os.environ[device] for _, pipe in pending_events.values(): assert not pipe.poll() > assert macro_variables.is_alive(1) E AssertionError tests/lib/cleanup.py:152: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:13:26.132582 435078 pytest WARNING context.py:87: Not forward_devices set 14:13:26.150772 435078 pytest WARNING context.py:90: Not source_devices set 14:13:26.741191 435078 pytest DEBUG parse.py:456: parsing macro set(foo, 2).ifeq(foo, 2, None, key(b)) 14:13:27.120739 435078 pytest DEBUG parse.py:244: calls set with foo,2 14:13:27.157578 435078 pytest DEBUG parse.py:244: string foo 14:13:27.488261 435078 pytest DEBUG parse.py:244: number 2 14:13:27.532385 435078 pytest DEBUG parse.py:244: add call to set with ['foo', 2], {} 14:13:27.920526 435078 pytest DEBUG parse.py:244: followed by ifeq(foo,2,None,key(b)) 14:13:27.955066 435078 pytest DEBUG parse.py:244: calls ifeq with foo,2,None,key(b) 14:13:27.973600 435078 pytest DEBUG parse.py:244: string foo 14:13:27.992134 435078 pytest DEBUG parse.py:244: number 2 14:13:28.538544 435078 pytest DEBUG parse.py:244: calls key with b 14:13:28.560187 435078 pytest DEBUG parse.py:244: string b 14:13:28.579594 435078 pytest DEBUG parse.py:244: add call to key with ['b'], {} 14:13:28.941150 435078 pytest DEBUG parse.py:244: add call to ifeq with ['foo', 2, None, ], {} 14:13:29.334750 435078 pytest DEBUG macro.py:533: "foo" set to "2" 14:13:29.362020 436103 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'foo', 2) 14:13:29.364810 435078 pytest DEBUG macro.py:580: "foo" is "pong" 14:13:29.386092 436103 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'foo') Test: macro wrote(1, 48, 1) Test: macro wrote(1, 48, 0) Test: Quick cleanup... 14:13:31.963029 436103 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:13:35.354598 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:13:36.912021 436105 pytest DEBUG shared_dict.py:63: SharedDict process started 14:13:36.924542 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:13:38.115083 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:13:38.173788 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:13:41.155261 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:13:41.742868 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:13:45.516597 436105 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(foo, 2).ifeq(foo, 2, None, key(b)) DEBUG input-remapper:parse.py:244 calls set with foo,2 DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 number 2 DEBUG input-remapper:parse.py:244 add call to set with ['foo', 2], {} DEBUG input-remapper:parse.py:244 followed by ifeq(foo,2,None,key(b)) DEBUG input-remapper:parse.py:244 calls ifeq with foo,2,None,key(b) DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 number 2 DEBUG input-remapper:parse.py:244 calls key with b DEBUG input-remapper:parse.py:244 string b DEBUG input-remapper:parse.py:244 add call to key with ['b'], {} DEBUG input-remapper:parse.py:244 add call to ifeq with ['foo', 2, None, ], {} DEBUG input-remapper:macro.py:533 "foo" set to "2" DEBUG input-remapper:macro.py:580 "foo" is "pong" INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 3.240 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 0) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.552 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" _________________ ERROR at teardown of TestIfEq.test_ifeq_runs _________________ self = def tearDown(self): self.result = [] > quick_cleanup() tests/unit/test_macros.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ log = True def quick_cleanup(log=True): """Reset the applications state.""" # Reminder: before patches are applied in test.py, no inputremapper module # may be imported. So tests.lib imports them just-in-time in functions instead. from inputremapper.injection.macros.macro import macro_variables from inputremapper.configs.global_config import global_config from inputremapper.configs.system_mapping import system_mapping from inputremapper.gui.utils import debounce_manager from inputremapper.configs.paths import get_config_path from inputremapper.injection.global_uinputs import global_uinputs from tests.lib.global_uinputs import reset_global_uinputs_for_service if log: logger.info("Quick cleanup...") debounce_manager.stop_all() for device in list(pending_events.keys()): try: while pending_events[device][1].poll(): pending_events[device][1].recv() except (UnpicklingError, EOFError): pass # setup new pipes for the next test pending_events[device][1].close() pending_events[device][0].close() del pending_events[device] setup_pipe(device) try: if asyncio.get_event_loop().is_running(): for task in asyncio.all_tasks(): task.cancel() except RuntimeError: # happens when the event loop disappears for magical reasons # create a fresh event loop asyncio.set_event_loop(asyncio.new_event_loop()) if macro_variables.process is not None and not macro_variables.process.is_alive(): # nothing should stop the process during runtime, if it has been started by # the injector once raise AssertionError("the SharedDict manager is not running anymore") if macro_variables.process is not None: macro_variables._stop() join_children() macro_variables.start() if os.path.exists(tmp): shutil.rmtree(tmp) global_config.path = os.path.join(get_config_path(), "config.json") global_config.clear_config() global_config._save_config() system_mapping.populate() clear_write_history() for name in list(uinputs.keys()): del uinputs[name] # for device in list(active_macros.keys()): # del active_macros[device] # for device in list(unreleased.keys()): # del unreleased[device] fixtures.reset() os.environ.update(environ_copy) for device in list(os.environ.keys()): if device not in environ_copy: del os.environ[device] for _, pipe in pending_events.values(): assert not pipe.poll() > assert macro_variables.is_alive(1) E AssertionError tests/lib/cleanup.py:152: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:14:39.753073 435078 pytest WARNING context.py:87: Not forward_devices set 14:14:40.109148 435078 pytest WARNING context.py:90: Not source_devices set 14:14:41.135707 435078 pytest DEBUG parse.py:456: parsing macro set(foo, 2).ifeq(foo, 2, key(a), key(b)) 14:14:41.716457 435078 pytest DEBUG parse.py:244: calls set with foo,2 14:14:41.762937 435078 pytest DEBUG parse.py:244: string foo 14:14:41.805694 435078 pytest DEBUG parse.py:244: number 2 14:14:42.142376 435078 pytest DEBUG parse.py:244: add call to set with ['foo', 2], {} 14:14:42.744967 435078 pytest DEBUG parse.py:244: followed by ifeq(foo,2,key(a),key(b)) 14:14:43.119298 435078 pytest DEBUG parse.py:244: calls ifeq with foo,2,key(a),key(b) 14:14:43.156035 435078 pytest DEBUG parse.py:244: string foo 14:14:43.340858 435078 pytest DEBUG parse.py:244: number 2 14:14:43.754124 435078 pytest DEBUG parse.py:244: calls key with a 14:14:43.832728 435078 pytest DEBUG parse.py:244: string a 14:14:44.292799 435078 pytest DEBUG parse.py:244: add call to key with ['a'], {} 14:14:44.329673 435078 pytest DEBUG parse.py:244: calls key with b 14:14:44.887535 435078 pytest DEBUG parse.py:244: string b 14:14:44.908113 435078 pytest DEBUG parse.py:244: add call to key with ['b'], {} 14:14:44.947238 435078 pytest DEBUG parse.py:244: add call to ifeq with ['foo', 2, , ], {} 14:14:44.981718 435078 pytest DEBUG macro.py:533: "foo" set to "2" 14:14:45.008094 435078 pytest DEBUG macro.py:580: "foo" is "pong" 14:14:45.006925 436105 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'foo', 2) Test: macro wrote(1, 48, 1) 14:14:45.440771 436105 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'foo') Test: macro wrote(1, 48, 0) Test: Quick cleanup... 14:14:48.087774 436105 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:14:50.588642 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:14:51.915258 436110 pytest DEBUG shared_dict.py:63: SharedDict process started 14:14:51.929152 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:14:52.728772 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:14:53.102757 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:14:55.362796 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:14:55.752170 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:14:59.355810 436110 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(foo, 2).ifeq(foo, 2, key(a), key(b)) DEBUG input-remapper:parse.py:244 calls set with foo,2 DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 number 2 DEBUG input-remapper:parse.py:244 add call to set with ['foo', 2], {} DEBUG input-remapper:parse.py:244 followed by ifeq(foo,2,key(a),key(b)) DEBUG input-remapper:parse.py:244 calls ifeq with foo,2,key(a),key(b) DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 number 2 DEBUG input-remapper:parse.py:244 calls key with a DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 add call to key with ['a'], {} DEBUG input-remapper:parse.py:244 calls key with b DEBUG input-remapper:parse.py:244 string b DEBUG input-remapper:parse.py:244 add call to key with ['b'], {} DEBUG input-remapper:parse.py:244 add call to ifeq with ['foo', 2, , ], {} DEBUG input-remapper:macro.py:533 "foo" set to "2" DEBUG input-remapper:macro.py:580 "foo" is "pong" INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 4.588 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 0) WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('Lists differ: [(1, 48, 1), (1, 48, 0)] != [(1, 30, 1), (1, 30, 0)]\n\nFirst differing element 0:\n(1, 48, 1)\n(1, 30, 1)\n\n- [(1, 48, 1), (1, 48, 0)]\n? ^^ ^^\n\n+ [(1, 30, 1), (1, 30, 0)]\n? ^^ ^^\n') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.591 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" __________ ERROR at teardown of TestIfSingle.test_if_single_times_out __________ self = def tearDown(self): self.result = [] > quick_cleanup() tests/unit/test_macros.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ log = True def quick_cleanup(log=True): """Reset the applications state.""" # Reminder: before patches are applied in test.py, no inputremapper module # may be imported. So tests.lib imports them just-in-time in functions instead. from inputremapper.injection.macros.macro import macro_variables from inputremapper.configs.global_config import global_config from inputremapper.configs.system_mapping import system_mapping from inputremapper.gui.utils import debounce_manager from inputremapper.configs.paths import get_config_path from inputremapper.injection.global_uinputs import global_uinputs from tests.lib.global_uinputs import reset_global_uinputs_for_service if log: logger.info("Quick cleanup...") debounce_manager.stop_all() for device in list(pending_events.keys()): try: while pending_events[device][1].poll(): pending_events[device][1].recv() except (UnpicklingError, EOFError): pass # setup new pipes for the next test pending_events[device][1].close() pending_events[device][0].close() del pending_events[device] setup_pipe(device) try: if asyncio.get_event_loop().is_running(): for task in asyncio.all_tasks(): task.cancel() except RuntimeError: # happens when the event loop disappears for magical reasons # create a fresh event loop asyncio.set_event_loop(asyncio.new_event_loop()) if macro_variables.process is not None and not macro_variables.process.is_alive(): # nothing should stop the process during runtime, if it has been started by # the injector once raise AssertionError("the SharedDict manager is not running anymore") if macro_variables.process is not None: macro_variables._stop() join_children() macro_variables.start() if os.path.exists(tmp): shutil.rmtree(tmp) global_config.path = os.path.join(get_config_path(), "config.json") global_config.clear_config() global_config._save_config() system_mapping.populate() clear_write_history() for name in list(uinputs.keys()): del uinputs[name] # for device in list(active_macros.keys()): # del active_macros[device] # for device in list(unreleased.keys()): # del unreleased[device] fixtures.reset() os.environ.update(environ_copy) for device in list(os.environ.keys()): if device not in environ_copy: del os.environ[device] for _, pipe in pending_events.values(): assert not pipe.poll() > assert macro_variables.is_alive(1) E AssertionError tests/lib/cleanup.py:152: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:21:23.269828 435078 pytest WARNING context.py:87: Not forward_devices set 14:21:23.308705 435078 pytest WARNING context.py:90: Not source_devices set 14:21:23.773011 435078 pytest DEBUG parse.py:456: parsing macro set(t, 300).if_single(key(x), key(y), timeout=$t) 14:21:24.332271 435078 pytest DEBUG parse.py:244: calls set with t,300 14:21:24.361449 435078 pytest DEBUG parse.py:244: string t 14:21:24.380469 435078 pytest DEBUG parse.py:244: number 300 14:21:24.704725 435078 pytest DEBUG parse.py:244: add call to set with ['t', 300], {} 14:21:25.294786 435078 pytest DEBUG parse.py:244: followed by if_single(key(x),key(y),timeout=$t) 14:21:25.501384 435078 pytest DEBUG parse.py:244: calls if_single with key(x),key(y),timeout=$t 14:21:25.525678 435078 pytest DEBUG parse.py:244: calls key with x 14:21:25.549911 435078 pytest DEBUG parse.py:244: string x 14:21:25.570033 435078 pytest DEBUG parse.py:244: add call to key with ['x'], {} 14:21:26.110936 435078 pytest DEBUG parse.py:244: calls key with y 14:21:26.134248 435078 pytest DEBUG parse.py:244: string y 14:21:26.154481 435078 pytest DEBUG parse.py:244: add call to key with ['y'], {} 14:21:26.179831 435078 pytest DEBUG parse.py:244: add call to if_single with [, ], {'timeout': } 14:21:27.152445 435078 pytest DEBUG macro.py:533: "t" set to "300" 14:21:27.506799 436122 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 't', 300) 14:21:27.515965 435078 pytest DEBUG macro.py:155: "" is "pong" 14:21:27.557024 436122 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 't') Test: Quick cleanup... 14:21:29.199120 436122 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:21:32.719412 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:21:34.072975 436125 pytest DEBUG shared_dict.py:63: SharedDict process started 14:21:34.117531 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:21:34.971810 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:21:35.358946 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:21:38.890641 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:21:38.941310 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:21:42.159664 436125 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(t, 300).if_single(key(x), key(y), timeout=$t) DEBUG input-remapper:parse.py:244 calls set with t,300 DEBUG input-remapper:parse.py:244 string t DEBUG input-remapper:parse.py:244 number 300 DEBUG input-remapper:parse.py:244 add call to set with ['t', 300], {} DEBUG input-remapper:parse.py:244 followed by if_single(key(x),key(y),timeout=$t) DEBUG input-remapper:parse.py:244 calls if_single with key(x),key(y),timeout=$t DEBUG input-remapper:parse.py:244 calls key with x DEBUG input-remapper:parse.py:244 string x DEBUG input-remapper:parse.py:244 add call to key with ['x'], {} DEBUG input-remapper:parse.py:244 calls key with y DEBUG input-remapper:parse.py:244 string y DEBUG input-remapper:parse.py:244 add call to key with ['y'], {} DEBUG input-remapper:parse.py:244 add call to if_single with [, ], {'timeout': } WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 3.367 seconds DEBUG input-remapper:macro.py:533 "t" set to "300" DEBUG input-remapper:macro.py:155 "" is "pong" WARNING asyncio:base_events.py:1946 Executing exception=MacroParsingError("Expected parameter to be one of [, , None], but got pong") created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.411 seconds ERROR asyncio:base_events.py:1785 Task exception was never retrieved future: exception=MacroParsingError("Expected parameter to be one of [, , None], but got pong") created at /usr/lib64/python3.12/asyncio/tasks.py:685> source_traceback: Object created at (most recent call last): File "/usr/bin/pytest", line 8, in sys.exit(console_main()) File "/usr/lib/python3.12/site-packages/_pytest/config/__init__.py", line 189, in console_main code = main() File "/usr/lib/python3.12/site-packages/_pytest/config/__init__.py", line 166, in main ret: Union[ExitCode, int] = config.hook.pytest_cmdline_main( File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 316, in pytest_cmdline_main return wrap_session(config, _main) File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 269, in wrap_session session.exitstatus = doit(config, session) or 0 File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 323, in _main config.hook.pytest_runtestloop(session=session) File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 348, in pytest_runtestloop item.config.hook.pytest_runtest_protocol(item=item, nextitem=nextitem) File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 114, in pytest_runtest_protocol runtestprotocol(item, nextitem=nextitem) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 133, in runtestprotocol reports.append(call_and_report(item, "call", log)) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 222, in call_and_report call = call_runtest_hook(item, when, **kwds) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 261, in call_runtest_hook return CallInfo.from_call( File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 341, in from_call result: Optional[TResult] = func() File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 262, in lambda: ihook(item=item, **kwds), when=when, reraise=reraise File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 169, in pytest_runtest_call item.runtest() File "/usr/lib/python3.12/site-packages/_pytest/unittest.py", line 314, in runtest self._testcase(result=self) # type: ignore[arg-type] File "/usr/lib64/python3.12/unittest/case.py", line 690, in __call__ return self.run(*args, **kwds) File "/usr/lib64/python3.12/unittest/async_case.py", line 131, in run return super().run(result) File "/usr/lib64/python3.12/unittest/case.py", line 634, in run self._callTestMethod(testMethod) File "/usr/lib64/python3.12/unittest/async_case.py", line 90, in _callTestMethod if self._callMaybeAsync(method) is not None: File "/usr/lib64/python3.12/unittest/async_case.py", line 112, in _callMaybeAsync return self._asyncioRunner.run( File "/usr/lib64/python3.12/asyncio/runners.py", line 118, in run return self._loop.run_until_complete(task) File "/usr/lib64/python3.12/asyncio/base_events.py", line 651, in run_until_complete self.run_forever() File "/usr/lib64/python3.12/asyncio/base_events.py", line 618, in run_forever self._run_once() File "/usr/lib64/python3.12/asyncio/base_events.py", line 1943, in _run_once handle._run() File "/usr/lib64/python3.12/asyncio/events.py", line 84, in _run self._context.run(self._callback, *self._args) File "/builddir/build/BUILD/input-remapper-2.0.1/tests/unit/test_macros.py", line 1408, in test_if_single_times_out await self.trigger_sequence(macro, InputEvent.key(a, 1)) File "/builddir/build/BUILD/input-remapper-2.0.1/tests/unit/test_macros.py", line 108, in trigger_sequence asyncio.ensure_future(macro.run(self.handler)) File "/usr/lib64/python3.12/asyncio/tasks.py", line 685, in ensure_future return loop.create_task(coro_or_future) Traceback (most recent call last): File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py", line 267, in run await coroutine File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py", line 677, in task resolved_timeout = _resolve(timeout, allowed_types=[int, float, None]) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py", line 157, in _resolve return _type_check(value, allowed_types) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py", line 127, in _type_check raise MacroParsingError( inputremapper.configs.validation_errors.MacroParsingError: Expected parameter to be one of [, , None], but got pong WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('False is not true') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.323 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" =================================== FAILURES =================================== _________________ TestEventReader.test_if_single_joystick_then _________________ self = async def test_if_single_joystick_then(self): # TODO: Move this somewhere more sensible # Integration test style for if_single. # won't care about the event, because the purpose is not set to BUTTON code_a = system_mapping.get("a") code_shift = system_mapping.get("KEY_LEFTSHIFT") trigger = evdev.ecodes.BTN_A self.preset.add( Mapping.from_combination( InputCombination( [ InputConfig( type=EV_KEY, code=trigger, origin_hash=fixtures.gamepad.get_device_hash(), ) ] ), "keyboard", "if_single(key(a), key(KEY_LEFTSHIFT))", ) ) self.preset.add( Mapping.from_combination( InputCombination( [ InputConfig( type=EV_ABS, code=ABS_Y, analog_threshold=1, origin_hash=fixtures.gamepad.get_device_hash(), ) ] ), "keyboard", "b", ), ) # left x to mouse x config = { "input_combination": [ InputConfig( type=EV_ABS, code=ABS_X, origin_hash=fixtures.gamepad.get_device_hash(), ) ], "target_uinput": "mouse", "output_type": EV_REL, "output_code": REL_X, } self.preset.add(Mapping(**config)) # left y to mouse y config["input_combination"] = [ InputConfig( type=EV_ABS, code=ABS_Y, origin_hash=fixtures.gamepad.get_device_hash(), ) ] config["output_code"] = REL_Y self.preset.add(Mapping(**config)) # right x to wheel x config["input_combination"] = [ InputConfig( type=EV_ABS, code=ABS_RX, origin_hash=fixtures.gamepad.get_device_hash(), ) ] config["output_code"] = REL_HWHEEL_HI_RES self.preset.add(Mapping(**config)) # right y to wheel y config["input_combination"] = [ InputConfig( type=EV_ABS, code=ABS_RY, origin_hash=fixtures.gamepad.get_device_hash(), ) ] config["output_code"] = REL_WHEEL_HI_RES self.preset.add(Mapping(**config)) context, _ = await self.setup(self.gamepad_source, self.preset) gamepad_hash = get_device_hash(self.gamepad_source) self.gamepad_source.push_events( [ InputEvent.key(evdev.ecodes.BTN_Y, 0, gamepad_hash), # start the macro InputEvent.key(trigger, 1, gamepad_hash), # start the macro InputEvent.abs(ABS_Y, 10, gamepad_hash), # ignored InputEvent.key(evdev.ecodes.BTN_B, 2, gamepad_hash), # ignored InputEvent.key(evdev.ecodes.BTN_B, 0, gamepad_hash), # ignored # release the trigger, which runs `then` of if_single InputEvent.key(trigger, 0, gamepad_hash), ] ) await asyncio.sleep(0.1) self.stop_event.set() # stop the reader history = global_uinputs.get_uinput("keyboard").write_history > self.assertIn((EV_KEY, code_a, 1), history) E AssertionError: (1, 30, 1) not found in [] tests/unit/test_event_reader.py:180: AssertionError ----------------------------- Captured stderr call ----------------------------- Test: Hash for fixture "/dev/input/event30" "gamepad": "be7d866387c266d10cb76ef3a7dca90d" 13:29:09.529660 435078 pytest DEBUG parse.py:456: parsing macro if_single(key(a), key(KEY_LEFTSHIFT)) Test: Hash for fixture "/dev/input/event30" "gamepad": "be7d866387c266d10cb76ef3a7dca90d" Test: Hash for fixture "/dev/input/event30" "gamepad": "be7d866387c266d10cb76ef3a7dca90d" Test: Hash for fixture "/dev/input/event30" "gamepad": "be7d866387c266d10cb76ef3a7dca90d" Test: Hash for fixture "/dev/input/event30" "gamepad": "be7d866387c266d10cb76ef3a7dca90d" Test: Hash for fixture "/dev/input/event30" "gamepad": "be7d866387c266d10cb76ef3a7dca90d" 13:29:10.689196 435078 pytest WARNING context.py:87: Not forward_devices set 13:29:10.697848 435078 pytest WARNING context.py:90: Not source_devices set 13:29:11.045862 435078 pytest DEBUG parse.py:456: parsing macro if_single(key(a), key(KEY_LEFTSHIFT)) 13:29:11.056430 435078 pytest DEBUG parse.py:244: calls if_single with key(a),key(KEY_LEFTSHIFT) 13:29:11.067992 435078 pytest DEBUG parse.py:244: calls key with a 13:29:11.076897 435078 pytest DEBUG parse.py:244: string a 13:29:11.086211 435078 pytest DEBUG parse.py:244: add call to key with ['a'], {} 13:29:11.448711 435078 pytest DEBUG parse.py:244: calls key with KEY_LEFTSHIFT 13:29:11.462920 435078 pytest DEBUG parse.py:244: string KEY_LEFTSHIFT 13:29:11.474470 435078 pytest DEBUG parse.py:244: add call to key with ['KEY_LEFTSHIFT'], {} 13:29:11.492901 435078 pytest DEBUG parse.py:244: add call to if_single with [, ], {} 13:29:11.885602 435078 pytest DEBUG combination_handler.py:56: {'input_combination': ) at 0xffffff9359b7f0>, 'target_uinput': 'keyboard'} 13:29:12.274238 435078 pytest DEBUG combination_handler.py:56: {'input_combination': ) at 0xffffff9359b840>, 'target_uinput': 'keyboard'} 13:29:12.326770 435078 pytest DEBUG mapping_parser.py:133: event-pipeline with entry point: ABS_X (3, 0, 'be7d866387c266d10cb76ef3a7dca90d') 13:29:12.657416 435078 pytest DEBUG logger.py:77: 13:29:12.667315 435078 pytest DEBUG logger.py:77: 'maps to: REL_X None at mouse' 13:29:12.677793 435078 pytest DEBUG mapping_parser.py:133: event-pipeline with entry point: ABS_Y (3, 1, 'be7d866387c266d10cb76ef3a7dca90d') 13:29:12.688405 435078 pytest DEBUG logger.py:77: 13:29:12.695815 435078 pytest DEBUG logger.py:77: 'maps to: REL_Y (2, 1) at mouse' 13:29:12.702851 435078 pytest DEBUG mapping_parser.py:133: event-pipeline with entry point: ABS_RX (3, 3, 'be7d866387c266d10cb76ef3a7dca90d') 13:29:12.711189 435078 pytest DEBUG logger.py:77: 13:29:12.717888 435078 pytest DEBUG logger.py:77: 'maps to: REL_HWHEEL_HI_RES (2, 12) at mouse' 13:29:12.725925 435078 pytest DEBUG mapping_parser.py:133: event-pipeline with entry point: ABS_RY (3, 4, 'be7d866387c266d10cb76ef3a7dca90d') 13:29:13.046795 435078 pytest DEBUG logger.py:77: 13:29:13.058829 435078 pytest DEBUG logger.py:77: 'maps to: REL_WHEEL_HI_RES (2, 11) at mouse' 13:29:13.070581 435078 pytest DEBUG mapping_parser.py:133: event-pipeline with entry point: ABS_Y (3, 1, 'be7d866387c266d10cb76ef3a7dca90d') 13:29:13.443312 435078 pytest DEBUG logger.py:77: 13:29:13.449738 435078 pytest DEBUG logger.py:77: ) at 0xffffff9359af80>" ((3, 1, 'be7d866387c266d10cb76ef3a7dca90d'),) at 0xffffff95fd6330> 13:29:13.460960 435078 pytest DEBUG logger.py:77: 13:29:13.470149 435078 pytest DEBUG logger.py:77: 'maps to: KEY_B (1, 48) on keyboard' 13:29:13.478031 435078 pytest DEBUG mapping_parser.py:133: event-pipeline with entry point: BTN_A (1, 304, 'be7d866387c266d10cb76ef3a7dca90d') 13:29:13.490530 435078 pytest DEBUG logger.py:77: ) at 0xffffff9359ad50>" ((1, 304, 'be7d866387c266d10cb76ef3a7dca90d'),) at 0xffffff937cdd30> 13:29:13.498667 435078 pytest DEBUG logger.py:77: 13:29:13.724923 435078 pytest DEBUG logger.py:77: 'maps to on keyboard' 13:29:13.732619 435078 pytest DEBUG context.py:110: Adding NotifyCallback for (3, 0, 'be7d866387c266d10cb76ef3a7dca90d') 13:29:13.741049 435078 pytest DEBUG context.py:110: Adding NotifyCallback for (3, 1, 'be7d866387c266d10cb76ef3a7dca90d') 13:29:13.749874 435078 pytest DEBUG context.py:110: Adding NotifyCallback for (3, 3, 'be7d866387c266d10cb76ef3a7dca90d') 13:29:13.757817 435078 pytest DEBUG context.py:110: Adding NotifyCallback for (3, 4, 'be7d866387c266d10cb76ef3a7dca90d') 13:29:13.765549 435078 pytest DEBUG context.py:110: Adding NotifyCallback for (3, 1, 'be7d866387c266d10cb76ef3a7dca90d') 13:29:13.772298 435078 pytest DEBUG context.py:110: Adding NotifyCallback for (1, 304, 'be7d866387c266d10cb76ef3a7dca90d') 13:29:16.686055 435078 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event30, fd 28 Test: Simulating InputEvent for (1, 308, 0) BTN_WEST for /dev/input/event30 Test: Simulating InputEvent for (1, 304, 1) BTN_A for /dev/input/event30 Test: Simulating InputEvent for (3, 1, 10) ABS_Y for /dev/input/event30 Test: Simulating InputEvent for (1, 305, 2) BTN_B for /dev/input/event30 Test: Simulating InputEvent for (1, 305, 0) BTN_B for /dev/input/event30 Test: Simulating InputEvent for (1, 304, 0) BTN_A for /dev/input/event30 13:29:21.645445 435078 pytest DEBUG event_reader.py:108: read loop stopped 13:29:21.655989 435078 pytest DEBUG key_handler.py:81: resetting key_handler 13:29:21.992283 435078 pytest INFO event_reader.py:207: read loop for /dev/input/event30 stopped Test: Quick cleanup... 13:29:22.879204 435936 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 13:29:25.698400 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 13:29:27.026733 435938 pytest DEBUG shared_dict.py:63: SharedDict process started 13:29:28.043481 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 13:29:29.068634 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 13:29:29.432792 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 13:29:31.915014 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:29:32.288205 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:29:35.666898 435938 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 13:29:36.242092 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 13:29:36.278886 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 13:29:36.313438 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 13:29:36.334602 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 13:29:36.345622 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done ------------------------------ Captured log call ------------------------------- INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event30" "gamepad": "be7d866387c266d10cb76ef3a7dca90d" DEBUG input-remapper:parse.py:456 parsing macro if_single(key(a), key(KEY_LEFTSHIFT)) INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event30" "gamepad": "be7d866387c266d10cb76ef3a7dca90d" INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event30" "gamepad": "be7d866387c266d10cb76ef3a7dca90d" INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event30" "gamepad": "be7d866387c266d10cb76ef3a7dca90d" INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event30" "gamepad": "be7d866387c266d10cb76ef3a7dca90d" INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event30" "gamepad": "be7d866387c266d10cb76ef3a7dca90d" WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro if_single(key(a), key(KEY_LEFTSHIFT)) DEBUG input-remapper:parse.py:244 calls if_single with key(a),key(KEY_LEFTSHIFT) DEBUG input-remapper:parse.py:244 calls key with a DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 add call to key with ['a'], {} DEBUG input-remapper:parse.py:244 calls key with KEY_LEFTSHIFT DEBUG input-remapper:parse.py:244 string KEY_LEFTSHIFT DEBUG input-remapper:parse.py:244 add call to key with ['KEY_LEFTSHIFT'], {} DEBUG input-remapper:parse.py:244 add call to if_single with [, ], {} DEBUG input-remapper:combination_handler.py:56 {'input_combination': ) at 0xffffff9359b7f0>, 'target_uinput': 'keyboard'} DEBUG input-remapper:combination_handler.py:56 {'input_combination': ) at 0xffffff9359b840>, 'target_uinput': 'keyboard'} DEBUG input-remapper:mapping_parser.py:133 event-pipeline with entry point: ABS_X (3, 0, 'be7d866387c266d10cb76ef3a7dca90d') DEBUG input-remapper:logger.py:77 DEBUG input-remapper:logger.py:77 'maps to: REL_X None at mouse' DEBUG input-remapper:mapping_parser.py:133 event-pipeline with entry point: ABS_Y (3, 1, 'be7d866387c266d10cb76ef3a7dca90d') DEBUG input-remapper:logger.py:77 DEBUG input-remapper:logger.py:77 'maps to: REL_Y (2, 1) at mouse' DEBUG input-remapper:mapping_parser.py:133 event-pipeline with entry point: ABS_RX (3, 3, 'be7d866387c266d10cb76ef3a7dca90d') DEBUG input-remapper:logger.py:77 DEBUG input-remapper:logger.py:77 'maps to: REL_HWHEEL_HI_RES (2, 12) at mouse' DEBUG input-remapper:mapping_parser.py:133 event-pipeline with entry point: ABS_RY (3, 4, 'be7d866387c266d10cb76ef3a7dca90d') DEBUG input-remapper:logger.py:77 DEBUG input-remapper:logger.py:77 'maps to: REL_WHEEL_HI_RES (2, 11) at mouse' DEBUG input-remapper:mapping_parser.py:133 event-pipeline with entry point: ABS_Y (3, 1, 'be7d866387c266d10cb76ef3a7dca90d') DEBUG input-remapper:logger.py:77 DEBUG input-remapper:logger.py:77 ) at 0xffffff9359af80>" ((3, 1, 'be7d866387c266d10cb76ef3a7dca90d'),) at 0xffffff95fd6330> DEBUG input-remapper:logger.py:77 DEBUG input-remapper:logger.py:77 'maps to: KEY_B (1, 48) on keyboard' DEBUG input-remapper:mapping_parser.py:133 event-pipeline with entry point: BTN_A (1, 304, 'be7d866387c266d10cb76ef3a7dca90d') DEBUG input-remapper:logger.py:77 ) at 0xffffff9359ad50>" ((1, 304, 'be7d866387c266d10cb76ef3a7dca90d'),) at 0xffffff937cdd30> DEBUG input-remapper:logger.py:77 DEBUG input-remapper:logger.py:77 'maps to on keyboard' DEBUG input-remapper:context.py:110 Adding NotifyCallback for (3, 0, 'be7d866387c266d10cb76ef3a7dca90d') DEBUG input-remapper:context.py:110 Adding NotifyCallback for (3, 1, 'be7d866387c266d10cb76ef3a7dca90d') DEBUG input-remapper:context.py:110 Adding NotifyCallback for (3, 3, 'be7d866387c266d10cb76ef3a7dca90d') DEBUG input-remapper:context.py:110 Adding NotifyCallback for (3, 4, 'be7d866387c266d10cb76ef3a7dca90d') DEBUG input-remapper:context.py:110 Adding NotifyCallback for (3, 1, 'be7d866387c266d10cb76ef3a7dca90d') DEBUG input-remapper:context.py:110 Adding NotifyCallback for (1, 304, 'be7d866387c266d10cb76ef3a7dca90d') WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 7.564 seconds DEBUG input-remapper:event_reader.py:191 Starting to listen for events from /dev/input/event30, fd 28 WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.903 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_wait.._on_completion() at /usr/lib64/python3.12/asyncio/tasks.py:524] created at /builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/event_reader.py:86> took 0.514 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_wait.._on_completion() at /usr/lib64/python3.12/asyncio/tasks.py:524] created at /builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/event_reader.py:93> took 0.548 seconds INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 308, 0) BTN_WEST for /dev/input/event30 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 304, 1) BTN_A for /dev/input/event30 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (3, 1, 10) ABS_Y for /dev/input/event30 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 305, 2) BTN_B for /dev/input/event30 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 305, 0) BTN_B for /dev/input/event30 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 304, 0) BTN_A for /dev/input/event30 WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 1.085 seconds WARNING asyncio:base_events.py:1946 Executing took 0.265 seconds DEBUG input-remapper:event_reader.py:108 read loop stopped DEBUG input-remapper:key_handler.py:81 resetting key_handler INFO input-remapper:event_reader.py:207 read loop for /dev/input/event30 stopped WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.369 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done ___________ TestEventReader.test_if_single_joystick_under_threshold ____________ self = async def test_if_single_joystick_under_threshold(self): """Triggers then because the joystick events value is too low.""" # TODO: Move this somewhere more sensible code_a = system_mapping.get("a") trigger = evdev.ecodes.BTN_A self.preset.add( Mapping.from_combination( InputCombination( [ InputConfig( type=EV_KEY, code=trigger, origin_hash=fixtures.gamepad.get_device_hash(), ) ] ), "keyboard", "if_single(k(a), k(KEY_LEFTSHIFT))", ) ) self.preset.add( Mapping.from_combination( InputCombination( [ InputConfig( type=EV_ABS, code=ABS_Y, analog_threshold=1, origin_hash=fixtures.gamepad.get_device_hash(), ) ] ), "keyboard", "b", ), ) # self.preset.set("gamepad.joystick.left_purpose", BUTTONS) # self.preset.set("gamepad.joystick.right_purpose", BUTTONS) context, _ = await self.setup(self.gamepad_source, self.preset) self.gamepad_source.push_events( [ InputEvent.key(trigger, 1), # start the macro InputEvent.abs(ABS_Y, 1), # ignored because value too low InputEvent.key(trigger, 0), # stop, only way to trigger `then` ] ) await asyncio.sleep(0.1) self.assertEqual(len(context.listeners), 0) history = global_uinputs.get_uinput("keyboard").write_history # the key that triggered if_single should be injected after # if_single had a chance to inject keys (if the macro is fast enough), # so that if_single can inject a modifier to e.g. capitalize the # triggering key. This is important for the space cadet shift > self.assertListEqual( history, [ (EV_KEY, code_a, 1), (EV_KEY, code_a, 0), ], ) E AssertionError: Lists differ: [] != [(1, 30, 1), (1, 30, 0)] E E Second list contains 2 additional elements. E First extra element 0: E (1, 30, 1) E E - [] E + [(1, 30, 1), (1, 30, 0)] tests/unit/test_event_reader.py:244: AssertionError ----------------------------- Captured stderr call ----------------------------- Test: Hash for fixture "/dev/input/event30" "gamepad": "be7d866387c266d10cb76ef3a7dca90d" 13:30:32.090981 435078 pytest DEBUG parse.py:456: parsing macro if_single(k(a), k(KEY_LEFTSHIFT)) Test: Hash for fixture "/dev/input/event30" "gamepad": "be7d866387c266d10cb76ef3a7dca90d" 13:30:33.060767 435078 pytest WARNING context.py:87: Not forward_devices set 13:30:33.066947 435078 pytest WARNING context.py:90: Not source_devices set 13:30:33.079509 435078 pytest DEBUG parse.py:456: parsing macro if_single(k(a), k(KEY_LEFTSHIFT)) 13:30:33.090875 435078 pytest DEBUG parse.py:244: calls if_single with k(a),k(KEY_LEFTSHIFT) 13:30:33.100742 435078 pytest DEBUG parse.py:244: calls k with a 13:30:33.110352 435078 pytest DEBUG parse.py:244: string a 13:30:33.116471 435078 pytest DEBUG parse.py:244: add call to k with ['a'], {} 13:30:33.127637 435078 pytest DEBUG parse.py:244: calls k with KEY_LEFTSHIFT 13:30:33.452368 435078 pytest DEBUG parse.py:244: string KEY_LEFTSHIFT 13:30:33.460889 435078 pytest DEBUG parse.py:244: add call to k with ['KEY_LEFTSHIFT'], {} 13:30:33.473814 435078 pytest DEBUG parse.py:244: add call to if_single with [, ], {} 13:30:33.874935 435078 pytest DEBUG combination_handler.py:56: {'input_combination': ) at 0xffffff936055e0>, 'target_uinput': 'keyboard'} 13:30:34.262458 435078 pytest DEBUG combination_handler.py:56: {'input_combination': ) at 0xffffff93605630>, 'target_uinput': 'keyboard'} 13:30:34.650558 435078 pytest DEBUG mapping_parser.py:133: event-pipeline with entry point: BTN_A (1, 304, 'be7d866387c266d10cb76ef3a7dca90d') 13:30:34.687619 435078 pytest DEBUG logger.py:77: ) at 0xffffff9359b9d0>" ((1, 304, 'be7d866387c266d10cb76ef3a7dca90d'),) at 0xffffff9381ea20> 13:30:34.704243 435078 pytest DEBUG logger.py:77: 13:30:34.715031 435078 pytest DEBUG logger.py:77: 'maps to on keyboard' 13:30:34.724180 435078 pytest DEBUG mapping_parser.py:133: event-pipeline with entry point: ABS_Y (3, 1, 'be7d866387c266d10cb76ef3a7dca90d') 13:30:35.114229 435078 pytest DEBUG logger.py:77: 13:30:35.124369 435078 pytest DEBUG logger.py:77: ) at 0xffffff937180a0>" ((3, 1, 'be7d866387c266d10cb76ef3a7dca90d'),) at 0xffffff95fb5fd0> 13:30:35.138953 435078 pytest DEBUG logger.py:77: 13:30:35.145718 435078 pytest DEBUG logger.py:77: 'maps to: KEY_B (1, 48) on keyboard' 13:30:35.627682 435078 pytest DEBUG context.py:110: Adding NotifyCallback for (1, 304, 'be7d866387c266d10cb76ef3a7dca90d') 13:30:35.644936 435078 pytest DEBUG context.py:110: Adding NotifyCallback for (3, 1, 'be7d866387c266d10cb76ef3a7dca90d') 13:30:36.238400 435078 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event30, fd 28 Test: Simulating InputEvent for (1, 304, 1) BTN_A for /dev/input/event30 Test: Simulating InputEvent for (3, 1, 1) ABS_Y for /dev/input/event30 Test: Simulating InputEvent for (1, 304, 0) BTN_A for /dev/input/event30 Test: read_one "gamepad" "/dev/input/event30" InputEvent for (1, 304, 1) BTN_A 13:30:40.046166 435078 pytest DEBUG combination_handler.py:138: Sending Combination (InputConfig BTN_A) to sub-handler Test: read_one "gamepad" "/dev/input/event30" InputEvent for (3, 1, 1) ABS_Y Test: read_one "gamepad" "/dev/input/event30" InputEvent for (1, 304, 0) BTN_A 13:30:40.503598 435078 pytest DEBUG combination_handler.py:138: Sending Combination (InputConfig BTN_A) to sub-handler Test: Quick cleanup... 13:30:42.867107 435938 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 13:30:45.858885 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 13:30:46.673322 435942 pytest DEBUG shared_dict.py:63: SharedDict process started 13:30:46.698938 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 13:30:47.842827 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 13:30:47.863702 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 13:30:49.672614 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:30:49.709865 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:30:52.672138 435942 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 13:30:53.063440 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 13:30:53.080574 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 13:30:53.103987 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 13:30:53.117575 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 13:30:53.125700 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done ------------------------------ Captured log call ------------------------------- INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event30" "gamepad": "be7d866387c266d10cb76ef3a7dca90d" DEBUG input-remapper:parse.py:456 parsing macro if_single(k(a), k(KEY_LEFTSHIFT)) INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event30" "gamepad": "be7d866387c266d10cb76ef3a7dca90d" WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro if_single(k(a), k(KEY_LEFTSHIFT)) DEBUG input-remapper:parse.py:244 calls if_single with k(a),k(KEY_LEFTSHIFT) DEBUG input-remapper:parse.py:244 calls k with a DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 add call to k with ['a'], {} DEBUG input-remapper:parse.py:244 calls k with KEY_LEFTSHIFT DEBUG input-remapper:parse.py:244 string KEY_LEFTSHIFT DEBUG input-remapper:parse.py:244 add call to k with ['KEY_LEFTSHIFT'], {} DEBUG input-remapper:parse.py:244 add call to if_single with [, ], {} DEBUG input-remapper:combination_handler.py:56 {'input_combination': ) at 0xffffff936055e0>, 'target_uinput': 'keyboard'} DEBUG input-remapper:combination_handler.py:56 {'input_combination': ) at 0xffffff93605630>, 'target_uinput': 'keyboard'} DEBUG input-remapper:mapping_parser.py:133 event-pipeline with entry point: BTN_A (1, 304, 'be7d866387c266d10cb76ef3a7dca90d') DEBUG input-remapper:logger.py:77 ) at 0xffffff9359b9d0>" ((1, 304, 'be7d866387c266d10cb76ef3a7dca90d'),) at 0xffffff9381ea20> DEBUG input-remapper:logger.py:77 DEBUG input-remapper:logger.py:77 'maps to on keyboard' DEBUG input-remapper:mapping_parser.py:133 event-pipeline with entry point: ABS_Y (3, 1, 'be7d866387c266d10cb76ef3a7dca90d') DEBUG input-remapper:logger.py:77 DEBUG input-remapper:logger.py:77 ) at 0xffffff937180a0>" ((3, 1, 'be7d866387c266d10cb76ef3a7dca90d'),) at 0xffffff95fb5fd0> DEBUG input-remapper:logger.py:77 DEBUG input-remapper:logger.py:77 'maps to: KEY_B (1, 48) on keyboard' DEBUG input-remapper:context.py:110 Adding NotifyCallback for (1, 304, 'be7d866387c266d10cb76ef3a7dca90d') DEBUG input-remapper:context.py:110 Adding NotifyCallback for (3, 1, 'be7d866387c266d10cb76ef3a7dca90d') WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 4.730 seconds DEBUG input-remapper:event_reader.py:191 Starting to listen for events from /dev/input/event30, fd 28 WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.852 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_wait.._on_completion() at /usr/lib64/python3.12/asyncio/tasks.py:524] created at /builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/event_reader.py:86> took 0.563 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_wait.._on_completion() at /usr/lib64/python3.12/asyncio/tasks.py:524] created at /builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/event_reader.py:93> took 0.178 seconds INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 304, 1) BTN_A for /dev/input/event30 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (3, 1, 1) ABS_Y for /dev/input/event30 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 304, 0) BTN_A for /dev/input/event30 WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.590 seconds WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('Lists differ: [] != [(1, 30, 1), (1, 30, 0)]\n\nSecond list contains 2 additional elements.\nFirst extra element 0:\n(1, 30, 1)\n\n- []\n+ [(1, 30, 1), (1, 30, 0)]') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.423 seconds INFO input-remapper-test:patches.py:96 read_one "gamepad" "/dev/input/event30" InputEvent for (1, 304, 1) BTN_A DEBUG input-remapper:combination_handler.py:138 Sending Combination (InputConfig BTN_A) to sub-handler INFO input-remapper-test:patches.py:96 read_one "gamepad" "/dev/input/event30" InputEvent for (3, 1, 1) ABS_Y INFO input-remapper-test:patches.py:96 read_one "gamepad" "/dev/input/event30" InputEvent for (1, 304, 0) BTN_A DEBUG input-remapper:combination_handler.py:138 Sending Combination (InputConfig BTN_A) to sub-handler WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 1.414 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.943 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done WARNING asyncio:base_events.py:1946 Executing created at /builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py:680> took 0.397 seconds WARNING asyncio:base_events.py:1946 Executing created at /builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py:681> took 0.364 seconds WARNING asyncio:base_events.py:1946 Executing created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.378 seconds WARNING asyncio:base_events.py:1946 Executing ) at /usr/lib64/python3.12/asyncio/base_events.py:180 created at /usr/lib64/python3.12/asyncio/tasks.py:810> took 0.355 seconds _________________________ TestInjector.test_fail_grab __________________________ self = def test_fail_grab(self): self.make_it_fail = 999 preset = Preset() preset.add( Mapping.from_combination( InputCombination([InputConfig(type=EV_KEY, code=10)]), "keyboard", "a", ) ) self.injector = Injector(groups.find(key="Foo Device 2"), preset) path = "/dev/input/event10" self.injector.context = Context(preset, {}, {}) device = self.injector._grab_device(evdev.InputDevice(path)) self.assertIsNone(device) self.assertGreaterEqual(self.failed, 1) self.assertEqual(self.injector.get_state(), InjectorState.UNKNOWN) self.injector.start() self.assertEqual(self.injector.get_state(), InjectorState.STARTING) # since none can be grabbed, the process will terminate. But that # actually takes quite some time. time.sleep(self.injector.regrab_timeout * 12) > self.assertFalse(self.injector.is_alive()) E AssertionError: True is not false tests/unit/test_injector.py:168: AssertionError ----------------------------- Captured stderr call ----------------------------- 13:36:13.131128 435078 pytest WARNING input_config.py:272: No origin_hash set for {'type': 1, 'code': 10} 13:36:14.095748 435078 pytest WARNING context.py:87: Not forward_devices set 13:36:14.448960 435078 pytest WARNING context.py:90: Not source_devices set 13:36:14.521532 435078 pytest WARNING input_config.py:272: No origin_hash set for {'type': 1, 'code': 10} 13:36:14.862184 435078 pytest DEBUG combination_handler.py:56: {'input_combination': ) at 0xffffff935fed00>, 'target_uinput': 'keyboard'} 13:36:14.909820 435078 pytest DEBUG mapping_parser.py:133: event-pipeline with entry point: KEY_9 (1, 10, None) 13:36:14.928416 435078 pytest DEBUG logger.py:77: ) at 0xffffff960d3110>" ((1, 10, None),) at 0xffffff9364e360> 13:36:15.272793 435078 pytest DEBUG logger.py:77: 13:36:15.284951 435078 pytest DEBUG logger.py:77: 'maps to: KEY_A (1, 30) on keyboard' 13:36:15.301019 435078 pytest DEBUG context.py:110: Adding NotifyCallback for (1, 10, None) 13:36:15.320121 435078 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 1 13:36:15.838608 435078 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 2 13:36:15.898228 435078 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 3 13:36:16.238521 435078 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 4 13:36:16.507681 435078 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 5 13:36:16.621036 435078 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 6 13:36:19.244761 435078 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 7 13:36:19.644633 435078 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 8 13:36:19.705134 435078 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 9 13:36:20.241045 435078 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 10 13:36:20.308228 435078 pytest ERROR injector.py:307: Cannot grab /dev/input/event10, it is possibly in use 13:36:20.318834 435078 pytest ERROR injector.py:308: 13:36:20.338143 435078 pytest DEBUG injector.py:173: Injector state of "Foo Device 2", "None": InjectorState.UNKNOWN 13:36:21.530039 435078 pytest DEBUG injector.py:173: Injector state of "Foo Device 2", "None": InjectorState.STARTING 13:36:21.854888 435998 pytest INFO injector.py:394: Starting injecting the preset for "Foo Device 2" 13:36:23.189243 435998 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 1 13:36:23.657469 435998 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 2 13:36:23.729853 435998 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 3 13:36:24.042938 435998 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 4 13:36:24.452551 435998 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 5 13:36:24.684103 435998 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 6 13:36:25.042556 435998 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 7 13:36:25.276610 435998 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 8 13:36:25.644394 435998 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 9 13:36:25.711019 435998 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 10 13:36:26.297993 435998 pytest ERROR injector.py:307: Cannot grab /dev/input/event10, it is possibly in use 13:36:26.641136 435998 pytest ERROR injector.py:308: 13:36:26.649678 435078 pytest INFO injector.py:188: Stopping injecting keycodes for group "Foo Device 2" 13:36:26.652806 435998 pytest WARNING context.py:87: Not forward_devices set 13:36:26.660830 435998 pytest WARNING context.py:90: Not source_devices set 13:36:27.057911 435078 pytest DEBUG injector.py:173: Injector state of "Foo Device 2", "None": InjectorState.STARTING 13:36:27.064279 435998 pytest DEBUG combination_handler.py:56: {'input_combination': ) at 0xffffff935fe8a0>, 'target_uinput': 'keyboard'} 13:36:27.109056 435998 pytest DEBUG mapping_parser.py:133: event-pipeline with entry point: KEY_9 (1, 10, '698702013ccc49179d9669854f6c2b69') 13:36:27.660593 435998 pytest DEBUG logger.py:77: ) at 0xffffff935fe490>" ((1, 10, '698702013ccc49179d9669854f6c2b69'),) at 0xffffff95fb7d10> 13:36:27.669193 435998 pytest DEBUG logger.py:77: 13:36:27.676841 435998 pytest DEBUG logger.py:77: 'maps to: KEY_A (1, 30) on keyboard' 13:36:27.687378 435998 pytest DEBUG context.py:110: Adding NotifyCallback for (1, 10, '698702013ccc49179d9669854f6c2b69') 13:36:28.046911 435998 pytest ERROR injector.py:423: Did not grab any device ------------------------------ Captured log call ------------------------------- WARNING input-remapper:input_config.py:272 No origin_hash set for {'type': 1, 'code': 10} WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set WARNING input-remapper:input_config.py:272 No origin_hash set for {'type': 1, 'code': 10} DEBUG input-remapper:combination_handler.py:56 {'input_combination': ) at 0xffffff935fed00>, 'target_uinput': 'keyboard'} DEBUG input-remapper:mapping_parser.py:133 event-pipeline with entry point: KEY_9 (1, 10, None) DEBUG input-remapper:logger.py:77 ) at 0xffffff960d3110>" ((1, 10, None),) at 0xffffff9364e360> DEBUG input-remapper:logger.py:77 DEBUG input-remapper:logger.py:77 'maps to: KEY_A (1, 30) on keyboard' DEBUG input-remapper:context.py:110 Adding NotifyCallback for (1, 10, None) DEBUG input-remapper:injector.py:304 Failed attempts to grab /dev/input/event10: 1 DEBUG input-remapper:injector.py:304 Failed attempts to grab /dev/input/event10: 2 DEBUG input-remapper:injector.py:304 Failed attempts to grab /dev/input/event10: 3 DEBUG input-remapper:injector.py:304 Failed attempts to grab /dev/input/event10: 4 DEBUG input-remapper:injector.py:304 Failed attempts to grab /dev/input/event10: 5 DEBUG input-remapper:injector.py:304 Failed attempts to grab /dev/input/event10: 6 DEBUG input-remapper:injector.py:304 Failed attempts to grab /dev/input/event10: 7 DEBUG input-remapper:injector.py:304 Failed attempts to grab /dev/input/event10: 8 DEBUG input-remapper:injector.py:304 Failed attempts to grab /dev/input/event10: 9 DEBUG input-remapper:injector.py:304 Failed attempts to grab /dev/input/event10: 10 ERROR input-remapper:injector.py:307 Cannot grab /dev/input/event10, it is possibly in use ERROR input-remapper:injector.py:308 DEBUG input-remapper:injector.py:173 Injector state of "Foo Device 2", "None": InjectorState.UNKNOWN DEBUG input-remapper:injector.py:173 Injector state of "Foo Device 2", "None": InjectorState.STARTING WARNING asyncio:base_events.py:1946 Executing ) at /usr/lib64/python3.12/asyncio/base_events.py:180 created at /usr/lib64/python3.12/asyncio/events.py:84> took 0.374 seconds INFO input-remapper:injector.py:188 Stopping injecting keycodes for group "Foo Device 2" DEBUG input-remapper:injector.py:173 Injector state of "Foo Device 2", "None": InjectorState.STARTING WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.355 seconds __________________________ TestInjector.test_injector __________________________ self = def test_injector(self): numlock_before = is_numlock_on() # stuff the preset outputs system_mapping.clear() code_a = 100 code_q = 101 code_w = 102 system_mapping._set("a", code_a) system_mapping._set("key_q", code_q) system_mapping._set("w", code_w) preset = Preset() preset.add( Mapping.from_combination( InputCombination( [ InputConfig( type=EV_KEY, code=8, origin_hash=fixtures.foo_device_2_keyboard.get_device_hash(), ), InputConfig( type=EV_KEY, code=9, origin_hash=fixtures.foo_device_2_keyboard.get_device_hash(), ), ] ), "keyboard", "k(KEY_Q).k(w)", ) ) preset.add( Mapping.from_combination( InputCombination( [ InputConfig( type=EV_ABS, code=ABS_HAT0X, analog_threshold=-1, origin_hash=fixtures.foo_device_2_gamepad.get_device_hash(), ) ] ), "keyboard", "a", ) ) # one mapping that is unknown in the system_mapping on purpose input_b = 10 with self.assertRaises(ValidationError): preset.add( Mapping.from_combination( InputCombination( [ InputConfig( type=EV_KEY, code=input_b, origin_hash=fixtures.foo_device_2_keyboard.get_device_hash(), ) ] ), "keyboard", "b", ) ) self.injector = Injector(groups.find(key="Foo Device 2"), preset) self.assertEqual(self.injector.get_state(), InjectorState.UNKNOWN) self.injector.start() self.assertEqual(self.injector.get_state(), InjectorState.STARTING) uinput_write_history_pipe[0].poll(timeout=1) > self.assertEqual(self.injector.get_state(), InjectorState.RUNNING) E AssertionError: != tests/unit/test_injector.py:433: AssertionError ----------------------------- Captured stderr call ----------------------------- Test: Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" Test: Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" 13:38:13.669296 435078 pytest DEBUG parse.py:456: parsing macro k(KEY_Q).k(w) Test: Hash for fixture "/dev/input/event15" "Foo Device bar": "cee831d56755e4bac5b0f5d2fcfd5735" Test: Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" 13:38:15.077366 435078 pytest DEBUG injector.py:173: Injector state of "Foo Device 2", "None": InjectorState.UNKNOWN 13:38:16.113425 435078 pytest DEBUG injector.py:173: Injector state of "Foo Device 2", "None": InjectorState.STARTING 13:38:16.500457 436011 pytest INFO injector.py:394: Starting injecting the preset for "Foo Device 2" 13:38:17.516402 435078 pytest DEBUG injector.py:173: Injector state of "Foo Device 2", "None": InjectorState.STARTING 13:38:19.042525 436011 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 1 13:38:19.126077 436011 pytest DEBUG injector.py:304: Failed attempts to grab /dev/input/event10: 2 13:38:19.847792 436011 pytest DEBUG injector.py:298: Grab /dev/input/event10 13:38:19.893830 436011 pytest DEBUG injector.py:298: Grab /dev/input/event15 13:38:19.947584 436011 pytest DEBUG parse.py:456: parsing macro k(KEY_Q).k(w) 13:38:20.292912 436011 pytest DEBUG parse.py:244: calls k with KEY_Q 13:38:20.310099 436011 pytest DEBUG parse.py:244: string KEY_Q 13:38:20.320602 436011 pytest DEBUG parse.py:244: add call to k with ['KEY_Q'], {} 13:38:20.860644 436011 pytest DEBUG parse.py:244: followed by k(w) 13:38:20.869091 436011 pytest DEBUG parse.py:244: calls k with w 13:38:20.877289 436011 pytest DEBUG parse.py:244: string w 13:38:20.886624 436011 pytest DEBUG parse.py:244: add call to k with ['w'], {} 13:38:20.902274 435078 pytest INFO injector.py:188: Stopping injecting keycodes for group "Foo Device 2" 13:38:21.268508 436011 pytest DEBUG combination_handler.py:56: {'input_combination': , ) at 0xffffff9344ba70>, 'target_uinput': 'keyboard'} 13:38:21.273452 435078 pytest DEBUG injector.py:173: Injector state of "Foo Device 2", "None": InjectorState.STARTING 13:38:21.304192 436011 pytest DEBUG combination_handler.py:56: {'input_combination': ) at 0xffffff9344bac0>, 'target_uinput': 'keyboard'} 13:38:21.674442 436011 pytest DEBUG mapping_parser.py:133: event-pipeline with entry point: KEY_7 (1, 8, '698702013ccc49179d9669854f6c2b69') 13:38:21.691812 436011 pytest DEBUG logger.py:77: , ) at 0xffffff960d22b0>" ((1, 8, '698702013ccc49179d9669854f6c2b69'), (1, 9, '698702013ccc49179d9669854f6c2b69')) at 0xffffff9364c500> 13:38:21.702160 436011 pytest DEBUG logger.py:77: 13:38:21.708375 436011 pytest DEBUG logger.py:77: 'maps to on keyboard' 13:38:21.716456 436011 pytest DEBUG mapping_parser.py:133: event-pipeline with entry point: KEY_8 (1, 9, '698702013ccc49179d9669854f6c2b69') 13:38:21.728401 436011 pytest DEBUG logger.py:77: , ) at 0xffffff960d22b0>" ((1, 8, '698702013ccc49179d9669854f6c2b69'), (1, 9, '698702013ccc49179d9669854f6c2b69')) at 0xffffff9364c500> 13:38:21.736772 436011 pytest DEBUG logger.py:77: 13:38:21.743130 436011 pytest DEBUG logger.py:77: 'maps to on keyboard' 13:38:21.750173 436011 pytest DEBUG mapping_parser.py:133: event-pipeline with entry point: ABS_HAT0X (3, 16, 'cee831d56755e4bac5b0f5d2fcfd5735') 13:38:22.444722 436011 pytest DEBUG logger.py:77: 13:38:22.455093 436011 pytest DEBUG logger.py:77: ) at 0xffffff9363b9d0>" ((3, 16, 'cee831d56755e4bac5b0f5d2fcfd5735'),) at 0xffffff9364c860> 13:38:22.467214 436011 pytest DEBUG logger.py:77: 13:38:22.478541 436011 pytest DEBUG logger.py:77: 'maps to: KEY_RIGHTALT (1, 100) on keyboard' ------------------------------ Captured log call ------------------------------- INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" DEBUG input-remapper:parse.py:456 parsing macro k(KEY_Q).k(w) INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event15" "Foo Device bar": "cee831d56755e4bac5b0f5d2fcfd5735" INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" DEBUG input-remapper:injector.py:173 Injector state of "Foo Device 2", "None": InjectorState.UNKNOWN DEBUG input-remapper:injector.py:173 Injector state of "Foo Device 2", "None": InjectorState.STARTING DEBUG input-remapper:injector.py:173 Injector state of "Foo Device 2", "None": InjectorState.STARTING WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.344 seconds INFO input-remapper:injector.py:188 Stopping injecting keycodes for group "Foo Device 2" DEBUG input-remapper:injector.py:173 Injector state of "Foo Device 2", "None": InjectorState.STARTING _________________________ TestSharedDict.test_set_get __________________________ self = def test_set_get(self): self.shared_dict["a"] = 3 > self.assertEqual(self.shared_dict.get("a"), 3) E AssertionError: None != 3 tests/unit/test_ipc.py:51: AssertionError ----------------------------- Captured stderr call ----------------------------- 13:40:59.740619 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 13:41:00.646960 436023 pytest DEBUG shared_dict.py:63: SharedDict process started 13:41:00.676925 435078 pytest ERROR shared_dict.py:118: select.select timed out 13:41:00.693782 436023 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'a', 3) 13:41:00.722331 436023 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'a') Test: Quick cleanup... 13:41:02.257870 436022 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) Test: Killed pid 436022 because it didn't finish in time Test: Killed pid 436023 because it didn't finish in time 13:41:33.324350 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 13:41:34.147968 436025 pytest DEBUG shared_dict.py:63: SharedDict process started 13:41:34.147125 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 13:41:35.125814 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 13:41:35.538233 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 13:41:36.546150 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:41:36.887775 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:41:39.767155 436025 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 13:41:40.343287 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 13:41:40.789262 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 13:41:40.816267 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 13:41:40.833444 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 13:41:40.844615 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done ------------------------------ Captured log call ------------------------------- DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process ERROR input-remapper:shared_dict.py:118 select.select timed out INFO input-remapper-test:cleanup.py:87 Quick cleanup... INFO input-remapper-test:cleanup.py:59 Killed pid 436022 because it didn't finish in time INFO input-remapper-test:cleanup.py:59 Killed pid 436023 because it didn't finish in time DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done _____________________________ TestMacros.test_add ______________________________ self = async def test_add(self): await parse("set(a, 1).add(a, 1)", self.context, DummyMapping).run(self.handler) > self.assertEqual(macro_variables.get("a"), 2) E AssertionError: 0 != 2 tests/unit/test_macros.py:1069: AssertionError ----------------------------- Captured stderr call ----------------------------- 13:43:51.696800 435078 pytest WARNING context.py:87: Not forward_devices set 13:43:51.717131 435078 pytest WARNING context.py:90: Not source_devices set 13:43:52.702742 435078 pytest DEBUG parse.py:456: parsing macro set(a, 1).add(a, 1) 13:43:53.260044 435078 pytest DEBUG parse.py:244: calls set with a,1 13:43:53.286362 435078 pytest DEBUG parse.py:244: string a 13:43:53.306286 435078 pytest DEBUG parse.py:244: number 1 13:43:53.326880 435078 pytest DEBUG parse.py:244: add call to set with ['a', 1], {} 13:43:54.005281 435078 pytest DEBUG parse.py:244: followed by add(a,1) 13:43:54.026039 435078 pytest DEBUG parse.py:244: calls add with a,1 13:43:54.044710 435078 pytest DEBUG parse.py:244: string a 13:43:54.690674 435078 pytest DEBUG parse.py:244: number 1 13:43:54.719618 435078 pytest DEBUG parse.py:244: add call to add with ['a', 1], {} 13:43:54.758358 435078 pytest DEBUG macro.py:533: "a" set to "1" 13:43:55.086486 436032 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'a', 1) 13:43:55.114641 435078 pytest ERROR shared_dict.py:118: select.select timed out 13:43:55.138091 435078 pytest DEBUG macro.py:546: "a" initialized with 0 13:43:55.139023 436032 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'a') 13:43:55.657329 435078 pytest DEBUG macro.py:563: "a" += "1" 13:43:55.665959 436032 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'a', 0) 13:43:55.692111 436032 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'a') 13:43:55.717387 436032 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'a', 2) 13:43:55.744288 436032 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'a') Test: Quick cleanup... 13:43:57.096670 436032 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 13:43:58.701861 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 13:43:59.722115 436033 pytest DEBUG shared_dict.py:63: SharedDict process started 13:43:59.732355 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 13:44:00.707322 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 13:44:01.121321 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 13:44:02.853343 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:44:02.904603 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:44:07.067055 436033 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(a, 1).add(a, 1) DEBUG input-remapper:parse.py:244 calls set with a,1 DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 number 1 DEBUG input-remapper:parse.py:244 add call to set with ['a', 1], {} DEBUG input-remapper:parse.py:244 followed by add(a,1) DEBUG input-remapper:parse.py:244 calls add with a,1 DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 number 1 DEBUG input-remapper:parse.py:244 add call to add with ['a', 1], {} DEBUG input-remapper:macro.py:533 "a" set to "1" ERROR input-remapper:shared_dict.py:118 select.select timed out DEBUG input-remapper:macro.py:546 "a" initialized with 0 DEBUG input-remapper:macro.py:563 "a" += "1" WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('0 != 2') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 3.032 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" __________________________ TestMacros.test_dont_hold ___________________________ self = async def test_dont_hold(self): macro = parse("key(1).hold(key(a)).key(3)", self.context, DummyMapping) asyncio.ensure_future(macro.run(self.handler)) await asyncio.sleep(0.2) self.assertFalse(macro.is_holding()) # press_trigger was never called, so the macro completes right away # and the child macro of hold is never called. > self.assertEqual(len(self.result), 4) E AssertionError: 1 != 4 tests/unit/test_macros.py:724: AssertionError ----------------------------- Captured stderr call ----------------------------- 13:45:28.059309 435078 pytest WARNING context.py:87: Not forward_devices set 13:45:28.087188 435078 pytest WARNING context.py:90: Not source_devices set 13:45:28.541748 435078 pytest DEBUG parse.py:456: parsing macro key(1).hold(key(a)).key(3) 13:45:28.938102 435078 pytest DEBUG parse.py:244: calls key with 1 13:45:28.960661 435078 pytest DEBUG parse.py:244: number 1 13:45:29.257872 435078 pytest DEBUG parse.py:244: add call to key with [1], {} 13:45:29.310237 435078 pytest DEBUG parse.py:244: followed by hold(key(a)).key(3) 13:45:29.461762 435078 pytest DEBUG parse.py:244: calls hold with key(a) 13:45:29.490358 435078 pytest DEBUG parse.py:244: calls key with a 13:45:29.861994 435078 pytest DEBUG parse.py:244: string a 13:45:29.888517 435078 pytest DEBUG parse.py:244: add call to key with ['a'], {} 13:45:29.922266 435078 pytest DEBUG parse.py:244: add call to hold with [], {} 13:45:30.462521 435078 pytest DEBUG parse.py:244: followed by key(3) 13:45:30.484289 435078 pytest DEBUG parse.py:244: calls key with 3 13:45:30.506426 435078 pytest DEBUG parse.py:244: number 3 13:45:30.856773 435078 pytest DEBUG parse.py:244: add call to key with [3], {} Test: macro wrote(1, 2, 1) Test: macro wrote(1, 2, 0) Test: macro wrote(1, 4, 1) Test: Quick cleanup... 13:45:34.858942 436036 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 13:45:37.208423 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 13:45:38.686581 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 13:45:38.702747 436037 pytest DEBUG shared_dict.py:63: SharedDict process started 13:45:40.067991 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 13:45:40.118014 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 13:45:42.537467 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:45:42.867563 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:45:47.090523 436037 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 13:45:47.470465 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 13:45:47.525162 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 13:45:47.931437 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 13:45:47.974521 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 13:45:48.673366 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro key(1).hold(key(a)).key(3) DEBUG input-remapper:parse.py:244 calls key with 1 DEBUG input-remapper:parse.py:244 number 1 DEBUG input-remapper:parse.py:244 add call to key with [1], {} DEBUG input-remapper:parse.py:244 followed by hold(key(a)).key(3) DEBUG input-remapper:parse.py:244 calls hold with key(a) DEBUG input-remapper:parse.py:244 calls key with a DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 add call to key with ['a'], {} DEBUG input-remapper:parse.py:244 add call to hold with [], {} DEBUG input-remapper:parse.py:244 followed by key(3) DEBUG input-remapper:parse.py:244 calls key with 3 DEBUG input-remapper:parse.py:244 number 3 DEBUG input-remapper:parse.py:244 add call to key with [3], {} WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 2.779 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 2, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.571 seconds WARNING asyncio:base_events.py:1946 Executing , None) at /usr/lib64/python3.12/asyncio/futures.py:311 created at /usr/lib64/python3.12/asyncio/tasks.py:651> took 0.350 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 2, 0) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.565 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 4, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.306 seconds WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.357 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done WARNING asyncio:base_events.py:1946 Executing created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.585 seconds ________________________ TestMacros.test_dont_just_hold ________________________ self = async def test_dont_just_hold(self): macro = parse("key(1).hold().key(3)", self.context, DummyMapping) asyncio.ensure_future(macro.run(self.handler)) await asyncio.sleep(0.1) self.assertFalse(macro.is_holding()) # since press_trigger was never called it just does the macro # completely > self.assertEqual(len(self.result), 4) E AssertionError: 2 != 4 tests/unit/test_macros.py:765: AssertionError ----------------------------- Captured stderr call ----------------------------- 13:46:21.872311 435078 pytest WARNING context.py:87: Not forward_devices set 13:46:21.899062 435078 pytest WARNING context.py:90: Not source_devices set 13:46:22.721293 435078 pytest DEBUG parse.py:456: parsing macro key(1).hold().key(3) 13:46:22.750800 435078 pytest DEBUG parse.py:244: calls key with 1 13:46:23.095765 435078 pytest DEBUG parse.py:244: number 1 13:46:23.122135 435078 pytest DEBUG parse.py:244: add call to key with [1], {} 13:46:23.675873 435078 pytest DEBUG parse.py:244: followed by hold().key(3) 13:46:23.700298 435078 pytest DEBUG parse.py:244: calls hold with 13:46:23.733635 435078 pytest DEBUG parse.py:244: add call to hold with [None], {} 13:46:23.759327 435078 pytest DEBUG parse.py:244: followed by key(3) 13:46:24.456958 435078 pytest DEBUG parse.py:244: calls key with 3 13:46:24.478791 435078 pytest DEBUG parse.py:244: number 3 13:46:24.499381 435078 pytest DEBUG parse.py:244: add call to key with [3], {} Test: macro wrote(1, 2, 1) Test: macro wrote(1, 2, 0) Test: macro wrote(1, 4, 1) Test: Quick cleanup... 13:46:27.122019 436037 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 13:46:29.659215 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 13:46:30.714515 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 13:46:30.731381 436038 pytest DEBUG shared_dict.py:63: SharedDict process started 13:46:31.930391 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 13:46:32.256342 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 13:46:34.884727 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:46:34.930945 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:46:39.068641 436038 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 13:46:39.084461 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 13:46:39.105511 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 13:46:39.674140 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 13:46:39.700462 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 13:46:40.056546 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro key(1).hold().key(3) DEBUG input-remapper:parse.py:244 calls key with 1 DEBUG input-remapper:parse.py:244 number 1 DEBUG input-remapper:parse.py:244 add call to key with [1], {} DEBUG input-remapper:parse.py:244 followed by hold().key(3) DEBUG input-remapper:parse.py:244 calls hold with DEBUG input-remapper:parse.py:244 add call to hold with [None], {} DEBUG input-remapper:parse.py:244 followed by key(3) DEBUG input-remapper:parse.py:244 calls key with 3 DEBUG input-remapper:parse.py:244 number 3 DEBUG input-remapper:parse.py:244 add call to key with [3], {} WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 2.316 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 2, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.427 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 2, 0) WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('2 != 4') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.313 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 4, 1) WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.514 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done ________________________ TestMacros.test_duplicate_run _________________________ self = async def test_duplicate_run(self): # it won't restart the macro, because that may screw up the # internal state (in particular the _trigger_release_event). # I actually don't know at all what kind of bugs that might produce, # lets just avoid it. It might cause it to be held down forever. a = system_mapping.get("a") b = system_mapping.get("b") c = system_mapping.get("c") macro = parse("key(a).modify(b, hold()).key(c)", self.context, DummyMapping) asyncio.ensure_future(macro.run(self.handler)) self.assertFalse(macro.is_holding()) asyncio.ensure_future(macro.run(self.handler)) # ignored self.assertFalse(macro.is_holding()) macro.press_trigger() await asyncio.sleep(0.2) self.assertTrue(macro.is_holding()) asyncio.ensure_future(macro.run(self.handler)) # ignored self.assertTrue(macro.is_holding()) macro.release_trigger() await asyncio.sleep(0.2) self.assertFalse(macro.is_holding()) expected = [ (EV_KEY, a, 1), (EV_KEY, a, 0), (EV_KEY, b, 1), (EV_KEY, b, 0), (EV_KEY, c, 1), (EV_KEY, c, 0), ] > self.assertListEqual(self.result, expected) E AssertionError: Lists differ: [(1, 30, 1), (1, 30, 0), (1, 48, 1)] != [(1, 30, 1), (1, 30, 0), (1, 48, 1), (1, 48, 0), (1, 46, 1), (1, 46, 0)] E E Second list contains 3 additional elements. E First extra element 3: E (1, 48, 0) E E - [(1, 30, 1), (1, 30, 0), (1, 48, 1)] E + [(1, 30, 1), (1, 30, 0), (1, 48, 1), (1, 48, 0), (1, 46, 1), (1, 46, 0)] tests/unit/test_macros.py:953: AssertionError ----------------------------- Captured stderr call ----------------------------- 13:47:17.107671 435078 pytest WARNING context.py:87: Not forward_devices set 13:47:17.469685 435078 pytest WARNING context.py:90: Not source_devices set 13:47:18.096633 435078 pytest DEBUG parse.py:456: parsing macro key(a).modify(b, hold()).key(c) 13:47:18.125651 435078 pytest DEBUG parse.py:244: calls key with a 13:47:18.707741 435078 pytest DEBUG parse.py:244: string a 13:47:18.735748 435078 pytest DEBUG parse.py:244: add call to key with ['a'], {} 13:47:19.107278 435078 pytest DEBUG parse.py:244: followed by modify(b,hold()).key(c) 13:47:19.463960 435078 pytest DEBUG parse.py:244: calls modify with b,hold() 13:47:19.490133 435078 pytest DEBUG parse.py:244: string b 13:47:19.514136 435078 pytest DEBUG parse.py:244: calls hold with 13:47:19.534942 435078 pytest DEBUG parse.py:244: add call to hold with [None], {} 13:47:20.095632 435078 pytest DEBUG parse.py:244: add call to modify with ['b', ], {} 13:47:20.133428 435078 pytest DEBUG parse.py:244: followed by key(c) 13:47:20.154677 435078 pytest DEBUG parse.py:244: calls key with c 13:47:20.887366 435078 pytest DEBUG parse.py:244: string c 13:47:20.907908 435078 pytest DEBUG parse.py:244: add call to key with ['c'], {} Test: macro wrote(1, 30, 1) 13:47:21.554241 435078 pytest ERROR macro.py:256: Tried to run already running macro "key(a).modify(b,hold()).key(c)" Test: macro wrote(1, 30, 0) 13:47:22.212678 435078 pytest ERROR macro.py:256: Tried to run already running macro "key(a).modify(b,hold()).key(c)" Test: macro wrote(1, 48, 1) Test: macro wrote(1, 48, 0) Test: macro wrote(1, 46, 1) Test: Quick cleanup... 13:47:26.693827 436038 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 13:47:29.673761 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 13:47:31.055144 436040 pytest DEBUG shared_dict.py:63: SharedDict process started 13:47:31.056812 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 13:47:32.101370 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 13:47:32.148235 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 13:47:34.549680 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:47:34.608783 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:47:37.525697 436040 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 13:47:37.544364 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 13:47:38.071980 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 13:47:38.109752 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 13:47:38.139029 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 13:47:38.508111 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro key(a).modify(b, hold()).key(c) DEBUG input-remapper:parse.py:244 calls key with a DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 add call to key with ['a'], {} DEBUG input-remapper:parse.py:244 followed by modify(b,hold()).key(c) DEBUG input-remapper:parse.py:244 calls modify with b,hold() DEBUG input-remapper:parse.py:244 string b DEBUG input-remapper:parse.py:244 calls hold with DEBUG input-remapper:parse.py:244 add call to hold with [None], {} DEBUG input-remapper:parse.py:244 add call to modify with ['b', ], {} DEBUG input-remapper:parse.py:244 followed by key(c) DEBUG input-remapper:parse.py:244 calls key with c DEBUG input-remapper:parse.py:244 string c DEBUG input-remapper:parse.py:244 add call to key with ['c'], {} WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 3.407 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 30, 1) ERROR input-remapper:macro.py:256 Tried to run already running macro "key(a).modify(b,hold()).key(c)" WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.516 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 30, 0) ERROR input-remapper:macro.py:256 Tried to run already running macro "key(a).modify(b,hold()).key(c)" WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.470 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.559 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 0) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.428 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 46, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.578 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done _____________________________ TestMacros.test_hold _____________________________ self = async def test_hold(self): # repeats key(a) as long as the key is held down macro = parse("key(1).hold(key(a)).key(3)", self.context, DummyMapping) """down""" macro.press_trigger() await asyncio.sleep(0.05) self.assertTrue(macro.is_holding()) macro.press_trigger() # redundantly calling doesn't break anything asyncio.ensure_future(macro.run(self.handler)) await asyncio.sleep(0.2) self.assertTrue(macro.is_holding()) > self.assertGreater(len(self.result), 2) E AssertionError: 2 not greater than 2 tests/unit/test_macros.py:681: AssertionError ----------------------------- Captured stderr call ----------------------------- 13:50:26.330217 435078 pytest WARNING context.py:87: Not forward_devices set 13:50:26.686467 435078 pytest WARNING context.py:90: Not source_devices set 13:50:27.507828 435078 pytest DEBUG parse.py:456: parsing macro key(1).hold(key(a)).key(3) 13:50:27.900368 435078 pytest DEBUG parse.py:244: calls key with 1 13:50:27.944206 435078 pytest DEBUG parse.py:244: number 1 13:50:28.499690 435078 pytest DEBUG parse.py:244: add call to key with [1], {} 13:50:28.894616 435078 pytest DEBUG parse.py:244: followed by hold(key(a)).key(3) 13:50:29.259927 435078 pytest DEBUG parse.py:244: calls hold with key(a) 13:50:29.297798 435078 pytest DEBUG parse.py:244: calls key with a 13:50:29.327642 435078 pytest DEBUG parse.py:244: string a 13:50:29.349559 435078 pytest DEBUG parse.py:244: add call to key with ['a'], {} 13:50:29.669912 435078 pytest DEBUG parse.py:244: add call to hold with [], {} 13:50:30.074205 435078 pytest DEBUG parse.py:244: followed by key(3) 13:50:30.119492 435078 pytest DEBUG parse.py:244: calls key with 3 13:50:30.671223 435078 pytest DEBUG parse.py:244: number 3 13:50:30.697072 435078 pytest DEBUG parse.py:244: add call to key with [3], {} 13:50:31.723048 435078 pytest ERROR macro.py:277: Already holding Test: macro wrote(1, 2, 1) Test: macro wrote(1, 2, 0) Test: macro wrote(1, 30, 1) Test: macro wrote(1, 30, 0) Test: Quick cleanup... 13:50:35.302405 436049 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 13:50:37.713768 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 13:50:38.779578 436050 pytest DEBUG shared_dict.py:63: SharedDict process started 13:50:38.557426 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 13:50:39.704219 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 13:50:40.059192 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 13:50:42.899591 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:50:43.294953 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:50:47.300912 436050 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 13:50:47.718392 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 13:50:47.756564 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 13:50:48.114222 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 13:50:48.145105 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 13:50:48.167794 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro key(1).hold(key(a)).key(3) DEBUG input-remapper:parse.py:244 calls key with 1 DEBUG input-remapper:parse.py:244 number 1 DEBUG input-remapper:parse.py:244 add call to key with [1], {} DEBUG input-remapper:parse.py:244 followed by hold(key(a)).key(3) DEBUG input-remapper:parse.py:244 calls hold with key(a) DEBUG input-remapper:parse.py:244 calls key with a DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 add call to key with ['a'], {} DEBUG input-remapper:parse.py:244 add call to hold with [], {} DEBUG input-remapper:parse.py:244 followed by key(3) DEBUG input-remapper:parse.py:244 calls key with 3 DEBUG input-remapper:parse.py:244 number 3 DEBUG input-remapper:parse.py:244 add call to key with [3], {} WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 3.813 seconds ERROR input-remapper:macro.py:277 Already holding WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.774 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 2, 1) INFO input-remapper-test:test_macros.py:96 macro wrote(1, 2, 0) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.564 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 30, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.543 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 30, 0) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.528 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done WARNING asyncio:base_events.py:1946 Executing created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.413 seconds __________________________ TestMacros.test_hold_keys ___________________________ self = async def test_hold_keys(self): macro = parse("set(foo, b).hold_keys(a, $foo, c)", self.context, DummyMapping) # press first macro.press_trigger() # then run, just like how it is going to happen during runtime asyncio.ensure_future(macro.run(self.handler)) code_a = system_mapping.get("a") code_b = system_mapping.get("b") code_c = system_mapping.get("c") await asyncio.sleep(0.2) > self.assertListEqual( self.result, [ (EV_KEY, code_a, 1), (EV_KEY, code_b, 1), (EV_KEY, code_c, 1), ], ) E AssertionError: Lists differ: [] != [(1, 30, 1), (1, 48, 1), (1, 46, 1)] E E Second list contains 3 additional elements. E First extra element 0: E (1, 30, 1) E E - [] E + [(1, 30, 1), (1, 48, 1), (1, 46, 1)] tests/unit/test_macros.py:643: AssertionError ----------------------------- Captured stderr call ----------------------------- 13:52:11.080945 435078 pytest WARNING context.py:87: Not forward_devices set 13:52:11.100500 435078 pytest WARNING context.py:90: Not source_devices set 13:52:11.684287 435078 pytest DEBUG parse.py:456: parsing macro set(foo, b).hold_keys(a, $foo, c) 13:52:12.082541 435078 pytest DEBUG parse.py:244: calls set with foo,b 13:52:12.124824 435078 pytest DEBUG parse.py:244: string foo 13:52:12.146254 435078 pytest DEBUG parse.py:244: string b 13:52:12.485803 435078 pytest DEBUG parse.py:244: add call to set with ['foo', 'b'], {} 13:52:12.524714 435078 pytest DEBUG parse.py:244: followed by hold_keys(a,$foo,c) 13:52:13.080919 435078 pytest DEBUG parse.py:244: calls hold_keys with a,$foo,c 13:52:13.102886 435078 pytest DEBUG parse.py:244: string a 13:52:13.126503 435078 pytest DEBUG parse.py:244: string c 13:52:13.147321 435078 pytest DEBUG parse.py:244: add call to hold_keys with ['a', , 'c'], {} 13:52:14.467042 435078 pytest DEBUG macro.py:533: "foo" set to "b" 13:52:14.497189 436053 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'foo', 'b') 13:52:14.520353 435078 pytest DEBUG macro.py:155: "" is "pong" 13:52:14.532097 436053 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'foo') Test: Quick cleanup... 13:52:17.549388 436053 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 13:52:20.336561 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 13:52:21.133225 436054 pytest DEBUG shared_dict.py:63: SharedDict process started 13:52:21.136053 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 13:52:22.106272 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 13:52:22.532178 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 13:52:24.269406 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:52:24.703932 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:52:27.892196 436054 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(foo, b).hold_keys(a, $foo, c) DEBUG input-remapper:parse.py:244 calls set with foo,b DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 string b DEBUG input-remapper:parse.py:244 add call to set with ['foo', 'b'], {} DEBUG input-remapper:parse.py:244 followed by hold_keys(a,$foo,c) DEBUG input-remapper:parse.py:244 calls hold_keys with a,$foo,c DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 string c DEBUG input-remapper:parse.py:244 add call to hold_keys with ['a', , 'c'], {} WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 2.381 seconds DEBUG input-remapper:macro.py:533 "foo" set to "b" DEBUG input-remapper:macro.py:155 "" is "pong" WARNING asyncio:base_events.py:1946 Executing exception=MacroParsingError('Unknown key "pong"') created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.435 seconds ERROR asyncio:base_events.py:1785 Task exception was never retrieved future: exception=MacroParsingError('Unknown key "pong"') created at /usr/lib64/python3.12/asyncio/tasks.py:685> source_traceback: Object created at (most recent call last): File "/usr/bin/pytest", line 8, in sys.exit(console_main()) File "/usr/lib/python3.12/site-packages/_pytest/config/__init__.py", line 189, in console_main code = main() File "/usr/lib/python3.12/site-packages/_pytest/config/__init__.py", line 166, in main ret: Union[ExitCode, int] = config.hook.pytest_cmdline_main( File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 316, in pytest_cmdline_main return wrap_session(config, _main) File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 269, in wrap_session session.exitstatus = doit(config, session) or 0 File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 323, in _main config.hook.pytest_runtestloop(session=session) File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 348, in pytest_runtestloop item.config.hook.pytest_runtest_protocol(item=item, nextitem=nextitem) File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 114, in pytest_runtest_protocol runtestprotocol(item, nextitem=nextitem) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 133, in runtestprotocol reports.append(call_and_report(item, "call", log)) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 222, in call_and_report call = call_runtest_hook(item, when, **kwds) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 261, in call_runtest_hook return CallInfo.from_call( File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 341, in from_call result: Optional[TResult] = func() File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 262, in lambda: ihook(item=item, **kwds), when=when, reraise=reraise File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 169, in pytest_runtest_call item.runtest() File "/usr/lib/python3.12/site-packages/_pytest/unittest.py", line 314, in runtest self._testcase(result=self) # type: ignore[arg-type] File "/usr/lib64/python3.12/unittest/case.py", line 690, in __call__ return self.run(*args, **kwds) File "/usr/lib64/python3.12/unittest/async_case.py", line 131, in run return super().run(result) File "/usr/lib64/python3.12/unittest/case.py", line 634, in run self._callTestMethod(testMethod) File "/usr/lib64/python3.12/unittest/async_case.py", line 90, in _callTestMethod if self._callMaybeAsync(method) is not None: File "/usr/lib64/python3.12/unittest/async_case.py", line 112, in _callMaybeAsync return self._asyncioRunner.run( File "/usr/lib64/python3.12/asyncio/runners.py", line 118, in run return self._loop.run_until_complete(task) File "/usr/lib64/python3.12/asyncio/base_events.py", line 651, in run_until_complete self.run_forever() File "/usr/lib64/python3.12/asyncio/base_events.py", line 618, in run_forever self._run_once() File "/usr/lib64/python3.12/asyncio/base_events.py", line 1943, in _run_once handle._run() File "/usr/lib64/python3.12/asyncio/events.py", line 84, in _run self._context.run(self._callback, *self._args) File "/builddir/build/BUILD/input-remapper-2.0.1/tests/unit/test_macros.py", line 636, in test_hold_keys asyncio.ensure_future(macro.run(self.handler)) File "/usr/lib64/python3.12/asyncio/tasks.py", line 685, in ensure_future return loop.create_task(coro_or_future) Traceback (most recent call last): File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py", line 267, in run await coroutine File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py", line 423, in task codes = [self._type_check_symbol(symbol) for symbol in resolved_symbols] ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py", line 708, in _type_check_symbol raise MacroParsingError(msg=f'Unknown key "{symbol}"') inputremapper.configs.validation_errors.MacroParsingError: Unknown key "pong" WARNING asyncio:base_events.py:1946 Executing , None) at /usr/lib64/python3.12/asyncio/futures.py:311 created at /usr/lib64/python3.12/asyncio/tasks.py:651> took 0.319 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" ________________________ TestMacros.test_hold_variable _________________________ self = async def test_hold_variable(self): code_a = system_mapping.get("a") macro = parse("set(foo, a).hold($foo)", self.context, DummyMapping) > await macro.run(self.handler) tests/unit/test_macros.py:622: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ inputremapper/injection/macros/macro.py:267: in run await coroutine inputremapper/injection/macros/macro.py:368: in task code = self._type_check_symbol(resolved_symbol) _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = , keyname = 'pong' def _type_check_symbol(self, keyname: Union[str, Variable]) -> Union[Variable, int]: """Same as _type_check, but checks if the key-name is valid.""" if isinstance(keyname, Variable): # it is a variable and will be read at runtime return keyname symbol = str(keyname) code = system_mapping.get(symbol) if code is None: > raise MacroParsingError(msg=f'Unknown key "{symbol}"') E inputremapper.configs.validation_errors.MacroParsingError: Unknown key "pong" inputremapper/injection/macros/macro.py:708: MacroParsingError ----------------------------- Captured stderr call ----------------------------- 13:53:24.144518 435078 pytest WARNING context.py:87: Not forward_devices set 13:53:24.691478 435078 pytest WARNING context.py:90: Not source_devices set 13:53:25.683704 435078 pytest DEBUG parse.py:456: parsing macro set(foo, a).hold($foo) 13:53:25.710938 435078 pytest DEBUG parse.py:244: calls set with foo,a 13:53:26.275389 435078 pytest DEBUG parse.py:244: string foo 13:53:26.325564 435078 pytest DEBUG parse.py:244: string a 13:53:26.366743 435078 pytest DEBUG parse.py:244: add call to set with ['foo', 'a'], {} 13:53:26.708795 435078 pytest DEBUG parse.py:244: followed by hold($foo) 13:53:27.288090 435078 pytest DEBUG parse.py:244: calls hold with $foo 13:53:27.342294 435078 pytest DEBUG parse.py:244: add call to hold with [], {} 13:53:27.897313 435078 pytest DEBUG macro.py:533: "foo" set to "a" 13:53:27.956799 436054 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'foo', 'a') 13:53:28.296402 435078 pytest DEBUG macro.py:155: "" is "pong" 13:53:28.299718 436054 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'foo') Test: Quick cleanup... 13:53:29.906810 436054 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 13:53:32.555836 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 13:53:34.059627 436057 pytest DEBUG shared_dict.py:63: SharedDict process started 13:53:34.060556 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 13:53:35.718731 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 13:53:35.764253 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 13:53:39.069866 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:53:39.125707 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:53:42.739877 436057 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(foo, a).hold($foo) DEBUG input-remapper:parse.py:244 calls set with foo,a DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 add call to set with ['foo', 'a'], {} DEBUG input-remapper:parse.py:244 followed by hold($foo) DEBUG input-remapper:parse.py:244 calls hold with $foo DEBUG input-remapper:parse.py:244 add call to hold with [], {} DEBUG input-remapper:macro.py:533 "foo" set to "a" DEBUG input-remapper:macro.py:155 "" is "pong" WARNING asyncio:base_events.py:1946 Executing exception=MacroParsingError('Unknown key "pong"') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 2.684 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" __________________________ TestMacros.test_just_hold ___________________________ self = async def test_just_hold(self): macro = parse("key(1).hold().key(3)", self.context, DummyMapping) """down""" macro.press_trigger() asyncio.ensure_future(macro.run(self.handler)) await asyncio.sleep(0.1) self.assertTrue(macro.is_holding()) > self.assertEqual(len(self.result), 2) E AssertionError: 1 != 2 tests/unit/test_macros.py:740: AssertionError ----------------------------- Captured stderr call ----------------------------- 13:55:11.126595 435078 pytest WARNING context.py:87: Not forward_devices set 13:55:11.146052 435078 pytest WARNING context.py:90: Not source_devices set 13:55:11.934183 435078 pytest DEBUG parse.py:456: parsing macro key(1).hold().key(3) 13:55:12.483343 435078 pytest DEBUG parse.py:244: calls key with 1 13:55:12.534769 435078 pytest DEBUG parse.py:244: number 1 13:55:12.555836 435078 pytest DEBUG parse.py:244: add call to key with [1], {} 13:55:12.894449 435078 pytest DEBUG parse.py:244: followed by hold().key(3) 13:55:12.920425 435078 pytest DEBUG parse.py:244: calls hold with 13:55:13.301445 435078 pytest DEBUG parse.py:244: add call to hold with [None], {} 13:55:13.335419 435078 pytest DEBUG parse.py:244: followed by key(3) 13:55:13.360713 435078 pytest DEBUG parse.py:244: calls key with 3 13:55:13.674451 435078 pytest DEBUG parse.py:244: number 3 13:55:14.069587 435078 pytest DEBUG parse.py:244: add call to key with [3], {} Test: macro wrote(1, 2, 1) Test: macro wrote(1, 2, 0) Test: Quick cleanup... 13:55:16.977887 436059 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 13:55:19.740105 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 13:55:21.291439 436061 pytest DEBUG shared_dict.py:63: SharedDict process started 13:55:21.293084 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 13:55:22.671331 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 13:55:22.707706 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 13:55:25.917986 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:55:26.369722 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:55:29.126027 436061 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 13:55:29.487117 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 13:55:29.513847 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 13:55:29.877291 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 13:55:29.905827 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 13:55:29.932180 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro key(1).hold().key(3) DEBUG input-remapper:parse.py:244 calls key with 1 DEBUG input-remapper:parse.py:244 number 1 DEBUG input-remapper:parse.py:244 add call to key with [1], {} DEBUG input-remapper:parse.py:244 followed by hold().key(3) DEBUG input-remapper:parse.py:244 calls hold with DEBUG input-remapper:parse.py:244 add call to hold with [None], {} DEBUG input-remapper:parse.py:244 followed by key(3) DEBUG input-remapper:parse.py:244 calls key with 3 DEBUG input-remapper:parse.py:244 number 3 DEBUG input-remapper:parse.py:244 add call to key with [3], {} WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 2.949 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 2, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.424 seconds WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('1 != 2') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.326 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 2, 0) WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.516 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.196 seconds _____________________________ TestMacros.test_key ______________________________ self = async def test_key(self): code_a = system_mapping.get("a") code_b = system_mapping.get("b") macro = parse("set(foo, b).key($foo).key(a)", self.context, DummyMapping) > await macro.run(self.handler) tests/unit/test_macros.py:567: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ inputremapper/injection/macros/macro.py:267: in run await coroutine inputremapper/injection/macros/macro.py:316: in task code = self._type_check_symbol(resolved_symbol) _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = keyname = 'pong' def _type_check_symbol(self, keyname: Union[str, Variable]) -> Union[Variable, int]: """Same as _type_check, but checks if the key-name is valid.""" if isinstance(keyname, Variable): # it is a variable and will be read at runtime return keyname symbol = str(keyname) code = system_mapping.get(symbol) if code is None: > raise MacroParsingError(msg=f'Unknown key "{symbol}"') E inputremapper.configs.validation_errors.MacroParsingError: Unknown key "pong" inputremapper/injection/macros/macro.py:708: MacroParsingError ----------------------------- Captured stderr call ----------------------------- 13:56:06.513235 435078 pytest WARNING context.py:87: Not forward_devices set 13:56:06.533075 435078 pytest WARNING context.py:90: Not source_devices set 13:56:07.356595 435078 pytest DEBUG parse.py:456: parsing macro set(foo, b).key($foo).key(a) 13:56:07.717299 435078 pytest DEBUG parse.py:244: calls set with foo,b 13:56:07.746213 435078 pytest DEBUG parse.py:244: string foo 13:56:08.104618 435078 pytest DEBUG parse.py:244: string b 13:56:08.665985 435078 pytest DEBUG parse.py:244: add call to set with ['foo', 'b'], {} 13:56:08.717215 435078 pytest DEBUG parse.py:244: followed by key($foo).key(a) 13:56:08.739710 435078 pytest DEBUG parse.py:244: calls key with $foo 13:56:09.315069 435078 pytest DEBUG parse.py:244: add call to key with [], {} 13:56:09.351515 435078 pytest DEBUG parse.py:244: followed by key(a) 13:56:09.875924 435078 pytest DEBUG parse.py:244: calls key with a 13:56:09.918836 435078 pytest DEBUG parse.py:244: string a 13:56:09.952059 435078 pytest DEBUG parse.py:244: add call to key with ['a'], {} 13:56:10.284409 435078 pytest DEBUG macro.py:533: "foo" set to "b" 13:56:10.667346 436061 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'foo', 'b') 13:56:10.673230 435078 pytest DEBUG macro.py:155: "" is "pong" 13:56:10.700112 436061 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'foo') Test: Quick cleanup... 13:56:11.555689 436061 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 13:56:12.845180 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 13:56:14.160479 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 13:56:14.682897 436062 pytest DEBUG shared_dict.py:63: SharedDict process started 13:56:15.314406 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 13:56:15.688786 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 13:56:17.537625 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:56:18.101475 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:56:20.982711 436062 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(foo, b).key($foo).key(a) DEBUG input-remapper:parse.py:244 calls set with foo,b DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 string b DEBUG input-remapper:parse.py:244 add call to set with ['foo', 'b'], {} DEBUG input-remapper:parse.py:244 followed by key($foo).key(a) DEBUG input-remapper:parse.py:244 calls key with $foo DEBUG input-remapper:parse.py:244 add call to key with [], {} DEBUG input-remapper:parse.py:244 followed by key(a) DEBUG input-remapper:parse.py:244 calls key with a DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 add call to key with ['a'], {} DEBUG input-remapper:macro.py:533 "foo" set to "b" DEBUG input-remapper:macro.py:155 "" is "pong" WARNING asyncio:base_events.py:1946 Executing exception=MacroParsingError('Unknown key "pong"') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 3.367 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" _________________________ TestMacros.test_key_down_up __________________________ self = async def test_key_down_up(self): code_a = system_mapping.get("a") code_b = system_mapping.get("b") macro = parse( "set(foo, b).key_down($foo).key_up($foo).key_up(a).key_down(a)", self.context, DummyMapping, ) > await macro.run(self.handler) tests/unit/test_macros.py:586: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ inputremapper/injection/macros/macro.py:267: in run await coroutine inputremapper/injection/macros/macro.py:332: in task code = self._type_check_symbol(resolved_symbol) _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = keyname = 'pong' def _type_check_symbol(self, keyname: Union[str, Variable]) -> Union[Variable, int]: """Same as _type_check, but checks if the key-name is valid.""" if isinstance(keyname, Variable): # it is a variable and will be read at runtime return keyname symbol = str(keyname) code = system_mapping.get(symbol) if code is None: > raise MacroParsingError(msg=f'Unknown key "{symbol}"') E inputremapper.configs.validation_errors.MacroParsingError: Unknown key "pong" inputremapper/injection/macros/macro.py:708: MacroParsingError ----------------------------- Captured stderr call ----------------------------- 13:57:30.735816 435078 pytest WARNING context.py:87: Not forward_devices set 13:57:31.076389 435078 pytest WARNING context.py:90: Not source_devices set 13:57:31.687158 435078 pytest DEBUG parse.py:456: parsing macro set(foo, b).key_down($foo).key_up($foo).key_up(a).key_down(a) 13:57:31.717247 435078 pytest DEBUG parse.py:244: calls set with foo,b 13:57:31.738893 435078 pytest DEBUG parse.py:244: string foo 13:57:31.960696 435078 pytest DEBUG parse.py:244: string b 13:57:32.279460 435078 pytest DEBUG parse.py:244: add call to set with ['foo', 'b'], {} 13:57:32.556237 435078 pytest DEBUG parse.py:244: followed by key_down($foo).key_up($foo).key_up(a).key_down(a) 13:57:32.579376 435078 pytest DEBUG parse.py:244: calls key_down with $foo 13:57:32.602414 435078 pytest DEBUG parse.py:244: add call to key_down with [], {} 13:57:33.083751 435078 pytest DEBUG parse.py:244: followed by key_up($foo).key_up(a).key_down(a) 13:57:33.122542 435078 pytest DEBUG parse.py:244: calls key_up with $foo 13:57:33.160709 435078 pytest DEBUG parse.py:244: add call to key_up with [], {} 13:57:33.483761 435078 pytest DEBUG parse.py:244: followed by key_up(a).key_down(a) 13:57:33.513945 435078 pytest DEBUG parse.py:244: calls key_up with a 13:57:33.872927 435078 pytest DEBUG parse.py:244: string a 13:57:33.896717 435078 pytest DEBUG parse.py:244: add call to key_up with ['a'], {} 13:57:33.935504 435078 pytest DEBUG parse.py:244: followed by key_down(a) 13:57:34.480379 435078 pytest DEBUG parse.py:244: calls key_down with a 13:57:34.508232 435078 pytest DEBUG parse.py:244: string a 13:57:34.534559 435078 pytest DEBUG parse.py:244: add call to key_down with ['a'], {} 13:57:34.570414 435078 pytest DEBUG macro.py:533: "foo" set to "b" 13:57:34.887653 436062 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'foo', 'b') 13:57:34.893359 435078 pytest DEBUG macro.py:155: "" is "pong" 13:57:34.947176 436062 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'foo') Test: Quick cleanup... 13:57:36.143594 436062 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 13:57:38.908496 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 13:57:40.670485 436064 pytest DEBUG shared_dict.py:63: SharedDict process started 13:57:40.710652 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 13:57:42.489944 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 13:57:42.893351 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 13:57:46.142802 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:57:46.216959 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:57:49.095071 436064 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(foo, b).key_down($foo).key_up($foo).key_up(a).key_down(a) DEBUG input-remapper:parse.py:244 calls set with foo,b DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 string b DEBUG input-remapper:parse.py:244 add call to set with ['foo', 'b'], {} DEBUG input-remapper:parse.py:244 followed by key_down($foo).key_up($foo).key_up(a).key_down(a) DEBUG input-remapper:parse.py:244 calls key_down with $foo DEBUG input-remapper:parse.py:244 add call to key_down with [], {} DEBUG input-remapper:parse.py:244 followed by key_up($foo).key_up(a).key_down(a) DEBUG input-remapper:parse.py:244 calls key_up with $foo DEBUG input-remapper:parse.py:244 add call to key_up with [], {} DEBUG input-remapper:parse.py:244 followed by key_up(a).key_down(a) DEBUG input-remapper:parse.py:244 calls key_up with a DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 add call to key_up with ['a'], {} DEBUG input-remapper:parse.py:244 followed by key_down(a) DEBUG input-remapper:parse.py:244 calls key_down with a DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 add call to key_down with ['a'], {} DEBUG input-remapper:macro.py:533 "foo" set to "b" DEBUG input-remapper:macro.py:155 "" is "pong" WARNING asyncio:base_events.py:1946 Executing exception=MacroParsingError('Unknown key "pong"') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 3.253 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" _________________________ TestMacros.test_macro_breaks _________________________ self = async def test_macro_breaks(self): # the first parameter for `repeat` requires an integer, not "foo", # which makes `repeat` throw macro = parse( 'set(a, "foo").repeat($a, key(KEY_A)).key(KEY_B)', self.context, DummyMapping, ) try: > await macro.run(self.handler) tests/unit/test_macros.py:1045: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = handler = > async def run(self, handler: Callable): """Run the macro. Parameters ---------- handler Will receive int type, code and value for an event to write """ if not callable(handler): raise ValueError("handler is not callable") if self.running: logger.error('Tried to run already running macro "%s"', self.code) return self.keystroke_sleep_ms = self.mapping.macro_key_sleep_ms self.running = True try: for task in self.tasks: coroutine = task(handler) if asyncio.iscoroutine(coroutine): > await coroutine inputremapper/injection/macros/macro.py:267: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ handler = > async def task(handler: Callable): > for _ in range(_resolve(repeats, [int])): inputremapper/injection/macros/macro.py:443: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ argument = , allowed_types = [] def _resolve(argument, allowed_types=None): """If the argument is a variable, figure out its value and cast it. Variables are prefixed with `$` in the syntax. Use this just-in-time when you need the actual value of the variable during runtime. """ if isinstance(argument, Variable): value = argument.resolve() logger.debug('"%s" is "%s"', argument, value) if allowed_types: > return _type_check(value, allowed_types) inputremapper/injection/macros/macro.py:157: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ value = 'pong', allowed_types = [], display_name = None position = None def _type_check(value: Any, allowed_types, display_name=None, position=None) -> Any: """Validate a parameter used in a macro. If the value is a Variable, it will be returned and should be resolved during runtime with _resolve. """ if isinstance(value, Variable): # it is a variable and will be read at runtime return value for allowed_type in allowed_types: if allowed_type is None: if value is None: return value continue # try to parse "1" as 1 if possible if allowed_type != Macro: # the macro constructor with a single argument always succeeds, # but will definitely not result in the correct macro try: return allowed_type(value) except (TypeError, ValueError): pass if isinstance(value, allowed_type): return value if display_name is not None and position is not None: raise MacroParsingError( msg=f"Expected parameter {position} for {display_name} to be " f"one of {allowed_types}, but got {value}" ) > raise MacroParsingError( msg=f"Expected parameter to be one of {allowed_types}, but got {value}" ) E inputremapper.configs.validation_errors.MacroParsingError: Expected parameter to be one of [], but got pong inputremapper/injection/macros/macro.py:127: MacroParsingError During handling of the above exception, another exception occurred: self = async def test_macro_breaks(self): # the first parameter for `repeat` requires an integer, not "foo", # which makes `repeat` throw macro = parse( 'set(a, "foo").repeat($a, key(KEY_A)).key(KEY_B)', self.context, DummyMapping, ) try: await macro.run(self.handler) except MacroParsingError as e: > self.assertIn("foo", str(e)) E AssertionError: 'foo' not found in "Expected parameter to be one of [], but got pong" tests/unit/test_macros.py:1047: AssertionError ----------------------------- Captured stderr call ----------------------------- 13:58:52.581228 435078 pytest WARNING context.py:87: Not forward_devices set 13:58:52.893693 435078 pytest WARNING context.py:90: Not source_devices set 13:58:53.707943 435078 pytest DEBUG parse.py:456: parsing macro set(a, "foo").repeat($a, key(KEY_A)).key(KEY_B) 13:58:53.748459 435078 pytest DEBUG parse.py:244: calls set with a,"foo" 13:58:54.092396 435078 pytest DEBUG parse.py:244: string a 13:58:54.114020 435078 pytest DEBUG parse.py:244: string foo 13:58:54.472068 435078 pytest DEBUG parse.py:244: add call to set with ['a', 'foo'], {} 13:58:54.511927 435078 pytest DEBUG parse.py:244: followed by repeat($a,key(KEY_A)).key(KEY_B) 13:58:54.533776 435078 pytest DEBUG parse.py:244: calls repeat with $a,key(KEY_A) 13:58:54.557900 435078 pytest DEBUG parse.py:244: calls key with KEY_A 13:58:55.080781 435078 pytest DEBUG parse.py:244: string KEY_A 13:58:55.115074 435078 pytest DEBUG parse.py:244: add call to key with ['KEY_A'], {} 13:58:55.485352 435078 pytest DEBUG parse.py:244: add call to repeat with [, ], {} 13:58:55.516022 435078 pytest DEBUG parse.py:244: followed by key(KEY_B) 13:58:55.537575 435078 pytest DEBUG parse.py:244: calls key with KEY_B 13:58:55.563154 435078 pytest DEBUG parse.py:244: string KEY_B 13:58:56.072679 435078 pytest DEBUG parse.py:244: add call to key with ['KEY_B'], {} 13:58:56.129587 435078 pytest DEBUG macro.py:533: "a" set to "foo" 13:58:56.686205 435078 pytest DEBUG macro.py:155: "" is "pong" 13:58:56.684968 436064 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'a', 'foo') 13:58:56.725184 436064 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'a') Test: Quick cleanup... 13:58:57.773287 436064 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 13:59:01.303288 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 13:59:02.318658 436067 pytest DEBUG shared_dict.py:63: SharedDict process started 13:59:02.317885 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 13:59:03.157044 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 13:59:03.695482 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 13:59:06.327117 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:59:06.906102 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 13:59:10.097618 436067 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(a, "foo").repeat($a, key(KEY_A)).key(KEY_B) DEBUG input-remapper:parse.py:244 calls set with a,"foo" DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 add call to set with ['a', 'foo'], {} DEBUG input-remapper:parse.py:244 followed by repeat($a,key(KEY_A)).key(KEY_B) DEBUG input-remapper:parse.py:244 calls repeat with $a,key(KEY_A) DEBUG input-remapper:parse.py:244 calls key with KEY_A DEBUG input-remapper:parse.py:244 string KEY_A DEBUG input-remapper:parse.py:244 add call to key with ['KEY_A'], {} DEBUG input-remapper:parse.py:244 add call to repeat with [, ], {} DEBUG input-remapper:parse.py:244 followed by key(KEY_B) DEBUG input-remapper:parse.py:244 calls key with KEY_B DEBUG input-remapper:parse.py:244 string KEY_B DEBUG input-remapper:parse.py:244 add call to key with ['KEY_B'], {} DEBUG input-remapper:macro.py:533 "a" set to "foo" DEBUG input-remapper:macro.py:155 "" is "pong" WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('\'foo\' not found in "Expected parameter to be one of [], but got pong"') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 3.050 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" ____________________________ TestMacros.test_modify ____________________________ self = async def test_modify(self): code_a = system_mapping.get("a") code_b = system_mapping.get("b") code_c = system_mapping.get("c") macro = parse( "set(foo, b).modify($foo, modify(a, key(c)))", self.context, DummyMapping, ) > await macro.run(self.handler) tests/unit/test_macros.py:606: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ inputremapper/injection/macros/macro.py:267: in run await coroutine inputremapper/injection/macros/macro.py:406: in task code = self._type_check_symbol(resolved_modifier) _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = keyname = 'pong' def _type_check_symbol(self, keyname: Union[str, Variable]) -> Union[Variable, int]: """Same as _type_check, but checks if the key-name is valid.""" if isinstance(keyname, Variable): # it is a variable and will be read at runtime return keyname symbol = str(keyname) code = system_mapping.get(symbol) if code is None: > raise MacroParsingError(msg=f'Unknown key "{symbol}"') E inputremapper.configs.validation_errors.MacroParsingError: Unknown key "pong" inputremapper/injection/macros/macro.py:708: MacroParsingError ----------------------------- Captured stderr call ----------------------------- 14:00:32.553604 435078 pytest WARNING context.py:87: Not forward_devices set 14:00:32.931067 435078 pytest WARNING context.py:90: Not source_devices set 14:00:33.898909 435078 pytest DEBUG parse.py:456: parsing macro set(foo, b).modify($foo, modify(a, key(c))) 14:00:33.936237 435078 pytest DEBUG parse.py:244: calls set with foo,b 14:00:34.315124 435078 pytest DEBUG parse.py:244: string foo 14:00:34.344493 435078 pytest DEBUG parse.py:244: string b 14:00:34.364833 435078 pytest DEBUG parse.py:244: add call to set with ['foo', 'b'], {} 14:00:34.786442 435078 pytest DEBUG parse.py:244: followed by modify($foo,modify(a,key(c))) 14:00:35.292472 435078 pytest DEBUG parse.py:244: calls modify with $foo,modify(a,key(c)) 14:00:35.352123 435078 pytest DEBUG parse.py:244: calls modify with a,key(c) 14:00:35.394208 435078 pytest DEBUG parse.py:244: string a 14:00:35.686353 435078 pytest DEBUG parse.py:244: calls key with c 14:00:35.707523 435078 pytest DEBUG parse.py:244: string c 14:00:35.728039 435078 pytest DEBUG parse.py:244: add call to key with ['c'], {} 14:00:36.277182 435078 pytest DEBUG parse.py:244: add call to modify with ['a', ], {} 14:00:36.342012 435078 pytest DEBUG parse.py:244: add call to modify with [, ], {} 14:00:36.891437 435078 pytest DEBUG macro.py:533: "foo" set to "b" 14:00:36.927631 435078 pytest DEBUG macro.py:155: "" is "pong" 14:00:36.927328 436067 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'foo', 'b') 14:00:36.983454 436067 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'foo') Test: Quick cleanup... 14:00:37.984546 436067 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:00:40.531902 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:00:41.267178 436071 pytest DEBUG shared_dict.py:63: SharedDict process started 14:00:41.258328 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:00:42.699048 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:00:43.099046 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:00:45.548496 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:00:46.138712 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:00:49.771460 436071 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(foo, b).modify($foo, modify(a, key(c))) DEBUG input-remapper:parse.py:244 calls set with foo,b DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 string b DEBUG input-remapper:parse.py:244 add call to set with ['foo', 'b'], {} DEBUG input-remapper:parse.py:244 followed by modify($foo,modify(a,key(c))) DEBUG input-remapper:parse.py:244 calls modify with $foo,modify(a,key(c)) DEBUG input-remapper:parse.py:244 calls modify with a,key(c) DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 calls key with c DEBUG input-remapper:parse.py:244 string c DEBUG input-remapper:parse.py:244 add call to key with ['c'], {} DEBUG input-remapper:parse.py:244 add call to modify with ['a', ], {} DEBUG input-remapper:parse.py:244 add call to modify with [, ], {} DEBUG input-remapper:macro.py:533 "foo" set to "b" DEBUG input-remapper:macro.py:155 "" is "pong" WARNING asyncio:base_events.py:1946 Executing exception=MacroParsingError('Unknown key "pong"') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 3.068 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.398 seconds _________________ TestMacros.test_multiline_macro_and_comments _________________ self = async def test_multiline_macro_and_comments(self): # the parser is not confused by the code in the comments and can use hashtags # in strings in the actual code comment = '# repeat(1,key(KEY_D)).set(a,"#b")' macro = parse( f""" {comment} key(KEY_A).{comment} key(KEY_B). {comment} repeat({comment} 1, {comment} key(KEY_C){comment} ). {comment} {comment} set(a, "#").{comment} if_eq($a, "#", key(KEY_E), key(KEY_F)) {comment} {comment} """, self.context, DummyMapping, ) await macro.run(self.handler) > self.assertListEqual( self.result, [ (EV_KEY, KEY_A, 1), (EV_KEY, KEY_A, 0), (EV_KEY, KEY_B, 1), (EV_KEY, KEY_B, 0), (EV_KEY, KEY_C, 1), (EV_KEY, KEY_C, 0), (EV_KEY, KEY_E, 1), (EV_KEY, KEY_E, 0), ], ) E AssertionError: Lists differ: [(1, [28 chars]1), (1, 48, 0), (1, 46, 1), (1, 46, 0), (1, 33, 1), (1, 33, 0)] != [(1, [28 chars]1), (1, 48, 0), (1, 46, 1), (1, 46, 0), (1, 18, 1), (1, 18, 0)] E E First differing element 6: E (1, 33, 1) E (1, 18, 1) E E [(1, 30, 1), E (1, 30, 0), E (1, 48, 1), E (1, 48, 0), E (1, 46, 1), E (1, 46, 0), E - (1, 33, 1), E ? ^^ E E + (1, 18, 1), E ? ^^ E E - (1, 33, 0)] E ? ^^ E E + (1, 18, 0)] E ? ^^ tests/unit/test_macros.py:1126: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:02:03.164015 435078 pytest WARNING context.py:87: Not forward_devices set 14:02:03.678394 435078 pytest WARNING context.py:90: Not source_devices set 14:02:04.152983 435078 pytest DEBUG parse.py:456: parsing macro # repeat(1,key(KEY_D)).set(a,"#b") key(KEY_A).# repeat(1,key(KEY_D)).set(a,"#b") key(KEY_B). # repeat(1,key(KEY_D)).set(a,"#b") repeat(# repeat(1,key(KEY_D)).set(a,"#b") 1, # repeat(1,key(KEY_D)).set(a,"#b") key(KEY_C)# repeat(1,key(KEY_D)).set(a,"#b") ). # repeat(1,key(KEY_D)).set(a,"#b") # repeat(1,key(KEY_D)).set(a,"#b") set(a, "#").# repeat(1,key(KEY_D)).set(a,"#b") if_eq($a, "#", key(KEY_E), key(KEY_F)) # repeat(1,key(KEY_D)).set(a,"#b") # repeat(1,key(KEY_D)).set(a,"#b") 14:02:04.708868 435078 pytest DEBUG parse.py:244: calls key with KEY_A 14:02:04.734924 435078 pytest DEBUG parse.py:244: string KEY_A 14:02:05.028440 435078 pytest DEBUG parse.py:244: add call to key with ['KEY_A'], {} 14:02:05.088935 435078 pytest DEBUG parse.py:244: followed by key(KEY_B).repeat(1,key(KEY_C)).set(a,"#").if_eq($a,"#",key(KEY_E),key(KEY_F)) 14:02:05.113537 435078 pytest DEBUG parse.py:244: calls key with KEY_B 14:02:05.138051 435078 pytest DEBUG parse.py:244: string KEY_B 14:02:05.711232 435078 pytest DEBUG parse.py:244: add call to key with ['KEY_B'], {} 14:02:05.748590 435078 pytest DEBUG parse.py:244: followed by repeat(1,key(KEY_C)).set(a,"#").if_eq($a,"#",key(KEY_E),key(KEY_F)) 14:02:06.285031 435078 pytest DEBUG parse.py:244: calls repeat with 1,key(KEY_C) 14:02:06.313865 435078 pytest DEBUG parse.py:244: number 1 14:02:06.338645 435078 pytest DEBUG parse.py:244: calls key with KEY_C 14:02:06.717842 435078 pytest DEBUG parse.py:244: string KEY_C 14:02:06.748691 435078 pytest DEBUG parse.py:244: add call to key with ['KEY_C'], {} 14:02:06.776622 435078 pytest DEBUG parse.py:244: add call to repeat with [1, ], {} 14:02:07.306075 435078 pytest DEBUG parse.py:244: followed by set(a,"#").if_eq($a,"#",key(KEY_E),key(KEY_F)) 14:02:07.328781 435078 pytest DEBUG parse.py:244: calls set with a,"#" 14:02:07.675290 435078 pytest DEBUG parse.py:244: string a 14:02:07.713429 435078 pytest DEBUG parse.py:244: string # 14:02:07.736918 435078 pytest DEBUG parse.py:244: add call to set with ['a', '#'], {} 14:02:07.764051 435078 pytest DEBUG parse.py:244: followed by if_eq($a,"#",key(KEY_E),key(KEY_F)) 14:02:08.086390 435078 pytest DEBUG parse.py:244: calls if_eq with $a,"#",key(KEY_E),key(KEY_F) 14:02:08.118218 435078 pytest DEBUG parse.py:244: string # 14:02:08.493039 435078 pytest DEBUG parse.py:244: calls key with KEY_E 14:02:08.516948 435078 pytest DEBUG parse.py:244: string KEY_E 14:02:08.539116 435078 pytest DEBUG parse.py:244: add call to key with ['KEY_E'], {} 14:02:09.083035 435078 pytest DEBUG parse.py:244: calls key with KEY_F 14:02:09.125923 435078 pytest DEBUG parse.py:244: string KEY_F 14:02:09.157396 435078 pytest DEBUG parse.py:244: add call to key with ['KEY_F'], {} 14:02:09.676250 435078 pytest DEBUG parse.py:244: add call to if_eq with [, '#', , ], {} Test: macro wrote(1, 30, 1) Test: macro wrote(1, 30, 0) Test: macro wrote(1, 48, 1) Test: macro wrote(1, 48, 0) Test: macro wrote(1, 46, 1) Test: macro wrote(1, 46, 0) 14:02:11.789663 435078 pytest DEBUG macro.py:533: "a" set to "#" 14:02:11.823495 435078 pytest DEBUG macro.py:155: "" is "pong" 14:02:11.822455 436071 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'a', '#') Test: macro wrote(1, 33, 1) 14:02:11.846919 436071 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'a') Test: macro wrote(1, 33, 0) Test: Quick cleanup... 14:02:14.917124 436071 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:02:18.412511 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:02:19.741906 436073 pytest DEBUG shared_dict.py:63: SharedDict process started 14:02:19.737816 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:02:20.896056 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:02:20.933576 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:02:25.346349 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:02:25.916140 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:02:28.709359 436073 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro # repeat(1,key(KEY_D)).set(a,"#b") key(KEY_A).# repeat(1,key(KEY_D)).set(a,"#b") key(KEY_B). # repeat(1,key(KEY_D)).set(a,"#b") repeat(# repeat(1,key(KEY_D)).set(a,"#b") 1, # repeat(1,key(KEY_D)).set(a,"#b") key(KEY_C)# repeat(1,key(KEY_D)).set(a,"#b") ). # repeat(1,key(KEY_D)).set(a,"#b") # repeat(1,key(KEY_D)).set(a,"#b") set(a, "#").# repeat(1,key(KEY_D)).set(a,"#b") if_eq($a, "#", key(KEY_E), key(KEY_F)) # repeat(1,key(KEY_D)).set(a,"#b") # repeat(1,key(KEY_D)).set(a,"#b") DEBUG input-remapper:parse.py:244 calls key with KEY_A DEBUG input-remapper:parse.py:244 string KEY_A DEBUG input-remapper:parse.py:244 add call to key with ['KEY_A'], {} DEBUG input-remapper:parse.py:244 followed by key(KEY_B).repeat(1,key(KEY_C)).set(a,"#").if_eq($a,"#",key(KEY_E),key(KEY_F)) DEBUG input-remapper:parse.py:244 calls key with KEY_B DEBUG input-remapper:parse.py:244 string KEY_B DEBUG input-remapper:parse.py:244 add call to key with ['KEY_B'], {} DEBUG input-remapper:parse.py:244 followed by repeat(1,key(KEY_C)).set(a,"#").if_eq($a,"#",key(KEY_E),key(KEY_F)) DEBUG input-remapper:parse.py:244 calls repeat with 1,key(KEY_C) DEBUG input-remapper:parse.py:244 number 1 DEBUG input-remapper:parse.py:244 calls key with KEY_C DEBUG input-remapper:parse.py:244 string KEY_C DEBUG input-remapper:parse.py:244 add call to key with ['KEY_C'], {} DEBUG input-remapper:parse.py:244 add call to repeat with [1, ], {} DEBUG input-remapper:parse.py:244 followed by set(a,"#").if_eq($a,"#",key(KEY_E),key(KEY_F)) DEBUG input-remapper:parse.py:244 calls set with a,"#" DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 string # DEBUG input-remapper:parse.py:244 add call to set with ['a', '#'], {} DEBUG input-remapper:parse.py:244 followed by if_eq($a,"#",key(KEY_E),key(KEY_F)) DEBUG input-remapper:parse.py:244 calls if_eq with $a,"#",key(KEY_E),key(KEY_F) DEBUG input-remapper:parse.py:244 string # DEBUG input-remapper:parse.py:244 calls key with KEY_E DEBUG input-remapper:parse.py:244 string KEY_E DEBUG input-remapper:parse.py:244 add call to key with ['KEY_E'], {} DEBUG input-remapper:parse.py:244 calls key with KEY_F DEBUG input-remapper:parse.py:244 string KEY_F DEBUG input-remapper:parse.py:244 add call to key with ['KEY_F'], {} DEBUG input-remapper:parse.py:244 add call to if_eq with [, '#', , ], {} INFO input-remapper-test:test_macros.py:96 macro wrote(1, 30, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 6.176 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 30, 0) INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 1) INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 0) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.339 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 46, 1) INFO input-remapper-test:test_macros.py:96 macro wrote(1, 46, 0) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.576 seconds DEBUG input-remapper:macro.py:533 "a" set to "#" DEBUG input-remapper:macro.py:155 "" is "pong" INFO input-remapper-test:test_macros.py:96 macro wrote(1, 33, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.345 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 33, 0) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.547 seconds WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('Lists differ: [(1, [28 chars]1), (1, 48, 0), (1, 46, 1), (1, 46, 0), (1, 33, 1), (1, 33, 0)] != [(1, [28 chars]1), (1, 48, 0), (1, 46, 1), (1, 46, 0), (1, 18, 1), (1, 18, 0)]\n\nFirst differing element 6:\n(1, 33, 1)\n(1, 18, 1)\n\n [(1, 30, 1),\n (1, 30, 0),\n (1, 48, 1),\n (1, 48, 0),\n (1, 46, 1),\n (1, 46, 0),\n- (1, 33, 1),\n? ^^\n\n+ (1, 18, 1),\n? ^^\n\n- (1, 33, 0)]\n? ^^\n\n+ (1, 18, 0)]\n? ^^\n') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.510 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" ___________________________ TestMacros.test_resolve ____________________________ self = def test_resolve(self): self.assertEqual(_resolve("a"), "a") self.assertEqual(_resolve(1), 1) self.assertEqual(_resolve(None), None) # $ is part of a custom string here self.assertEqual(_resolve('"$a"'), '"$a"') self.assertEqual(_resolve("'$a'"), "'$a'") # variables are expected to be of the Variable type here, not a $string self.assertEqual(_resolve("$a"), "$a") variable = Variable("a") > self.assertEqual(_resolve(variable), None) E AssertionError: 'pong' != None tests/unit/test_macros.py:225: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:06:23.117617 435078 pytest WARNING context.py:87: Not forward_devices set 14:06:23.151814 435078 pytest WARNING context.py:90: Not source_devices set 14:06:23.978163 436085 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'a') 14:06:24.507323 435078 pytest DEBUG macro.py:155: "" is "pong" Test: Quick cleanup... 14:06:25.347136 436085 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:06:27.777963 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:06:29.302991 436087 pytest DEBUG shared_dict.py:63: SharedDict process started 14:06:29.302369 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:06:30.288589 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:06:30.326384 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:06:33.153531 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:06:33.695736 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:06:37.309126 436087 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:macro.py:155 "" is "pong" INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.478 seconds _______________________ TestMacros.test_run_plus_syntax ________________________ self = async def test_run_plus_syntax(self): macro = parse("a + b + c + d", self.context, DummyMapping) macro.press_trigger() asyncio.ensure_future(macro.run(self.handler)) await asyncio.sleep(0.2) self.assertTrue(macro.is_holding()) # starting from the left, presses each one down self.assertEqual(self.result[0], (EV_KEY, system_mapping.get("a"), 1)) > self.assertEqual(self.result[1], (EV_KEY, system_mapping.get("b"), 1)) E IndexError: list index out of range tests/unit/test_macros.py:351: IndexError ----------------------------- Captured stderr call ----------------------------- 14:07:32.712684 435078 pytest WARNING context.py:87: Not forward_devices set 14:07:33.084839 435078 pytest WARNING context.py:90: Not source_devices set 14:07:33.720518 435078 pytest DEBUG parse.py:456: parsing macro a + b + c + d 14:07:33.760166 435078 pytest DEBUG parse.py:391: Transformed "a+b+c+d" to "hold_keys(a,b,c,d)" 14:07:34.902214 435078 pytest DEBUG parse.py:244: calls hold_keys with a,b,c,d 14:07:34.953139 435078 pytest DEBUG parse.py:244: string a 14:07:34.985029 435078 pytest DEBUG parse.py:244: string b 14:07:35.296293 435078 pytest DEBUG parse.py:244: string c 14:07:35.336866 435078 pytest DEBUG parse.py:244: string d 14:07:35.360339 435078 pytest DEBUG parse.py:244: add call to hold_keys with ['a', 'b', 'c', 'd'], {} Test: macro wrote(1, 30, 1) Test: macro wrote(1, 48, 1) Test: macro wrote(1, 46, 1) Test: Quick cleanup... 14:07:38.693362 436087 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:07:41.307123 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:07:41.912539 436089 pytest DEBUG shared_dict.py:63: SharedDict process started 14:07:43.340792 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:07:44.958805 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:07:45.311211 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:07:48.132982 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:07:48.723519 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:07:51.926387 436089 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:07:52.512340 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:07:52.825244 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:07:52.857171 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:07:53.300981 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:07:53.335914 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro a + b + c + d DEBUG input-remapper:parse.py:391 Transformed "a+b+c+d" to "hold_keys(a,b,c,d)" DEBUG input-remapper:parse.py:244 calls hold_keys with a,b,c,d DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 string b DEBUG input-remapper:parse.py:244 string c DEBUG input-remapper:parse.py:244 string d DEBUG input-remapper:parse.py:244 add call to hold_keys with ['a', 'b', 'c', 'd'], {} WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 2.586 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 30, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.385 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 1) WARNING asyncio:base_events.py:1946 Executing ) at /usr/lib64/python3.12/asyncio/base_events.py:180 created at /usr/lib64/python3.12/asyncio/events.py:84> took 0.495 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 46, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.374 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done WARNING asyncio:base_events.py:1946 Executing created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.611 seconds WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.461 seconds WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.326 seconds _____________________________ TestMacros.test_set ______________________________ self = async def test_set(self): await parse('set(a, "foo")', self.context, DummyMapping).run(self.handler) > self.assertEqual(macro_variables.get("a"), "foo") E AssertionError: 'pong' != 'foo' E - pong E + foo tests/unit/test_macros.py:1056: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:08:32.382764 435078 pytest WARNING context.py:87: Not forward_devices set 14:08:32.705486 435078 pytest WARNING context.py:90: Not source_devices set 14:08:33.184601 435078 pytest DEBUG parse.py:456: parsing macro set(a, "foo") 14:08:33.899942 435078 pytest DEBUG parse.py:244: calls set with a,"foo" 14:08:33.947021 435078 pytest DEBUG parse.py:244: string a 14:08:34.284701 435078 pytest DEBUG parse.py:244: string foo 14:08:34.306900 435078 pytest DEBUG parse.py:244: add call to set with ['a', 'foo'], {} 14:08:34.752001 435078 pytest DEBUG macro.py:533: "a" set to "foo" 14:08:34.781377 436089 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'a', 'foo') 14:08:35.110944 436089 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'a') Test: Quick cleanup... 14:08:36.313280 436089 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:08:39.093217 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:08:40.139016 436091 pytest DEBUG shared_dict.py:63: SharedDict process started 14:08:40.137839 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:08:41.518479 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:08:41.552388 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:08:44.493155 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:08:44.554826 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:08:48.377997 436091 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(a, "foo") DEBUG input-remapper:parse.py:244 calls set with a,"foo" DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 add call to set with ['a', 'foo'], {} DEBUG input-remapper:macro.py:533 "a" set to "foo" WARNING asyncio:base_events.py:1946 Executing exception=AssertionError("'pong' != 'foo'\n- pong\n+ foo\n") created at /usr/lib64/python3.12/asyncio/runners.py:100> took 1.935 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" _____________________________ TestIfEq.test_if_eq ______________________________ self = async def test_if_eq(self): """new version of ifeq""" code_a = system_mapping.get("a") code_b = system_mapping.get("b") a_press = [(EV_KEY, code_a, 1), (EV_KEY, code_a, 0)] b_press = [(EV_KEY, code_b, 1), (EV_KEY, code_b, 0)] async def test(macro, expected): """Run the macro and compare the injections with an expectation.""" logger.info("Testing %s", macro) # cleanup macro_variables._clear() self.assertIsNone(macro_variables.get("a")) self.result.clear() # test macro = parse(macro, self.context, DummyMapping) await macro.run(self.handler) self.assertListEqual(self.result, expected) > await test("if_eq(1, 1, key(a), key(b))", a_press) tests/unit/test_macros.py:1221: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ tests/unit/test_macros.py:1213: in test self.assertIsNone(macro_variables.get("a")) E AssertionError: 'pong' is not None ----------------------------- Captured stderr call ----------------------------- 14:10:42.737698 435078 pytest WARNING context.py:87: Not forward_devices set 14:10:43.010417 435078 pytest WARNING context.py:90: Not source_devices set Test: Testing if_eq(1, 1, key(a), key(b)) 14:10:43.556011 436095 pytest DEBUG shared_dict.py:67: SharedDict got ('clear',) 14:10:43.877916 436095 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'a') Test: Quick cleanup... 14:10:45.375417 436095 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:10:48.188567 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:10:49.103229 436097 pytest DEBUG shared_dict.py:63: SharedDict process started 14:10:49.485219 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:10:50.742314 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:10:50.791551 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:10:53.129704 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:10:53.696404 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:10:56.129671 436097 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set INFO input-remapper-test:test_macros.py:1210 Testing if_eq(1, 1, key(a), key(b)) INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.387 seconds ___________________ TestIfEq.test_if_eq_runs_multiprocessed ____________________ self = async def test_if_eq_runs_multiprocessed(self): """ifeq on variables that have been set in other processes works.""" macro = parse("if_eq($foo, 3, key(a), key(b))", self.context, DummyMapping) code_a = system_mapping.get("a") code_b = system_mapping.get("b") self.assertEqual(len(macro.child_macros), 2) def set_foo(value): # will write foo = 2 into the shared dictionary of macros macro_2 = parse(f"set(foo, {value})", self.context, DummyMapping) loop = asyncio.new_event_loop() loop.run_until_complete(macro_2.run(lambda: None)) """foo is not 3""" process = multiprocessing.Process(target=set_foo, args=(2,)) process.start() process.join() await macro.run(self.handler) self.assertListEqual(self.result, [(EV_KEY, code_b, 1), (EV_KEY, code_b, 0)]) """foo is 3""" process = multiprocessing.Process(target=set_foo, args=(3,)) process.start() process.join() await macro.run(self.handler) > self.assertListEqual( self.result, [ (EV_KEY, code_b, 1), (EV_KEY, code_b, 0), (EV_KEY, code_a, 1), (EV_KEY, code_a, 0), ], ) E AssertionError: Lists differ: [(1, 48, 1), (1, 48, 0), (1, 48, 1), (1, 48, 0)] != [(1, 48, 1), (1, 48, 0), (1, 30, 1), (1, 30, 0)] E E First differing element 2: E (1, 48, 1) E (1, 30, 1) E E - [(1, 48, 1), (1, 48, 0), (1, 48, 1), (1, 48, 0)] E ? ^^ ^^ E E + [(1, 48, 1), (1, 48, 0), (1, 30, 1), (1, 30, 0)] E ? ^^ ^^ tests/unit/test_macros.py:1282: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:11:57.700607 435078 pytest WARNING context.py:87: Not forward_devices set 14:11:57.729341 435078 pytest WARNING context.py:90: Not source_devices set 14:11:58.783987 435078 pytest DEBUG parse.py:456: parsing macro if_eq($foo, 3, key(a), key(b)) 14:11:59.237917 435078 pytest DEBUG parse.py:244: calls if_eq with $foo,3,key(a),key(b) 14:11:59.294561 435078 pytest DEBUG parse.py:244: number 3 14:11:59.698166 435078 pytest DEBUG parse.py:244: calls key with a 14:11:59.719844 435078 pytest DEBUG parse.py:244: string a 14:11:59.738910 435078 pytest DEBUG parse.py:244: add call to key with ['a'], {} 14:12:00.302854 435078 pytest DEBUG parse.py:244: calls key with b 14:12:00.327193 435078 pytest DEBUG parse.py:244: string b 14:12:00.346284 435078 pytest DEBUG parse.py:244: add call to key with ['b'], {} 14:12:00.897693 435078 pytest DEBUG parse.py:244: add call to if_eq with [, 3, , ], {} 14:12:02.171167 436100 pytest DEBUG parse.py:456: parsing macro set(foo, 2) 14:12:02.764825 436100 pytest DEBUG parse.py:244: calls set with foo,2 14:12:03.321612 436100 pytest DEBUG parse.py:244: string foo 14:12:03.354982 436100 pytest DEBUG parse.py:244: number 2 14:12:05.284671 436100 pytest DEBUG parse.py:244: add call to set with ['foo', 2], {} 14:12:05.779700 436100 pytest DEBUG macro.py:533: "foo" set to "2" 14:12:06.126739 436097 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'foo', 2) 14:12:06.920046 436097 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'foo') 14:12:06.931182 435078 pytest DEBUG macro.py:155: "" is "pong" Test: macro wrote(1, 48, 1) Test: macro wrote(1, 48, 0) 14:12:10.917040 436101 pytest DEBUG parse.py:456: parsing macro set(foo, 3) 14:12:11.332172 436101 pytest DEBUG parse.py:244: calls set with foo,3 14:12:11.372759 436101 pytest DEBUG parse.py:244: string foo 14:12:11.893724 436101 pytest DEBUG parse.py:244: number 3 14:12:11.915908 436101 pytest DEBUG parse.py:244: add call to set with ['foo', 3], {} 14:12:12.726247 436101 pytest DEBUG macro.py:533: "foo" set to "3" 14:12:13.116529 436097 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'foo', 3) 14:12:13.567357 436097 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'foo') 14:12:13.574839 435078 pytest DEBUG macro.py:155: "" is "2" Test: macro wrote(1, 48, 1) Test: macro wrote(1, 48, 0) Test: Quick cleanup... 14:12:17.958258 436097 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:12:21.336846 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:12:22.543433 436103 pytest DEBUG shared_dict.py:63: SharedDict process started 14:12:22.543074 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:12:23.557211 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:12:23.960452 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:12:26.701158 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:12:26.755976 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:12:29.747733 436103 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro if_eq($foo, 3, key(a), key(b)) DEBUG input-remapper:parse.py:244 calls if_eq with $foo,3,key(a),key(b) DEBUG input-remapper:parse.py:244 number 3 DEBUG input-remapper:parse.py:244 calls key with a DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 add call to key with ['a'], {} DEBUG input-remapper:parse.py:244 calls key with b DEBUG input-remapper:parse.py:244 string b DEBUG input-remapper:parse.py:244 add call to key with ['b'], {} DEBUG input-remapper:parse.py:244 add call to if_eq with [, 3, , ], {} DEBUG input-remapper:macro.py:155 "" is "pong" INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 8.973 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 0) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.773 seconds DEBUG input-remapper:macro.py:155 "" is "2" INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 5.843 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 0) WARNING asyncio:base_events.py:1946 Executing , None) at /usr/lib64/python3.12/asyncio/futures.py:311 created at /usr/lib64/python3.12/asyncio/tasks.py:651> took 0.338 seconds WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('Lists differ: [(1, 48, 1), (1, 48, 0), (1, 48, 1), (1, 48, 0)] != [(1, 48, 1), (1, 48, 0), (1, 30, 1), (1, 30, 0)]\n\nFirst differing element 2:\n(1, 48, 1)\n(1, 30, 1)\n\n- [(1, 48, 1), (1, 48, 0), (1, 48, 1), (1, 48, 0)]\n? ^^ ^^\n\n+ [(1, 48, 1), (1, 48, 0), (1, 30, 1), (1, 30, 0)]\n? ^^ ^^\n') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.838 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.254 seconds ___________________________ TestIfEq.test_ifeq_none ____________________________ self = async def test_ifeq_none(self): code_a = system_mapping.get("a") # first param None macro = parse( "set(foo, 2).ifeq(foo, 2, None, key(b))", self.context, DummyMapping ) self.assertEqual(len(macro.child_macros), 1) await macro.run(self.handler) > self.assertListEqual(self.result, []) E AssertionError: Lists differ: [(1, 48, 1), (1, 48, 0)] != [] E E First list contains 2 additional elements. E First extra element 0: E (1, 48, 1) E E - [(1, 48, 1), (1, 48, 0)] E + [] tests/unit/test_macros.py:1165: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:13:26.132582 435078 pytest WARNING context.py:87: Not forward_devices set 14:13:26.150772 435078 pytest WARNING context.py:90: Not source_devices set 14:13:26.741191 435078 pytest DEBUG parse.py:456: parsing macro set(foo, 2).ifeq(foo, 2, None, key(b)) 14:13:27.120739 435078 pytest DEBUG parse.py:244: calls set with foo,2 14:13:27.157578 435078 pytest DEBUG parse.py:244: string foo 14:13:27.488261 435078 pytest DEBUG parse.py:244: number 2 14:13:27.532385 435078 pytest DEBUG parse.py:244: add call to set with ['foo', 2], {} 14:13:27.920526 435078 pytest DEBUG parse.py:244: followed by ifeq(foo,2,None,key(b)) 14:13:27.955066 435078 pytest DEBUG parse.py:244: calls ifeq with foo,2,None,key(b) 14:13:27.973600 435078 pytest DEBUG parse.py:244: string foo 14:13:27.992134 435078 pytest DEBUG parse.py:244: number 2 14:13:28.538544 435078 pytest DEBUG parse.py:244: calls key with b 14:13:28.560187 435078 pytest DEBUG parse.py:244: string b 14:13:28.579594 435078 pytest DEBUG parse.py:244: add call to key with ['b'], {} 14:13:28.941150 435078 pytest DEBUG parse.py:244: add call to ifeq with ['foo', 2, None, ], {} 14:13:29.334750 435078 pytest DEBUG macro.py:533: "foo" set to "2" 14:13:29.362020 436103 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'foo', 2) 14:13:29.364810 435078 pytest DEBUG macro.py:580: "foo" is "pong" 14:13:29.386092 436103 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'foo') Test: macro wrote(1, 48, 1) Test: macro wrote(1, 48, 0) Test: Quick cleanup... 14:13:31.963029 436103 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:13:35.354598 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:13:36.912021 436105 pytest DEBUG shared_dict.py:63: SharedDict process started 14:13:36.924542 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:13:38.115083 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:13:38.173788 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:13:41.155261 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:13:41.742868 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:13:45.516597 436105 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(foo, 2).ifeq(foo, 2, None, key(b)) DEBUG input-remapper:parse.py:244 calls set with foo,2 DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 number 2 DEBUG input-remapper:parse.py:244 add call to set with ['foo', 2], {} DEBUG input-remapper:parse.py:244 followed by ifeq(foo,2,None,key(b)) DEBUG input-remapper:parse.py:244 calls ifeq with foo,2,None,key(b) DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 number 2 DEBUG input-remapper:parse.py:244 calls key with b DEBUG input-remapper:parse.py:244 string b DEBUG input-remapper:parse.py:244 add call to key with ['b'], {} DEBUG input-remapper:parse.py:244 add call to ifeq with ['foo', 2, None, ], {} DEBUG input-remapper:macro.py:533 "foo" set to "2" DEBUG input-remapper:macro.py:580 "foo" is "pong" INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 3.240 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 0) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.552 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" ___________________________ TestIfEq.test_ifeq_runs ____________________________ self = async def test_ifeq_runs(self): # deprecated ifeq function, but kept for compatibility reasons macro = parse( "set(foo, 2).ifeq(foo, 2, key(a), key(b))", self.context, DummyMapping, ) code_a = system_mapping.get("a") code_b = system_mapping.get("b") await macro.run(self.handler) > self.assertListEqual(self.result, [(EV_KEY, code_a, 1), (EV_KEY, code_a, 0)]) E AssertionError: Lists differ: [(1, 48, 1), (1, 48, 0)] != [(1, 30, 1), (1, 30, 0)] E E First differing element 0: E (1, 48, 1) E (1, 30, 1) E E - [(1, 48, 1), (1, 48, 0)] E ? ^^ ^^ E E + [(1, 30, 1), (1, 30, 0)] E ? ^^ ^^ tests/unit/test_macros.py:1153: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:14:39.753073 435078 pytest WARNING context.py:87: Not forward_devices set 14:14:40.109148 435078 pytest WARNING context.py:90: Not source_devices set 14:14:41.135707 435078 pytest DEBUG parse.py:456: parsing macro set(foo, 2).ifeq(foo, 2, key(a), key(b)) 14:14:41.716457 435078 pytest DEBUG parse.py:244: calls set with foo,2 14:14:41.762937 435078 pytest DEBUG parse.py:244: string foo 14:14:41.805694 435078 pytest DEBUG parse.py:244: number 2 14:14:42.142376 435078 pytest DEBUG parse.py:244: add call to set with ['foo', 2], {} 14:14:42.744967 435078 pytest DEBUG parse.py:244: followed by ifeq(foo,2,key(a),key(b)) 14:14:43.119298 435078 pytest DEBUG parse.py:244: calls ifeq with foo,2,key(a),key(b) 14:14:43.156035 435078 pytest DEBUG parse.py:244: string foo 14:14:43.340858 435078 pytest DEBUG parse.py:244: number 2 14:14:43.754124 435078 pytest DEBUG parse.py:244: calls key with a 14:14:43.832728 435078 pytest DEBUG parse.py:244: string a 14:14:44.292799 435078 pytest DEBUG parse.py:244: add call to key with ['a'], {} 14:14:44.329673 435078 pytest DEBUG parse.py:244: calls key with b 14:14:44.887535 435078 pytest DEBUG parse.py:244: string b 14:14:44.908113 435078 pytest DEBUG parse.py:244: add call to key with ['b'], {} 14:14:44.947238 435078 pytest DEBUG parse.py:244: add call to ifeq with ['foo', 2, , ], {} 14:14:44.981718 435078 pytest DEBUG macro.py:533: "foo" set to "2" 14:14:45.008094 435078 pytest DEBUG macro.py:580: "foo" is "pong" 14:14:45.006925 436105 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 'foo', 2) Test: macro wrote(1, 48, 1) 14:14:45.440771 436105 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'foo') Test: macro wrote(1, 48, 0) Test: Quick cleanup... 14:14:48.087774 436105 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:14:50.588642 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:14:51.915258 436110 pytest DEBUG shared_dict.py:63: SharedDict process started 14:14:51.929152 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:14:52.728772 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:14:53.102757 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:14:55.362796 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:14:55.752170 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:14:59.355810 436110 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(foo, 2).ifeq(foo, 2, key(a), key(b)) DEBUG input-remapper:parse.py:244 calls set with foo,2 DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 number 2 DEBUG input-remapper:parse.py:244 add call to set with ['foo', 2], {} DEBUG input-remapper:parse.py:244 followed by ifeq(foo,2,key(a),key(b)) DEBUG input-remapper:parse.py:244 calls ifeq with foo,2,key(a),key(b) DEBUG input-remapper:parse.py:244 string foo DEBUG input-remapper:parse.py:244 number 2 DEBUG input-remapper:parse.py:244 calls key with a DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 add call to key with ['a'], {} DEBUG input-remapper:parse.py:244 calls key with b DEBUG input-remapper:parse.py:244 string b DEBUG input-remapper:parse.py:244 add call to key with ['b'], {} DEBUG input-remapper:parse.py:244 add call to ifeq with ['foo', 2, , ], {} DEBUG input-remapper:macro.py:533 "foo" set to "2" DEBUG input-remapper:macro.py:580 "foo" is "pong" INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 4.588 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 0) WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('Lists differ: [(1, 48, 1), (1, 48, 0)] != [(1, 30, 1), (1, 30, 0)]\n\nFirst differing element 0:\n(1, 48, 1)\n(1, 30, 1)\n\n- [(1, 48, 1), (1, 48, 0)]\n? ^^ ^^\n\n+ [(1, 30, 1), (1, 30, 0)]\n? ^^ ^^\n') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.591 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" ________________________ TestIfEq.test_ifeq_unknown_key ________________________ self = def tearDown(self): self.result = [] > quick_cleanup() tests/unit/test_macros.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ log = True def quick_cleanup(log=True): """Reset the applications state.""" # Reminder: before patches are applied in test.py, no inputremapper module # may be imported. So tests.lib imports them just-in-time in functions instead. from inputremapper.injection.macros.macro import macro_variables from inputremapper.configs.global_config import global_config from inputremapper.configs.system_mapping import system_mapping from inputremapper.gui.utils import debounce_manager from inputremapper.configs.paths import get_config_path from inputremapper.injection.global_uinputs import global_uinputs from tests.lib.global_uinputs import reset_global_uinputs_for_service if log: logger.info("Quick cleanup...") debounce_manager.stop_all() for device in list(pending_events.keys()): try: while pending_events[device][1].poll(): pending_events[device][1].recv() except (UnpicklingError, EOFError): pass # setup new pipes for the next test pending_events[device][1].close() pending_events[device][0].close() del pending_events[device] setup_pipe(device) try: if asyncio.get_event_loop().is_running(): for task in asyncio.all_tasks(): task.cancel() except RuntimeError: # happens when the event loop disappears for magical reasons # create a fresh event loop asyncio.set_event_loop(asyncio.new_event_loop()) if macro_variables.process is not None and not macro_variables.process.is_alive(): # nothing should stop the process during runtime, if it has been started by # the injector once raise AssertionError("the SharedDict manager is not running anymore") if macro_variables.process is not None: macro_variables._stop() join_children() macro_variables.start() if os.path.exists(tmp): shutil.rmtree(tmp) global_config.path = os.path.join(get_config_path(), "config.json") global_config.clear_config() global_config._save_config() system_mapping.populate() clear_write_history() for name in list(uinputs.keys()): del uinputs[name] # for device in list(active_macros.keys()): # del active_macros[device] # for device in list(unreleased.keys()): # del unreleased[device] fixtures.reset() os.environ.update(environ_copy) for device in list(os.environ.keys()): if device not in environ_copy: del os.environ[device] for _, pipe in pending_events.values(): assert not pipe.poll() > assert macro_variables.is_alive(1) E AssertionError tests/lib/cleanup.py:152: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:15:54.550286 435078 pytest WARNING context.py:87: Not forward_devices set 14:15:54.572311 435078 pytest WARNING context.py:90: Not source_devices set 14:15:55.070724 435078 pytest DEBUG parse.py:456: parsing macro ifeq(qux, 2, key(a), key(b)) 14:15:55.704252 435078 pytest DEBUG parse.py:244: calls ifeq with qux,2,key(a),key(b) 14:15:55.733688 435078 pytest DEBUG parse.py:244: string qux 14:15:56.093922 435078 pytest DEBUG parse.py:244: number 2 14:15:56.119302 435078 pytest DEBUG parse.py:244: calls key with a 14:15:56.143103 435078 pytest DEBUG parse.py:244: string a 14:15:56.163433 435078 pytest DEBUG parse.py:244: add call to key with ['a'], {} 14:15:56.744469 435078 pytest DEBUG parse.py:244: calls key with b 14:15:57.107877 435078 pytest DEBUG parse.py:244: string b 14:15:57.139225 435078 pytest DEBUG parse.py:244: add call to key with ['b'], {} 14:15:57.178060 435078 pytest DEBUG parse.py:244: add call to ifeq with ['qux', 2, , ], {} 14:15:57.723807 435078 pytest DEBUG macro.py:580: "qux" is "pong" 14:15:57.724087 436110 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 'qux') Test: macro wrote(1, 48, 1) Test: macro wrote(1, 48, 0) Test: Quick cleanup... 14:16:00.099921 436110 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:16:03.142788 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:16:04.539904 436114 pytest DEBUG shared_dict.py:63: SharedDict process started 14:16:04.539424 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:16:05.752533 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:16:05.789602 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:16:08.700057 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:16:08.771049 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:16:11.885834 436114 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro ifeq(qux, 2, key(a), key(b)) DEBUG input-remapper:parse.py:244 calls ifeq with qux,2,key(a),key(b) DEBUG input-remapper:parse.py:244 string qux DEBUG input-remapper:parse.py:244 number 2 DEBUG input-remapper:parse.py:244 calls key with a DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 add call to key with ['a'], {} DEBUG input-remapper:parse.py:244 calls key with b DEBUG input-remapper:parse.py:244 string b DEBUG input-remapper:parse.py:244 add call to key with ['b'], {} DEBUG input-remapper:parse.py:244 add call to ifeq with ['qux', 2, , ], {} DEBUG input-remapper:macro.py:580 "qux" is "pong" INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 3.039 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 0) INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.415 seconds _______________________ TestIfSingle.test_if_not_single ________________________ self = async def test_if_not_single(self): # Will run the `else` macro if another key is pressed. # Also works if if_single is a child macro, i.e. the event is passed to it # from the outside macro correctly. macro = parse( "repeat(1, if_single(then=key(x), else=key(y)))", self.context, DummyMapping, ) self.assertEqual(len(macro.child_macros), 1) self.assertEqual(len(macro.child_macros[0].child_macros), 2) a = system_mapping.get("a") b = system_mapping.get("b") x = system_mapping.get("x") y = system_mapping.get("y") # press the trigger key await self.trigger_sequence(macro, InputEvent.key(a, 1)) await asyncio.sleep(0.1) # press another key for listener in self.context.listeners: asyncio.ensure_future(listener(InputEvent.key(b, 1))) await asyncio.sleep(0.1) > self.assertListEqual(self.result, [(EV_KEY, y, 1), (EV_KEY, y, 0)]) E AssertionError: Lists differ: [] != [(1, 44, 1), (1, 44, 0)] E E Second list contains 2 additional elements. E First extra element 0: E (1, 44, 1) E E - [] E + [(1, 44, 1), (1, 44, 0)] tests/unit/test_macros.py:1374: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:16:52.388765 435078 pytest WARNING context.py:87: Not forward_devices set 14:16:52.658029 435078 pytest WARNING context.py:90: Not source_devices set 14:16:53.686719 435078 pytest DEBUG parse.py:456: parsing macro repeat(1, if_single(then=key(x), else=key(y))) 14:16:53.743590 435078 pytest DEBUG parse.py:244: calls repeat with 1,if_single(then=key(x),else=key(y)) 14:16:53.774748 435078 pytest DEBUG parse.py:244: number 1 14:16:54.315917 435078 pytest DEBUG parse.py:244: calls if_single with then=key(x),else=key(y) 14:16:54.353096 435078 pytest DEBUG parse.py:244: calls key with x 14:16:54.878471 435078 pytest DEBUG parse.py:244: string x 14:16:54.900516 435078 pytest DEBUG parse.py:244: add call to key with ['x'], {} 14:16:54.943069 435078 pytest DEBUG parse.py:244: calls key with y 14:16:54.963194 435078 pytest DEBUG parse.py:244: string y 14:16:55.298712 435078 pytest DEBUG parse.py:244: add call to key with ['y'], {} 14:16:55.690991 435078 pytest DEBUG parse.py:244: add call to if_single with [], {'then': , 'else': } 14:16:55.729683 435078 pytest DEBUG parse.py:244: add call to repeat with [1, ], {} Test: macro wrote(1, 44, 1) Test: macro wrote(1, 44, 0) Test: Quick cleanup... 14:17:00.988303 436114 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:17:04.154734 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:17:06.159208 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:17:06.188676 436115 pytest DEBUG shared_dict.py:63: SharedDict process started 14:17:07.696801 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:17:07.737013 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:17:10.333048 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:17:10.729027 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:17:14.529790 436115 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:17:15.119300 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:17:15.162337 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:17:15.189420 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:17:15.720486 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:17:15.743200 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro repeat(1, if_single(then=key(x), else=key(y))) DEBUG input-remapper:parse.py:244 calls repeat with 1,if_single(then=key(x),else=key(y)) DEBUG input-remapper:parse.py:244 number 1 DEBUG input-remapper:parse.py:244 calls if_single with then=key(x),else=key(y) DEBUG input-remapper:parse.py:244 calls key with x DEBUG input-remapper:parse.py:244 string x DEBUG input-remapper:parse.py:244 add call to key with ['x'], {} DEBUG input-remapper:parse.py:244 calls key with y DEBUG input-remapper:parse.py:244 string y DEBUG input-remapper:parse.py:244 add call to key with ['y'], {} DEBUG input-remapper:parse.py:244 add call to if_single with [], {'then': , 'else': } DEBUG input-remapper:parse.py:244 add call to repeat with [1, ], {} WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 3.009 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.636 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_wait.._on_completion() at /usr/lib64/python3.12/asyncio/tasks.py:524] created at /builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py:680> took 0.308 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_wait.._on_completion() at /usr/lib64/python3.12/asyncio/tasks.py:524] created at /builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py:681> took 0.340 seconds WARNING asyncio:base_events.py:1946 Executing .task..listener() done, defined at /builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py:665> result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.509 seconds WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('Lists differ: [] != [(1, 44, 1), (1, 44, 0)]\n\nSecond list contains 2 additional elements.\nFirst extra element 0:\n(1, 44, 1)\n\n- []\n+ [(1, 44, 1), (1, 44, 0)]') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.604 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 44, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.733 seconds WARNING asyncio:base_events.py:1946 Executing , None) at /usr/lib64/python3.12/asyncio/futures.py:311 created at /usr/lib64/python3.12/asyncio/tasks.py:651> took 0.302 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 44, 0) INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done WARNING asyncio:base_events.py:1946 Executing created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.355 seconds WARNING asyncio:base_events.py:1946 Executing ) at /usr/lib64/python3.12/asyncio/base_events.py:180 created at /usr/lib64/python3.12/asyncio/tasks.py:810> took 0.504 seconds WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.315 seconds _________________________ TestIfSingle.test_if_single __________________________ self = async def test_if_single(self): macro = parse("if_single(key(x), key(y))", self.context, DummyMapping) self.assertEqual(len(macro.child_macros), 2) a = system_mapping.get("a") x = system_mapping.get("x") y = system_mapping.get("y") await self.trigger_sequence(macro, InputEvent.key(a, 1)) await asyncio.sleep(0.1) await self.release_sequence(macro, InputEvent.key(a, 0)) # the key that triggered the macro is released await asyncio.sleep(0.1) > self.assertListEqual(self.result, [(EV_KEY, x, 1), (EV_KEY, x, 0)]) E AssertionError: Lists differ: [] != [(1, 45, 1), (1, 45, 0)] E E Second list contains 2 additional elements. E First extra element 0: E (1, 45, 1) E E - [] E + [(1, 45, 1), (1, 45, 0)] tests/unit/test_macros.py:1309: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:18:22.717627 435078 pytest WARNING context.py:87: Not forward_devices set 14:18:22.760468 435078 pytest WARNING context.py:90: Not source_devices set 14:18:23.739355 435078 pytest DEBUG parse.py:456: parsing macro if_single(key(x), key(y)) 14:18:24.142974 435078 pytest DEBUG parse.py:244: calls if_single with key(x),key(y) 14:18:24.178028 435078 pytest DEBUG parse.py:244: calls key with x 14:18:24.712633 435078 pytest DEBUG parse.py:244: string x 14:18:24.755027 435078 pytest DEBUG parse.py:244: add call to key with ['x'], {} 14:18:25.156354 435078 pytest DEBUG parse.py:244: calls key with y 14:18:25.690431 435078 pytest DEBUG parse.py:244: string y 14:18:25.734955 435078 pytest DEBUG parse.py:244: add call to key with ['y'], {} 14:18:25.782207 435078 pytest DEBUG parse.py:244: add call to if_single with [, ], {} Test: macro wrote(1, 45, 1) Test: macro wrote(1, 45, 0) Test: Quick cleanup... 14:18:32.379055 436117 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:18:35.387528 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:18:36.973942 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:18:36.997988 436118 pytest DEBUG shared_dict.py:63: SharedDict process started 14:18:37.583390 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:18:37.982329 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:18:40.696810 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:18:40.766836 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:18:44.164280 436118 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:18:44.178595 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:18:44.735661 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:18:44.766406 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:18:45.294863 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:18:45.320825 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro if_single(key(x), key(y)) DEBUG input-remapper:parse.py:244 calls if_single with key(x),key(y) DEBUG input-remapper:parse.py:244 calls key with x DEBUG input-remapper:parse.py:244 string x DEBUG input-remapper:parse.py:244 add call to key with ['x'], {} DEBUG input-remapper:parse.py:244 calls key with y DEBUG input-remapper:parse.py:244 string y DEBUG input-remapper:parse.py:244 add call to key with ['y'], {} DEBUG input-remapper:parse.py:244 add call to if_single with [, ], {} WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 2.990 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.791 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_wait.._on_completion() at /usr/lib64/python3.12/asyncio/tasks.py:524] created at /builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py:681> took 0.511 seconds WARNING asyncio:base_events.py:1946 Executing , None) at /usr/lib64/python3.12/asyncio/futures.py:311 created at /usr/lib64/python3.12/asyncio/tasks.py:651> took 0.583 seconds WARNING asyncio:base_events.py:1946 Executing cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.580 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.400 seconds WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('Lists differ: [] != [(1, 45, 1), (1, 45, 0)]\n\nSecond list contains 2 additional elements.\nFirst extra element 0:\n(1, 45, 1)\n\n- []\n+ [(1, 45, 1), (1, 45, 0)]') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.527 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 45, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.355 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 45, 0) INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done _________________ TestIfSingle.test_if_single_ignores_joystick _________________ self = async def test_if_single_ignores_joystick(self): """Triggers else + delayed_handle_keycode.""" # Integration test style for if_single. # If a joystick that is mapped to a button is moved, if_single stops macro = parse("if_single(k(a), k(KEY_LEFTSHIFT))", self.context, DummyMapping) code_shift = system_mapping.get("KEY_LEFTSHIFT") code_a = system_mapping.get("a") trigger = 1 await self.trigger_sequence(macro, InputEvent.key(trigger, 1)) await asyncio.sleep(0.1) for listener in self.context.listeners: asyncio.ensure_future(listener(InputEvent.abs(ABS_Y, 10))) await asyncio.sleep(0.1) await self.release_sequence(macro, InputEvent.key(trigger, 0)) await asyncio.sleep(0.1) > self.assertFalse(macro.running) E AssertionError: True is not false tests/unit/test_macros.py:1436: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:19:21.750751 435078 pytest WARNING context.py:87: Not forward_devices set 14:19:21.790799 435078 pytest WARNING context.py:90: Not source_devices set 14:19:23.084903 435078 pytest DEBUG parse.py:456: parsing macro if_single(k(a), k(KEY_LEFTSHIFT)) 14:19:23.117427 435078 pytest DEBUG parse.py:244: calls if_single with k(a),k(KEY_LEFTSHIFT) 14:19:23.141919 435078 pytest DEBUG parse.py:244: calls k with a 14:19:23.161236 435078 pytest DEBUG parse.py:244: string a 14:19:23.180100 435078 pytest DEBUG parse.py:244: add call to k with ['a'], {} 14:19:23.928089 435078 pytest DEBUG parse.py:244: calls k with KEY_LEFTSHIFT 14:19:23.952428 435078 pytest DEBUG parse.py:244: string KEY_LEFTSHIFT 14:19:23.970597 435078 pytest DEBUG parse.py:244: add call to k with ['KEY_LEFTSHIFT'], {} 14:19:24.323819 435078 pytest DEBUG parse.py:244: add call to if_single with [, ], {} Test: macro wrote(1, 30, 1) Test: macro wrote(1, 30, 0) Test: Quick cleanup... 14:19:28.788670 436118 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:19:31.685046 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:19:32.715271 436120 pytest DEBUG shared_dict.py:63: SharedDict process started 14:19:32.714117 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:19:33.754746 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:19:33.792803 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:19:36.534034 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:19:36.583559 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:19:40.164058 436120 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:19:40.181042 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:19:40.737528 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:19:40.805107 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:19:41.305478 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:19:41.351680 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro if_single(k(a), k(KEY_LEFTSHIFT)) DEBUG input-remapper:parse.py:244 calls if_single with k(a),k(KEY_LEFTSHIFT) DEBUG input-remapper:parse.py:244 calls k with a DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 add call to k with ['a'], {} DEBUG input-remapper:parse.py:244 calls k with KEY_LEFTSHIFT DEBUG input-remapper:parse.py:244 string KEY_LEFTSHIFT DEBUG input-remapper:parse.py:244 add call to k with ['KEY_LEFTSHIFT'], {} DEBUG input-remapper:parse.py:244 add call to if_single with [, ], {} WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 1.962 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.405 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_wait.._on_completion() at /usr/lib64/python3.12/asyncio/tasks.py:524] created at /builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py:680> took 0.191 seconds WARNING asyncio:base_events.py:1946 Executing cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.544 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 30, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.536 seconds WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('True is not false') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.355 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 30, 0) WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.327 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done WARNING asyncio:base_events.py:1946 Executing created at /builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py:680> took 0.515 seconds _________________ TestIfSingle.test_if_single_ignores_releases _________________ self = async def test_if_single_ignores_releases(self): # the timeout won't break the macro, everything happens well within that # timeframe. macro = parse( "if_single(key(x), else=key(y), timeout=100000)", self.context, DummyMapping, ) self.assertEqual(len(macro.child_macros), 2) a = system_mapping.get("a") b = system_mapping.get("b") x = system_mapping.get("x") y = system_mapping.get("y") # pressing the macro key await self.trigger_sequence(macro, InputEvent.key(a, 1)) await asyncio.sleep(0.05) # if_single only looks out for newly pressed keys, # it doesn't care if keys were released that have been # pressed before if_single. This was decided because it is a lot # less tricky and more fluently to use if you type fast for listener in self.context.listeners: asyncio.ensure_future(listener(InputEvent.key(b, 0))) await asyncio.sleep(0.05) self.assertListEqual(self.result, []) # releasing the actual key triggers if_single await asyncio.sleep(0.05) await self.release_sequence(macro, InputEvent.key(a, 0)) await asyncio.sleep(0.05) > self.assertListEqual(self.result, [(EV_KEY, x, 1), (EV_KEY, x, 0)]) E AssertionError: Lists differ: [] != [(1, 45, 1), (1, 45, 0)] E E Second list contains 2 additional elements. E First extra element 0: E (1, 45, 1) E E - [] E + [(1, 45, 1), (1, 45, 0)] tests/unit/test_macros.py:1345: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:20:18.172721 435078 pytest WARNING context.py:87: Not forward_devices set 14:20:18.193887 435078 pytest WARNING context.py:90: Not source_devices set 14:20:19.027307 435078 pytest DEBUG parse.py:456: parsing macro if_single(key(x), else=key(y), timeout=100000) 14:20:19.547400 435078 pytest DEBUG parse.py:244: calls if_single with key(x),else=key(y),timeout=100000 14:20:19.907586 435078 pytest DEBUG parse.py:244: calls key with x 14:20:19.928227 435078 pytest DEBUG parse.py:244: string x 14:20:19.948241 435078 pytest DEBUG parse.py:244: add call to key with ['x'], {} 14:20:20.188161 435078 pytest DEBUG parse.py:244: calls key with y 14:20:20.716177 435078 pytest DEBUG parse.py:244: string y 14:20:20.738974 435078 pytest DEBUG parse.py:244: add call to key with ['y'], {} 14:20:20.768506 435078 pytest DEBUG parse.py:244: number 100000 14:20:21.119788 435078 pytest DEBUG parse.py:244: add call to if_single with [], {'else': , 'timeout': 100000} Test: macro wrote(1, 45, 1) Test: macro wrote(1, 45, 0) Test: Quick cleanup... 14:20:28.944611 436120 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:20:31.347258 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:20:32.578665 436122 pytest DEBUG shared_dict.py:63: SharedDict process started 14:20:32.579469 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:20:34.138374 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:20:34.516347 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:20:37.714641 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:20:38.112178 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:20:41.522488 436122 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:20:41.562839 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:20:42.695776 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:20:42.745487 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:20:42.778848 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:20:42.804812 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro if_single(key(x), else=key(y), timeout=100000) DEBUG input-remapper:parse.py:244 calls if_single with key(x),else=key(y),timeout=100000 DEBUG input-remapper:parse.py:244 calls key with x DEBUG input-remapper:parse.py:244 string x DEBUG input-remapper:parse.py:244 add call to key with ['x'], {} DEBUG input-remapper:parse.py:244 calls key with y DEBUG input-remapper:parse.py:244 string y DEBUG input-remapper:parse.py:244 add call to key with ['y'], {} DEBUG input-remapper:parse.py:244 number 100000 DEBUG input-remapper:parse.py:244 add call to if_single with [], {'else': , 'timeout': 100000} WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 2.752 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.457 seconds WARNING asyncio:base_events.py:1946 Executing , None) at /usr/lib64/python3.12/asyncio/futures.py:311 created at /usr/lib64/python3.12/asyncio/tasks.py:651> took 0.528 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.610 seconds WARNING asyncio:base_events.py:1946 Executing , None) at /usr/lib64/python3.12/asyncio/futures.py:311 created at /usr/lib64/python3.12/asyncio/tasks.py:651> took 0.160 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.903 seconds WARNING asyncio:base_events.py:1946 Executing ._on_completion() at /usr/lib64/python3.12/asyncio/tasks.py:524 created at /usr/lib64/python3.12/asyncio/events.py:84> took 0.822 seconds WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('Lists differ: [] != [(1, 45, 1), (1, 45, 0)]\n\nSecond list contains 2 additional elements.\nFirst extra element 0:\n(1, 45, 1)\n\n- []\n+ [(1, 45, 1), (1, 45, 0)]') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.602 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 45, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.539 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 45, 0) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.546 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done WARNING asyncio:base_events.py:1946 Executing created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.575 seconds WARNING asyncio:base_events.py:1946 Executing ) at /usr/lib64/python3.12/asyncio/base_events.py:180 created at /usr/lib64/python3.12/asyncio/tasks.py:810> took 0.296 seconds ____________________ TestIfSingle.test_if_single_times_out _____________________ self = async def test_if_single_times_out(self): macro = parse( "set(t, 300).if_single(key(x), key(y), timeout=$t)", self.context, DummyMapping, ) self.assertEqual(len(macro.child_macros), 2) a = system_mapping.get("a") y = system_mapping.get("y") await self.trigger_sequence(macro, InputEvent.key(a, 1)) # no timeout yet await asyncio.sleep(0.2) self.assertListEqual(self.result, []) > self.assertTrue(macro.running) E AssertionError: False is not true tests/unit/test_macros.py:1413: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:21:23.269828 435078 pytest WARNING context.py:87: Not forward_devices set 14:21:23.308705 435078 pytest WARNING context.py:90: Not source_devices set 14:21:23.773011 435078 pytest DEBUG parse.py:456: parsing macro set(t, 300).if_single(key(x), key(y), timeout=$t) 14:21:24.332271 435078 pytest DEBUG parse.py:244: calls set with t,300 14:21:24.361449 435078 pytest DEBUG parse.py:244: string t 14:21:24.380469 435078 pytest DEBUG parse.py:244: number 300 14:21:24.704725 435078 pytest DEBUG parse.py:244: add call to set with ['t', 300], {} 14:21:25.294786 435078 pytest DEBUG parse.py:244: followed by if_single(key(x),key(y),timeout=$t) 14:21:25.501384 435078 pytest DEBUG parse.py:244: calls if_single with key(x),key(y),timeout=$t 14:21:25.525678 435078 pytest DEBUG parse.py:244: calls key with x 14:21:25.549911 435078 pytest DEBUG parse.py:244: string x 14:21:25.570033 435078 pytest DEBUG parse.py:244: add call to key with ['x'], {} 14:21:26.110936 435078 pytest DEBUG parse.py:244: calls key with y 14:21:26.134248 435078 pytest DEBUG parse.py:244: string y 14:21:26.154481 435078 pytest DEBUG parse.py:244: add call to key with ['y'], {} 14:21:26.179831 435078 pytest DEBUG parse.py:244: add call to if_single with [, ], {'timeout': } 14:21:27.152445 435078 pytest DEBUG macro.py:533: "t" set to "300" 14:21:27.506799 436122 pytest DEBUG shared_dict.py:67: SharedDict got ('set', 't', 300) 14:21:27.515965 435078 pytest DEBUG macro.py:155: "" is "pong" 14:21:27.557024 436122 pytest DEBUG shared_dict.py:67: SharedDict got ('get', 't') Test: Quick cleanup... 14:21:29.199120 436122 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:21:32.719412 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:21:34.072975 436125 pytest DEBUG shared_dict.py:63: SharedDict process started 14:21:34.117531 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:21:34.971810 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:21:35.358946 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:21:38.890641 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:21:38.941310 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:21:42.159664 436125 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro set(t, 300).if_single(key(x), key(y), timeout=$t) DEBUG input-remapper:parse.py:244 calls set with t,300 DEBUG input-remapper:parse.py:244 string t DEBUG input-remapper:parse.py:244 number 300 DEBUG input-remapper:parse.py:244 add call to set with ['t', 300], {} DEBUG input-remapper:parse.py:244 followed by if_single(key(x),key(y),timeout=$t) DEBUG input-remapper:parse.py:244 calls if_single with key(x),key(y),timeout=$t DEBUG input-remapper:parse.py:244 calls key with x DEBUG input-remapper:parse.py:244 string x DEBUG input-remapper:parse.py:244 add call to key with ['x'], {} DEBUG input-remapper:parse.py:244 calls key with y DEBUG input-remapper:parse.py:244 string y DEBUG input-remapper:parse.py:244 add call to key with ['y'], {} DEBUG input-remapper:parse.py:244 add call to if_single with [, ], {'timeout': } WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 3.367 seconds DEBUG input-remapper:macro.py:533 "t" set to "300" DEBUG input-remapper:macro.py:155 "" is "pong" WARNING asyncio:base_events.py:1946 Executing exception=MacroParsingError("Expected parameter to be one of [, , None], but got pong") created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.411 seconds ERROR asyncio:base_events.py:1785 Task exception was never retrieved future: exception=MacroParsingError("Expected parameter to be one of [, , None], but got pong") created at /usr/lib64/python3.12/asyncio/tasks.py:685> source_traceback: Object created at (most recent call last): File "/usr/bin/pytest", line 8, in sys.exit(console_main()) File "/usr/lib/python3.12/site-packages/_pytest/config/__init__.py", line 189, in console_main code = main() File "/usr/lib/python3.12/site-packages/_pytest/config/__init__.py", line 166, in main ret: Union[ExitCode, int] = config.hook.pytest_cmdline_main( File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 316, in pytest_cmdline_main return wrap_session(config, _main) File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 269, in wrap_session session.exitstatus = doit(config, session) or 0 File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 323, in _main config.hook.pytest_runtestloop(session=session) File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 348, in pytest_runtestloop item.config.hook.pytest_runtest_protocol(item=item, nextitem=nextitem) File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 114, in pytest_runtest_protocol runtestprotocol(item, nextitem=nextitem) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 133, in runtestprotocol reports.append(call_and_report(item, "call", log)) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 222, in call_and_report call = call_runtest_hook(item, when, **kwds) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 261, in call_runtest_hook return CallInfo.from_call( File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 341, in from_call result: Optional[TResult] = func() File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 262, in lambda: ihook(item=item, **kwds), when=when, reraise=reraise File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 169, in pytest_runtest_call item.runtest() File "/usr/lib/python3.12/site-packages/_pytest/unittest.py", line 314, in runtest self._testcase(result=self) # type: ignore[arg-type] File "/usr/lib64/python3.12/unittest/case.py", line 690, in __call__ return self.run(*args, **kwds) File "/usr/lib64/python3.12/unittest/async_case.py", line 131, in run return super().run(result) File "/usr/lib64/python3.12/unittest/case.py", line 634, in run self._callTestMethod(testMethod) File "/usr/lib64/python3.12/unittest/async_case.py", line 90, in _callTestMethod if self._callMaybeAsync(method) is not None: File "/usr/lib64/python3.12/unittest/async_case.py", line 112, in _callMaybeAsync return self._asyncioRunner.run( File "/usr/lib64/python3.12/asyncio/runners.py", line 118, in run return self._loop.run_until_complete(task) File "/usr/lib64/python3.12/asyncio/base_events.py", line 651, in run_until_complete self.run_forever() File "/usr/lib64/python3.12/asyncio/base_events.py", line 618, in run_forever self._run_once() File "/usr/lib64/python3.12/asyncio/base_events.py", line 1943, in _run_once handle._run() File "/usr/lib64/python3.12/asyncio/events.py", line 84, in _run self._context.run(self._callback, *self._args) File "/builddir/build/BUILD/input-remapper-2.0.1/tests/unit/test_macros.py", line 1408, in test_if_single_times_out await self.trigger_sequence(macro, InputEvent.key(a, 1)) File "/builddir/build/BUILD/input-remapper-2.0.1/tests/unit/test_macros.py", line 108, in trigger_sequence asyncio.ensure_future(macro.run(self.handler)) File "/usr/lib64/python3.12/asyncio/tasks.py", line 685, in ensure_future return loop.create_task(coro_or_future) Traceback (most recent call last): File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py", line 267, in run await coroutine File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py", line 677, in task resolved_timeout = _resolve(timeout, allowed_types=[int, float, None]) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py", line 157, in _resolve return _type_check(value, allowed_types) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/macros/macro.py", line 127, in _type_check raise MacroParsingError( inputremapper.configs.validation_errors.MacroParsingError: Expected parameter to be one of [, , None], but got pong WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('False is not true') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.323 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" _________________________ TestIfTap.test_if_double_tap _________________________ self = async def test_if_double_tap(self): macro = parse( "if_tap(if_tap(key(a), key(b), 100), key(c), 100)", self.context, DummyMapping, ) self.assertEqual(len(macro.child_macros), 2) self.assertEqual(len(macro.child_macros[0].child_macros), 2) asyncio.ensure_future(macro.run(self.handler)) # first tap macro.press_trigger() await asyncio.sleep(0.05) macro.release_trigger() # second tap await asyncio.sleep(0.04) macro.press_trigger() await asyncio.sleep(0.04) macro.release_trigger() await asyncio.sleep(0.05) > self.assertListEqual(self.result, [(EV_KEY, KEY_A, 1), (EV_KEY, KEY_A, 0)]) E AssertionError: Lists differ: [(1, 46, 1), (1, 46, 0)] != [(1, 30, 1), (1, 30, 0)] E E First differing element 0: E (1, 46, 1) E (1, 30, 1) E E - [(1, 46, 1), (1, 46, 0)] E ? ^^ ^^ E E + [(1, 30, 1), (1, 30, 0)] E ? ^^ ^^ tests/unit/test_macros.py:1498: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:22:35.733786 435078 pytest WARNING context.py:87: Not forward_devices set 14:22:36.292167 435078 pytest WARNING context.py:90: Not source_devices set 14:22:36.739727 435078 pytest DEBUG parse.py:456: parsing macro if_tap(if_tap(key(a), key(b), 100), key(c), 100) 14:22:36.780289 435078 pytest DEBUG parse.py:244: calls if_tap with if_tap(key(a),key(b),100),key(c),100 14:22:37.297713 435078 pytest DEBUG parse.py:244: calls if_tap with key(a),key(b),100 14:22:37.326225 435078 pytest DEBUG parse.py:244: calls key with a 14:22:37.350957 435078 pytest DEBUG parse.py:244: string a 14:22:37.376319 435078 pytest DEBUG parse.py:244: add call to key with ['a'], {} 14:22:38.692938 435078 pytest DEBUG parse.py:244: calls key with b 14:22:38.722409 435078 pytest DEBUG parse.py:244: string b 14:22:38.744444 435078 pytest DEBUG parse.py:244: add call to key with ['b'], {} 14:22:39.143641 435078 pytest DEBUG parse.py:244: number 100 14:22:39.185389 435078 pytest DEBUG parse.py:244: add call to if_tap with [, , 100], {} 14:22:39.724545 435078 pytest DEBUG parse.py:244: calls key with c 14:22:39.757326 435078 pytest DEBUG parse.py:244: string c 14:22:39.778612 435078 pytest DEBUG parse.py:244: add call to key with ['c'], {} 14:22:40.155785 435078 pytest DEBUG parse.py:244: number 100 14:22:40.177961 435078 pytest DEBUG parse.py:244: add call to if_tap with [, , 100], {} Test: macro wrote(1, 46, 1) Test: macro wrote(1, 46, 0) Test: Quick cleanup... 14:22:44.328258 436125 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:22:46.540471 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:22:48.113380 436129 pytest DEBUG shared_dict.py:63: SharedDict process started 14:22:48.109230 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:22:48.773947 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:22:49.120600 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:22:51.705311 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:22:51.772007 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:22:54.190441 436129 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:22:54.348636 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:22:54.709830 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:22:54.739631 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:22:55.108840 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:22:55.144056 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro if_tap(if_tap(key(a), key(b), 100), key(c), 100) DEBUG input-remapper:parse.py:244 calls if_tap with if_tap(key(a),key(b),100),key(c),100 DEBUG input-remapper:parse.py:244 calls if_tap with key(a),key(b),100 DEBUG input-remapper:parse.py:244 calls key with a DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 add call to key with ['a'], {} DEBUG input-remapper:parse.py:244 calls key with b DEBUG input-remapper:parse.py:244 string b DEBUG input-remapper:parse.py:244 add call to key with ['b'], {} DEBUG input-remapper:parse.py:244 number 100 DEBUG input-remapper:parse.py:244 add call to if_tap with [, , 100], {} DEBUG input-remapper:parse.py:244 calls key with c DEBUG input-remapper:parse.py:244 string c DEBUG input-remapper:parse.py:244 add call to key with ['c'], {} DEBUG input-remapper:parse.py:244 number 100 DEBUG input-remapper:parse.py:244 add call to if_tap with [, , 100], {} WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 4.033 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.416 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 46, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.485 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.540 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 46, 0) WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.316 seconds WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('Lists differ: [(1, 46, 1), (1, 46, 0)] != [(1, 30, 1), (1, 30, 0)]\n\nFirst differing element 0:\n(1, 46, 1)\n(1, 30, 1)\n\n- [(1, 46, 1), (1, 46, 0)]\n? ^^ ^^\n\n+ [(1, 30, 1), (1, 30, 0)]\n? ^^ ^^\n') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.421 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done __________________________ TestIfTap.test_if_not_tap ___________________________ self = async def test_if_not_tap(self): macro = parse("if_tap(key(x), key(y), 50)", self.context, DummyMapping) self.assertEqual(len(macro.child_macros), 2) x = system_mapping.get("x") y = system_mapping.get("y") macro.press_trigger() asyncio.ensure_future(macro.run(self.handler)) await asyncio.sleep(0.1) macro.release_trigger() await asyncio.sleep(0.05) self.assertListEqual(self.result, [(EV_KEY, y, 1), (EV_KEY, y, 0)]) > self.assertFalse(macro.running) E AssertionError: True is not false tests/unit/test_macros.py:1561: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:23:23.095540 435078 pytest WARNING context.py:87: Not forward_devices set 14:23:23.118973 435078 pytest WARNING context.py:90: Not source_devices set 14:23:24.316215 435078 pytest DEBUG parse.py:456: parsing macro if_tap(key(x), key(y), 50) 14:23:24.356278 435078 pytest DEBUG parse.py:244: calls if_tap with key(x),key(y),50 14:23:24.380960 435078 pytest DEBUG parse.py:244: calls key with x 14:23:24.694868 435078 pytest DEBUG parse.py:244: string x 14:23:24.910251 435078 pytest DEBUG parse.py:244: add call to key with ['x'], {} 14:23:24.948913 435078 pytest DEBUG parse.py:244: calls key with y 14:23:24.975685 435078 pytest DEBUG parse.py:244: string y 14:23:24.996892 435078 pytest DEBUG parse.py:244: add call to key with ['y'], {} 14:23:25.511032 435078 pytest DEBUG parse.py:244: number 50 14:23:25.534135 435078 pytest DEBUG parse.py:244: add call to if_tap with [, , 50], {} Test: macro wrote(1, 44, 1) Test: macro wrote(1, 44, 0) Test: Quick cleanup... 14:23:28.538122 436129 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:23:31.143574 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:23:32.362022 436131 pytest DEBUG shared_dict.py:63: SharedDict process started 14:23:32.890862 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:23:33.737376 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:23:33.788305 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:23:36.131450 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:23:36.473014 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:23:39.346859 436131 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:23:39.383237 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:23:39.885141 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:23:39.924165 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:23:39.951026 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:23:39.975135 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro if_tap(key(x), key(y), 50) DEBUG input-remapper:parse.py:244 calls if_tap with key(x),key(y),50 DEBUG input-remapper:parse.py:244 calls key with x DEBUG input-remapper:parse.py:244 string x DEBUG input-remapper:parse.py:244 add call to key with ['x'], {} DEBUG input-remapper:parse.py:244 calls key with y DEBUG input-remapper:parse.py:244 string y DEBUG input-remapper:parse.py:244 add call to key with ['y'], {} DEBUG input-remapper:parse.py:244 number 50 DEBUG input-remapper:parse.py:244 add call to if_tap with [, , 50], {} WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 1.688 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.360 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 44, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.338 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.372 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 44, 0) WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.494 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done _______________________ TestIfTap.test_if_not_tap_named ________________________ self = async def test_if_not_tap_named(self): macro = parse("if_tap(key(x), key(y), timeout=50)", self.context, DummyMapping) self.assertEqual(len(macro.child_macros), 2) x = system_mapping.get("x") y = system_mapping.get("y") macro.press_trigger() asyncio.ensure_future(macro.run(self.handler)) await asyncio.sleep(0.1) macro.release_trigger() await asyncio.sleep(0.05) > self.assertListEqual(self.result, [(EV_KEY, y, 1), (EV_KEY, y, 0)]) E AssertionError: Lists differ: [(1, 44, 1)] != [(1, 44, 1), (1, 44, 0)] E E Second list contains 1 additional elements. E First extra element 1: E (1, 44, 0) E E - [(1, 44, 1)] E + [(1, 44, 1), (1, 44, 0)] tests/unit/test_macros.py:1576: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:24:11.773037 435078 pytest WARNING context.py:87: Not forward_devices set 14:24:11.792643 435078 pytest WARNING context.py:90: Not source_devices set 14:24:12.815057 435078 pytest DEBUG parse.py:456: parsing macro if_tap(key(x), key(y), timeout=50) 14:24:13.179073 435078 pytest DEBUG parse.py:244: calls if_tap with key(x),key(y),timeout=50 14:24:13.209552 435078 pytest DEBUG parse.py:244: calls key with x 14:24:13.230757 435078 pytest DEBUG parse.py:244: string x 14:24:13.249834 435078 pytest DEBUG parse.py:244: add call to key with ['x'], {} 14:24:13.742521 435078 pytest DEBUG parse.py:244: calls key with y 14:24:13.769400 435078 pytest DEBUG parse.py:244: string y 14:24:13.789121 435078 pytest DEBUG parse.py:244: add call to key with ['y'], {} 14:24:14.079411 435078 pytest DEBUG parse.py:244: number 50 14:24:14.335198 435078 pytest DEBUG parse.py:244: add call to if_tap with [, ], {'timeout': 50} Test: macro wrote(1, 44, 1) Test: macro wrote(1, 44, 0) Test: Quick cleanup... 14:24:18.123042 436131 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:24:20.278632 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:24:21.591417 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:24:22.092807 436134 pytest DEBUG shared_dict.py:63: SharedDict process started 14:24:23.160854 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:24:23.717972 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:24:25.973700 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:24:26.332448 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:24:29.206517 436134 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:24:29.209163 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:24:29.724313 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:24:29.784457 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:24:30.101027 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:24:30.155012 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro if_tap(key(x), key(y), timeout=50) DEBUG input-remapper:parse.py:244 calls if_tap with key(x),key(y),timeout=50 DEBUG input-remapper:parse.py:244 calls key with x DEBUG input-remapper:parse.py:244 string x DEBUG input-remapper:parse.py:244 add call to key with ['x'], {} DEBUG input-remapper:parse.py:244 calls key with y DEBUG input-remapper:parse.py:244 string y DEBUG input-remapper:parse.py:244 add call to key with ['y'], {} DEBUG input-remapper:parse.py:244 number 50 DEBUG input-remapper:parse.py:244 add call to if_tap with [, ], {'timeout': 50} WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 2.286 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.564 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 44, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.406 seconds WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('Lists differ: [(1, 44, 1)] != [(1, 44, 1), (1, 44, 0)]\n\nSecond list contains 1 additional elements.\nFirst extra element 1:\n(1, 44, 0)\n\n- [(1, 44, 1)]\n+ [(1, 44, 1), (1, 44, 0)]') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.489 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 44, 0) INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done ____________________________ TestIfTap.test_if_tap _____________________________ self = async def test_if_tap(self): macro = parse("if_tap(key(x), key(y), 100)", self.context, DummyMapping) self.assertEqual(len(macro.child_macros), 2) x = system_mapping.get("x") y = system_mapping.get("y") # this is the regular routine of how a macro is started. the tigger is pressed # already when the macro runs, and released during if_tap within the timeout. macro.press_trigger() asyncio.ensure_future(macro.run(self.handler)) await asyncio.sleep(0.05) macro.release_trigger() await asyncio.sleep(0.05) > self.assertListEqual(self.result, [(EV_KEY, x, 1), (EV_KEY, x, 0)]) E AssertionError: Lists differ: [(1, 44, 1)] != [(1, 45, 1), (1, 45, 0)] E E First differing element 0: E (1, 44, 1) E (1, 45, 1) E E Second list contains 1 additional elements. E First extra element 1: E (1, 45, 0) E E - [(1, 44, 1)] E + [(1, 45, 1), (1, 45, 0)] tests/unit/test_macros.py:1456: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:25:04.325574 435078 pytest WARNING context.py:87: Not forward_devices set 14:25:04.347927 435078 pytest WARNING context.py:90: Not source_devices set 14:25:05.113605 435078 pytest DEBUG parse.py:456: parsing macro if_tap(key(x), key(y), 100) 14:25:05.140975 435078 pytest DEBUG parse.py:244: calls if_tap with key(x),key(y),100 14:25:05.163918 435078 pytest DEBUG parse.py:244: calls key with x 14:25:05.927918 435078 pytest DEBUG parse.py:244: string x 14:25:05.968603 435078 pytest DEBUG parse.py:244: add call to key with ['x'], {} 14:25:06.018267 435078 pytest DEBUG parse.py:244: calls key with y 14:25:06.535394 435078 pytest DEBUG parse.py:244: string y 14:25:06.586979 435078 pytest DEBUG parse.py:244: add call to key with ['y'], {} 14:25:07.139719 435078 pytest DEBUG parse.py:244: number 100 14:25:07.176261 435078 pytest DEBUG parse.py:244: add call to if_tap with [, , 100], {} Test: macro wrote(1, 44, 1) Test: macro wrote(1, 44, 0) Test: Quick cleanup... 14:25:10.380751 436134 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:25:12.916470 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:25:14.309242 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:25:14.313942 436138 pytest DEBUG shared_dict.py:63: SharedDict process started 14:25:15.165576 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:25:15.752183 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:25:18.126888 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:25:18.550792 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:25:21.977651 436138 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:25:22.000708 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:25:22.025564 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:25:22.056604 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:25:22.508279 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:25:22.538197 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro if_tap(key(x), key(y), 100) DEBUG input-remapper:parse.py:244 calls if_tap with key(x),key(y),100 DEBUG input-remapper:parse.py:244 calls key with x DEBUG input-remapper:parse.py:244 string x DEBUG input-remapper:parse.py:244 add call to key with ['x'], {} DEBUG input-remapper:parse.py:244 calls key with y DEBUG input-remapper:parse.py:244 string y DEBUG input-remapper:parse.py:244 add call to key with ['y'], {} DEBUG input-remapper:parse.py:244 number 100 DEBUG input-remapper:parse.py:244 add call to if_tap with [, , 100], {} WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 2.803 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.422 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.401 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 44, 1) INFO input-remapper-test:test_macros.py:96 macro wrote(1, 44, 0) INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.416 seconds ___________________________ TestIfTap.test_if_tap_2 ____________________________ self = async def test_if_tap_2(self): # when the press arrives shortly after run. # a tap will happen within the timeout even if the tigger is not pressed when # it does into if_tap macro = parse("if_tap(key(a), key(b), 100)", self.context, DummyMapping) asyncio.ensure_future(macro.run(self.handler)) await asyncio.sleep(0.01) macro.press_trigger() await asyncio.sleep(0.01) macro.release_trigger() await asyncio.sleep(0.2) > self.assertListEqual(self.result, [(EV_KEY, KEY_A, 1), (EV_KEY, KEY_A, 0)]) E AssertionError: Lists differ: [(1, 48, 1), (1, 48, 0)] != [(1, 30, 1), (1, 30, 0)] E E First differing element 0: E (1, 48, 1) E (1, 30, 1) E E - [(1, 48, 1), (1, 48, 0)] E ? ^^ ^^ E E + [(1, 30, 1), (1, 30, 0)] E ? ^^ ^^ tests/unit/test_macros.py:1471: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:26:04.937381 435078 pytest WARNING context.py:87: Not forward_devices set 14:26:04.969634 435078 pytest WARNING context.py:90: Not source_devices set 14:26:06.109889 435078 pytest DEBUG parse.py:456: parsing macro if_tap(key(a), key(b), 100) 14:26:06.179696 435078 pytest DEBUG parse.py:244: calls if_tap with key(a),key(b),100 14:26:06.568379 435078 pytest DEBUG parse.py:244: calls key with a 14:26:06.590612 435078 pytest DEBUG parse.py:244: string a 14:26:06.611511 435078 pytest DEBUG parse.py:244: add call to key with ['a'], {} 14:26:06.929458 435078 pytest DEBUG parse.py:244: calls key with b 14:26:06.950475 435078 pytest DEBUG parse.py:244: string b 14:26:07.296030 435078 pytest DEBUG parse.py:244: add call to key with ['b'], {} 14:26:07.332368 435078 pytest DEBUG parse.py:244: number 100 14:26:07.716501 435078 pytest DEBUG parse.py:244: add call to if_tap with [, , 100], {} Test: macro wrote(1, 48, 1) Test: macro wrote(1, 48, 0) Test: Quick cleanup... 14:26:11.927436 436138 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:26:14.589616 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:26:16.342097 436140 pytest DEBUG shared_dict.py:63: SharedDict process started 14:26:16.350480 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:26:17.709200 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:26:18.113412 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:26:21.148110 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:26:21.575846 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:26:26.954544 436140 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:26:26.988754 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:26:27.544413 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:26:27.578750 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:26:28.099677 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:26:28.127544 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.310 seconds DEBUG input-remapper:parse.py:456 parsing macro if_tap(key(a), key(b), 100) DEBUG input-remapper:parse.py:244 calls if_tap with key(a),key(b),100 DEBUG input-remapper:parse.py:244 calls key with a DEBUG input-remapper:parse.py:244 string a DEBUG input-remapper:parse.py:244 add call to key with ['a'], {} DEBUG input-remapper:parse.py:244 calls key with b DEBUG input-remapper:parse.py:244 string b DEBUG input-remapper:parse.py:244 add call to key with ['b'], {} DEBUG input-remapper:parse.py:244 number 100 DEBUG input-remapper:parse.py:244 add call to if_tap with [, , 100], {} WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 2.591 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.408 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 1) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.398 seconds WARNING asyncio:base_events.py:1946 Executing , None) at /usr/lib64/python3.12/asyncio/futures.py:311 created at /usr/lib64/python3.12/asyncio/tasks.py:651> took 0.458 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 48, 0) WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.426 seconds WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('Lists differ: [(1, 48, 1), (1, 48, 0)] != [(1, 30, 1), (1, 30, 0)]\n\nFirst differing element 0:\n(1, 48, 1)\n(1, 30, 1)\n\n- [(1, 48, 1), (1, 48, 0)]\n? ^^ ^^\n\n+ [(1, 30, 1), (1, 30, 0)]\n? ^^ ^^\n') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.510 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done __________________________ TestIfTap.test_if_tap_none __________________________ self = async def test_if_tap_none(self): # first param none macro = parse("if_tap(, key(y), 100)", self.context, DummyMapping) self.assertEqual(len(macro.child_macros), 1) y = system_mapping.get("y") macro.press_trigger() asyncio.ensure_future(macro.run(self.handler)) await asyncio.sleep(0.05) macro.release_trigger() await asyncio.sleep(0.05) > self.assertListEqual(self.result, []) E AssertionError: Lists differ: [(1, 44, 1)] != [] E E First list contains 1 additional elements. E First extra element 0: E (1, 44, 1) E E - [(1, 44, 1)] E + [] tests/unit/test_macros.py:1532: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:27:13.295036 435078 pytest WARNING context.py:87: Not forward_devices set 14:27:13.323135 435078 pytest WARNING context.py:90: Not source_devices set 14:27:14.108130 435078 pytest DEBUG parse.py:456: parsing macro if_tap(, key(y), 100) 14:27:14.137256 435078 pytest DEBUG parse.py:244: calls if_tap with ,key(y),100 14:27:14.407952 435078 pytest DEBUG parse.py:244: calls key with y 14:27:14.433914 435078 pytest DEBUG parse.py:244: string y 14:27:14.795991 435078 pytest DEBUG parse.py:244: add call to key with ['y'], {} 14:27:14.837532 435078 pytest DEBUG parse.py:244: number 100 14:27:14.859041 435078 pytest DEBUG parse.py:244: add call to if_tap with [None, , 100], {} Test: macro wrote(1, 44, 1) Test: macro wrote(1, 44, 0) Test: Quick cleanup... 14:27:18.354679 436140 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:27:20.518443 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:27:21.516791 436149 pytest DEBUG shared_dict.py:63: SharedDict process started 14:27:21.536996 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:27:22.363130 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:27:22.910979 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:27:25.741499 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:27:26.116512 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:27:29.218751 436149 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:27:29.950599 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:27:29.976974 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:27:30.333054 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:27:30.372795 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:27:30.395572 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done ------------------------------ Captured log call ------------------------------- WARNING input-remapper:context.py:87 Not forward_devices set WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro if_tap(, key(y), 100) DEBUG input-remapper:parse.py:244 calls if_tap with ,key(y),100 DEBUG input-remapper:parse.py:244 calls key with y DEBUG input-remapper:parse.py:244 string y DEBUG input-remapper:parse.py:244 add call to key with ['y'], {} DEBUG input-remapper:parse.py:244 number 100 DEBUG input-remapper:parse.py:244 add call to if_tap with [None, , 100], {} WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 1.535 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.328 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.333 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 44, 1) WARNING asyncio:base_events.py:1946 Executing exception=AssertionError('Lists differ: [(1, 44, 1)] != []\n\nFirst list contains 1 additional elements.\nFirst extra element 0:\n(1, 44, 1)\n\n- [(1, 44, 1)]\n+ []') created at /usr/lib64/python3.12/asyncio/runners.py:100> took 0.539 seconds INFO input-remapper-test:test_macros.py:96 macro wrote(1, 44, 0) INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done ________________ TestReaderAsyncio.test_should_forward_to_dummy ________________ self = async def test_should_forward_to_dummy(self): # It forwards to a ForwardDummy, because the gui process # 1. can't inject and # 2. is not even supposed to inject anything # thanks to not using multiprocessing as opposed to the other tests, we can # access this stuff context = None original_create_event_pipeline = ReaderService._create_event_pipeline def remember_context(*args, **kwargs): nonlocal context context = original_create_event_pipeline(*args, **kwargs) return context with mock.patch( "inputremapper.gui.reader_service.ReaderService._create_event_pipeline", remember_context, ): await self.create_reader_service() listener = Listener() self.message_broker.subscribe(MessageType.combination_recorded, listener) self.reader_client.set_group(self.groups.find(key="Foo Device 2")) self.reader_client.start_recorder() await asyncio.sleep(0.1) > self.assertIsInstance(context, ContextDummy) E AssertionError: None is not an instance of tests/unit/test_reader.py:142: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:35:03.178833 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:35:05.146247 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:35:05.717762 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.terminate: . at 0xffffff936ca5c0> 14:35:08.943545 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:35:08.984833 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:35:10.365939 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.combination_recorded: 14:35:11.507908 435078 pytest DEBUG groups.py:354: Discovering device paths 14:35:11.603151 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:35:12.158240 435078 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:35:12.567229 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:35:12.597428 435078 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:35:12.909229 435078 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:35:12.944531 435078 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:35:13.340761 435078 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:35:13.379214 435078 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:35:13.725022 435078 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:35:13.763298 435078 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:35:14.115638 435078 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:35:14.188677 435078 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:35:14.725862 435078 pytest DEBUG reader_client.py:172: Starting recorder. Test: is_running is patched to always return True 14:35:14.763230 435078 pytest DEBUG reader_client.py:120: Sending "Foo Device 2" to ReaderService 14:35:14.801540 435078 pytest DEBUG message_broker.py:76: from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started 14:35:15.353290 435078 pytest DEBUG reader_service.py:154: Discovering initial groups 14:35:15.407556 435078 pytest DEBUG groups.py:354: Discovering device paths 14:35:15.933539 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:35:15.964658 435078 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:35:16.340578 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:35:16.383749 435078 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:35:16.706699 435078 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:35:16.750900 435078 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:35:16.792206 435078 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:35:17.311704 435078 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:35:17.360352 435078 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:35:17.408849 435078 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:35:17.904661 435078 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:35:17.972362 435078 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:35:18.330755 435078 pytest DEBUG reader_service.py:161: Sending groups 14:35:19.725055 435078 pytest DEBUG reader_service.py:193: Waiting for commands 14:35:23.331046 435078 pytest DEBUG reader_service.py:195: Received command "Foo Device 2" 14:35:30.136023 435078 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event11, fd 16 14:35:30.969159 435078 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event10, fd 18 14:35:32.301020 435078 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event13, fd 20 14:35:32.761040 435078 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event15, fd 24 Test: Quick cleanup... 14:35:34.138859 436209 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:35:36.567346 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:35:37.744402 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:35:38.122969 436214 pytest DEBUG shared_dict.py:63: SharedDict process started 14:35:38.922232 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:35:38.958066 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:35:40.698347 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:35:41.317215 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:35:44.552505 436214 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:35:44.935661 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:35:44.966712 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:35:45.337233 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:35:45.368633 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:35:45.390889 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done 14:35:45.873954 435078 pytest DEBUG reader_client.py:120: Sending "terminate" to ReaderService 14:35:45.899430 435078 pytest DEBUG reader_client.py:185: Stopping recorder. 14:35:45.918583 435078 pytest DEBUG reader_client.py:120: Sending "stop-reading" to ReaderService 14:35:47.519848 435078 pytest DEBUG message_broker.py:76: from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ------------------------------ Captured log call ------------------------------- DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.terminate: . at 0xffffff936ca5c0> WARNING asyncio:base_events.py:1946 Executing ) at /usr/lib64/python3.12/asyncio/base_events.py:180 created at /usr/lib64/python3.12/asyncio/events.py:84> took 0.499 seconds DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.combination_recorded: DEBUG input-remapper:groups.py:354 Discovering device paths DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" DEBUG input-remapper:groups.py:402 Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:391 "Foo Device qux" has no useful capabilities DEBUG input-remapper:groups.py:402 Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" DEBUG input-remapper:groups.py:402 Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" DEBUG input-remapper:groups.py:402 Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" DEBUG input-remapper:groups.py:395 "YuBiCofooYuBiKeYbar" is denylisted DEBUG input-remapper:groups.py:402 Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" INFO input-remapper:groups.py:481 Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" DEBUG input-remapper:reader_client.py:172 Starting recorder. INFO input-remapper-test:patches.py:310 is_running is patched to always return True DEBUG input-remapper:reader_client.py:120 Sending "Foo Device 2" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 7.548 seconds DEBUG input-remapper:reader_service.py:154 Discovering initial groups DEBUG input-remapper:groups.py:354 Discovering device paths DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" DEBUG input-remapper:groups.py:402 Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:391 "Foo Device qux" has no useful capabilities DEBUG input-remapper:groups.py:402 Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" DEBUG input-remapper:groups.py:402 Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" DEBUG input-remapper:groups.py:402 Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" DEBUG input-remapper:groups.py:395 "YuBiCofooYuBiKeYbar" is denylisted DEBUG input-remapper:groups.py:402 Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" INFO input-remapper:groups.py:481 Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" DEBUG input-remapper:reader_service.py:161 Sending groups WARNING asyncio:base_events.py:1946 Executing wait_for=<_GatheringFuture pending cb=[Task.task_wakeup()] created at /usr/lib64/python3.12/asyncio/tasks.py:702> created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 4.357 seconds DEBUG input-remapper:reader_service.py:193 Waiting for commands WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[gather.._done_callback() at /usr/lib64/python3.12/asyncio/tasks.py:757] created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.629 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[gather.._done_callback() at /usr/lib64/python3.12/asyncio/tasks.py:757] created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 1.214 seconds WARNING asyncio:base_events.py:1946 Executing , None) at /usr/lib64/python3.12/asyncio/futures.py:311 created at /usr/lib64/python3.12/asyncio/unix_events.py:492> took 0.326 seconds DEBUG input-remapper:reader_service.py:195 Received command "Foo Device 2" WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[gather.._done_callback() at /usr/lib64/python3.12/asyncio/tasks.py:757] created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 6.785 seconds DEBUG input-remapper:event_reader.py:191 Starting to listen for events from /dev/input/event11, fd 16 WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:410> took 0.826 seconds DEBUG input-remapper:event_reader.py:191 Starting to listen for events from /dev/input/event10, fd 18 WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:410> took 0.970 seconds DEBUG input-remapper:event_reader.py:191 Starting to listen for events from /dev/input/event13, fd 20 WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:410> took 0.808 seconds DEBUG input-remapper:event_reader.py:191 Starting to listen for events from /dev/input/event15, fd 24 WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:410> took 0.105 seconds INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done DEBUG input-remapper:reader_client.py:120 Sending "terminate" to ReaderService DEBUG input-remapper:reader_client.py:185 Stopping recorder. DEBUG input-remapper:reader_client.py:120 Sending "stop-reading" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished WARNING asyncio:base_events.py:1946 Executing created at /builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/event_reader.py:93> took 0.314 seconds WARNING asyncio:base_events.py:1946 Executing created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.357 seconds WARNING asyncio:base_events.py:1946 Executing created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.546 seconds WARNING asyncio:base_events.py:1946 Executing ._done_callback() at /usr/lib64/python3.12/asyncio/tasks.py:757 created at /usr/lib64/python3.12/asyncio/events.py:84> took 0.318 seconds ___________ TestReaderMultiprocessing.test_are_new_groups_available ____________ self = def test_are_new_groups_available(self): l1 = Listener() self.message_broker.subscribe(MessageType.groups, l1) self.create_reader_service() self.reader_client.groups.set_groups([]) time.sleep(0.1) # let the reader-service send the groups # read stuff from the reader-service, which includes the devices self.assertEqual("[]", self.reader_client.groups.dumps()) self.reader_client._read() > self.assertEqual( self.reader_client.groups.dumps(), json.dumps( [ json.dumps( { "paths": [ "/dev/input/event1", ], "names": ["Foo Device"], "types": [DeviceType.KEYBOARD], "key": "Foo Device", } ), json.dumps( { "paths": [ "/dev/input/event11", "/dev/input/event10", "/dev/input/event13", "/dev/input/event15", ], "names": [ "Foo Device foo", "Foo Device", "Foo Device", "Foo Device bar", ], "types": [ DeviceType.GAMEPAD, DeviceType.KEYBOARD, DeviceType.MOUSE, ], "key": "Foo Device 2", } ), json.dumps( { "paths": ["/dev/input/event20"], "names": ["Bar Device"], "types": [DeviceType.KEYBOARD], "key": "Bar Device", } ), json.dumps( { "paths": ["/dev/input/event30"], "names": ["gamepad"], "types": [DeviceType.GAMEPAD], "key": "gamepad", } ), json.dumps( { "paths": ["/dev/input/event40"], "names": ["input-remapper Bar Device"], "types": [DeviceType.KEYBOARD], "key": "input-remapper Bar Device", } ), json.dumps( { "paths": ["/dev/input/event52"], "names": ["Qux/Device?"], "types": [DeviceType.KEYBOARD], "key": "Qux/Device?", } ), ] ), ) E AssertionError: '[]' != '["{\\"paths\\": [\\"/dev/input/event1\\"],[976 chars]"}"]' E Diff is 919 characters long. Set self.maxDiff to None to see it. tests/unit/test_reader.py:839: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:36:11.533985 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:36:11.907782 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:36:11.936951 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.terminate: . at 0xffffff936c8860> 14:36:11.962548 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.groups: 14:36:13.168134 435078 pytest DEBUG groups.py:497: Overwriting groups with [] 14:36:13.727050 436217 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:36:14.161100 436217 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:36:14.733988 435078 pytest DEBUG reader_client.py:141: received {'type': 'status', 'message': 'ready'} 14:36:14.745566 436217 pytest DEBUG reader_service.py:154: Discovering initial groups 14:36:15.173129 436217 pytest DEBUG groups.py:354: Discovering device paths 14:36:15.752776 436217 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:36:16.235010 436217 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" Test: Quick cleanup... 14:36:16.719841 436217 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:36:16.768979 436217 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:36:17.316793 436217 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:36:17.405062 436217 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:36:17.453788 436214 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:36:17.753673 436217 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:36:17.785392 436217 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:36:18.332571 436217 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:36:18.368891 436217 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:36:18.761344 436217 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:36:19.942366 436217 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:36:20.305230 436217 pytest DEBUG reader_service.py:161: Sending groups 14:36:20.360928 436217 pytest DEBUG reader_service.py:193: Waiting for commands Test: Killed pid 436214 because it didn't finish in time Test: Killed pid 436217 because it didn't finish in time 14:36:52.114714 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:36:53.368740 436221 pytest DEBUG shared_dict.py:63: SharedDict process started 14:36:53.371447 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:36:54.707571 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:36:54.760729 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:36:57.885454 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:36:58.340822 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:37:01.159087 436221 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:37:01.178676 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:37:01.205724 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:37:01.766998 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:37:02.126431 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:37:02.148710 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done 14:37:02.182853 435078 pytest DEBUG reader_client.py:120: Sending "terminate" to ReaderService 14:37:02.207780 435078 pytest DEBUG reader_client.py:185: Stopping recorder. 14:37:02.722002 435078 pytest DEBUG reader_client.py:120: Sending "stop-reading" to ReaderService 14:37:02.773291 435078 pytest DEBUG reader_client.py:194: No recording generator existed 14:37:03.335251 435078 pytest DEBUG message_broker.py:76: from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ------------------------------ Captured log call ------------------------------- DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.terminate: . at 0xffffff936c8860> DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.groups: DEBUG input-remapper:groups.py:497 Overwriting groups with [] DEBUG input-remapper:reader_client.py:141 received {'type': 'status', 'message': 'ready'} INFO input-remapper-test:cleanup.py:87 Quick cleanup... INFO input-remapper-test:cleanup.py:59 Killed pid 436214 because it didn't finish in time INFO input-remapper-test:cleanup.py:59 Killed pid 436217 because it didn't finish in time DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done DEBUG input-remapper:reader_client.py:120 Sending "terminate" to ReaderService DEBUG input-remapper:reader_client.py:185 Stopping recorder. DEBUG input-remapper:reader_client.py:120 Sending "stop-reading" to ReaderService DEBUG input-remapper:reader_client.py:194 No recording generator existed DEBUG input-remapper:message_broker.py:76 from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished --------------------------- Captured stderr teardown --------------------------- 14:37:19.547183 435078 pytest DEBUG pipe.py:106: closing transport ______________ TestReaderMultiprocessing.test_blacklisted_events _______________ self = def test_blacklisted_events(self): l1 = Listener() self.message_broker.subscribe(MessageType.combination_recorded, l1) push_events( fixtures.foo_device_2_mouse, [ InputEvent.key(BTN_TOOL_DOUBLETAP, 1), InputEvent.key(BTN_LEFT, 1), InputEvent.key(BTN_TOOL_DOUBLETAP, 1), ], force=True, ) self.create_reader_service() self.reader_client.set_group(self.groups.find(key="Foo Device 2")) self.reader_client.start_recorder() time.sleep(0.1) self.reader_client._read() self.assertEqual( > l1.calls[-1].combination, InputCombination( [ InputConfig( type=EV_KEY, code=BTN_LEFT, origin_hash=fixtures.foo_device_2_mouse.get_device_hash(), ) ] ), ) E IndexError: list index out of range tests/unit/test_reader.py:701: IndexError ----------------------------- Captured stderr call ----------------------------- 14:37:31.198568 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:37:31.741023 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:37:31.794704 435078 pytest DEBUG pipe.py:133: Ignoring old message [1707853022.200557, 'terminate'] 14:37:32.210691 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.terminate: . at 0xffffff934a4860> 14:37:32.246897 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.combination_recorded: Test: Simulating InputEvent for (1, 333, 1) BTN_TOOL_DOUBLETAP for /dev/input/event11 Test: Simulating InputEvent for (1, 272, 1) BTN_LEFT for /dev/input/event11 Test: Simulating InputEvent for (1, 333, 1) BTN_TOOL_DOUBLETAP for /dev/input/event11 14:37:35.137220 436227 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:37:35.175746 435078 pytest DEBUG groups.py:354: Discovering device paths 14:37:35.554425 436227 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:37:36.144131 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:37:36.523351 435078 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:37:36.544373 436227 pytest DEBUG reader_service.py:154: Discovering initial groups 14:37:37.049432 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:37:37.078537 436227 pytest DEBUG groups.py:354: Discovering device paths 14:37:37.086012 435078 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:37:37.114590 435078 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:37:37.725745 436227 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:37:37.745843 435078 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:37:37.759514 436227 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:37:38.342485 435078 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:37:38.359231 436227 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:37:38.379825 435078 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:37:38.398707 436227 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:37:38.856086 436227 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:37:38.866024 435078 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:37:39.222446 436227 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:37:39.228932 435078 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:37:39.276509 436227 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:37:39.278180 435078 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:37:39.760904 436227 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:37:40.387940 436227 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:37:40.405050 435078 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:37:40.953535 435078 pytest DEBUG reader_client.py:172: Starting recorder. 14:37:40.954714 436227 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted Test: is_running is patched to always return True 14:37:41.004535 435078 pytest DEBUG reader_client.py:120: Sending "Foo Device 2" to ReaderService 14:37:41.509683 436227 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:37:41.544198 435078 pytest DEBUG message_broker.py:76: from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started 14:37:41.916144 435078 pytest DEBUG reader_client.py:141: received {'type': 'status', 'message': 'ready'} 14:37:41.939013 436227 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" Test: Quick cleanup... 14:37:42.752655 436227 pytest DEBUG reader_service.py:161: Sending groups 14:37:43.323280 436227 pytest DEBUG reader_service.py:193: Waiting for commands 14:37:43.387491 436221 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:37:45.106470 436227 pytest DEBUG reader_service.py:195: Received command "Foo Device 2" 14:37:51.515602 436227 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event11, fd 16 14:37:51.574696 436227 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event10, fd 18 14:37:51.944130 436227 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event13, fd 20 14:37:52.339047 436227 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event15, fd 24 Test: Killed pid 436221 because it didn't finish in time Test: Killed pid 436227 because it didn't finish in time 14:38:27.777743 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:38:29.519638 436232 pytest DEBUG shared_dict.py:63: SharedDict process started 14:38:29.519014 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:38:30.572018 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:38:31.737571 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:38:34.934833 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:38:34.988632 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:38:38.960670 436232 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:38:39.335539 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:38:39.381241 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:38:39.775313 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:38:39.802986 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:38:39.826688 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done 14:38:40.546165 435078 pytest DEBUG reader_client.py:120: Sending "terminate" to ReaderService 14:38:40.579798 435078 pytest DEBUG reader_client.py:185: Stopping recorder. 14:38:40.616346 435078 pytest DEBUG reader_client.py:120: Sending "stop-reading" to ReaderService 14:38:41.708200 435078 pytest DEBUG message_broker.py:76: from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ------------------------------ Captured log call ------------------------------- DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" DEBUG input-remapper:pipe.py:133 Ignoring old message [1707853022.200557, 'terminate'] DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.terminate: . at 0xffffff934a4860> DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.combination_recorded: INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 333, 1) BTN_TOOL_DOUBLETAP for /dev/input/event11 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 272, 1) BTN_LEFT for /dev/input/event11 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 333, 1) BTN_TOOL_DOUBLETAP for /dev/input/event11 DEBUG input-remapper:groups.py:354 Discovering device paths DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" DEBUG input-remapper:groups.py:402 Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:391 "Foo Device qux" has no useful capabilities DEBUG input-remapper:groups.py:402 Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" DEBUG input-remapper:groups.py:402 Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" DEBUG input-remapper:groups.py:402 Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" DEBUG input-remapper:groups.py:395 "YuBiCofooYuBiKeYbar" is denylisted DEBUG input-remapper:groups.py:402 Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" INFO input-remapper:groups.py:481 Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" DEBUG input-remapper:reader_client.py:172 Starting recorder. INFO input-remapper-test:patches.py:310 is_running is patched to always return True DEBUG input-remapper:reader_client.py:120 Sending "Foo Device 2" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started DEBUG input-remapper:reader_client.py:141 received {'type': 'status', 'message': 'ready'} INFO input-remapper-test:cleanup.py:87 Quick cleanup... INFO input-remapper-test:cleanup.py:59 Killed pid 436221 because it didn't finish in time INFO input-remapper-test:cleanup.py:59 Killed pid 436227 because it didn't finish in time DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done DEBUG input-remapper:reader_client.py:120 Sending "terminate" to ReaderService DEBUG input-remapper:reader_client.py:185 Stopping recorder. DEBUG input-remapper:reader_client.py:120 Sending "stop-reading" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished _________________ TestReaderMultiprocessing.test_change_device _________________ self = def test_change_device(self): l1 = Listener() self.message_broker.subscribe(MessageType.combination_recorded, l1) push_events( fixtures.foo_device_2_keyboard, [ InputEvent.key(1, 1), ] * 10, ) push_events( fixtures.bar_device, [ InputEvent.key(2, 1), InputEvent.key(2, 0), ] * 3, ) self.create_reader_service() self.reader_client.set_group(self.groups.find(key="Foo Device 2")) self.reader_client.start_recorder() time.sleep(0.1) self.reader_client._read() self.assertEqual( > l1.calls[0].combination, InputCombination( [ InputConfig( type=EV_KEY, code=1, origin_hash=fixtures.foo_device_2_keyboard.get_device_hash(), ) ] ), ) E IndexError: list index out of range tests/unit/test_reader.py:581: IndexError ----------------------------- Captured stderr call ----------------------------- 14:39:05.376924 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:39:06.406887 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:39:06.765877 435078 pytest DEBUG pipe.py:133: Ignoring old message [1707853120.570899, 'terminate'] 14:39:06.804465 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.terminate: . at 0xffffff934a6840> 14:39:07.207372 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.combination_recorded: Test: Simulating InputEvent for (1, 1, 1) KEY_ESC for /dev/input/event10 Test: Simulating InputEvent for (1, 1, 1) KEY_ESC for /dev/input/event10 Test: Simulating InputEvent for (1, 1, 1) KEY_ESC for /dev/input/event10 Test: Simulating InputEvent for (1, 1, 1) KEY_ESC for /dev/input/event10 Test: Simulating InputEvent for (1, 1, 1) KEY_ESC for /dev/input/event10 Test: Simulating InputEvent for (1, 1, 1) KEY_ESC for /dev/input/event10 Test: Simulating InputEvent for (1, 1, 1) KEY_ESC for /dev/input/event10 Test: Simulating InputEvent for (1, 1, 1) KEY_ESC for /dev/input/event10 Test: Simulating InputEvent for (1, 1, 1) KEY_ESC for /dev/input/event10 Test: Simulating InputEvent for (1, 1, 1) KEY_ESC for /dev/input/event10 Test: Simulating InputEvent for (1, 2, 1) KEY_1 for /dev/input/event20 Test: Simulating InputEvent for (1, 2, 0) KEY_1 for /dev/input/event20 Test: Simulating InputEvent for (1, 2, 1) KEY_1 for /dev/input/event20 Test: Simulating InputEvent for (1, 2, 0) KEY_1 for /dev/input/event20 Test: Simulating InputEvent for (1, 2, 1) KEY_1 for /dev/input/event20 Test: Simulating InputEvent for (1, 2, 0) KEY_1 for /dev/input/event20 14:39:09.970603 436248 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:39:11.787524 436248 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:39:12.122330 435078 pytest DEBUG groups.py:354: Discovering device paths 14:39:12.762153 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:39:13.138663 435078 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:39:13.140213 436248 pytest DEBUG reader_service.py:154: Discovering initial groups 14:39:13.735753 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:39:13.736533 436248 pytest DEBUG groups.py:354: Discovering device paths 14:39:14.113880 435078 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:39:14.160972 436248 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:39:14.178531 435078 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:39:14.206294 436248 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:39:14.208346 435078 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:39:15.111113 435078 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:39:15.127924 436248 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:39:15.155806 436248 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:39:15.167884 435078 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:39:15.181494 436248 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:39:15.207724 436248 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:39:15.730353 435078 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:39:15.772680 435078 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:39:15.773492 436248 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:39:16.149999 436248 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:39:16.187616 435078 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:39:16.720630 436248 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:39:16.765914 436248 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:39:16.788886 435078 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:39:17.263256 435078 pytest DEBUG reader_client.py:172: Starting recorder. 14:39:17.264074 436248 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" Test: is_running is patched to always return True 14:39:17.298093 435078 pytest DEBUG reader_client.py:120: Sending "Foo Device 2" to ReaderService 14:39:17.886436 435078 pytest DEBUG message_broker.py:76: from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started 14:39:18.259287 436248 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:39:18.297690 436248 pytest DEBUG reader_service.py:161: Sending groups 14:39:18.934313 436248 pytest DEBUG reader_service.py:193: Waiting for commands 14:39:18.933140 435078 pytest DEBUG reader_client.py:141: received {'type': 'status', 'message': 'ready'} 14:39:18.965623 435078 pytest DEBUG reader_client.py:141: received {'type': 'groups', 'message': '["{\\"paths\\": [\\"/dev/input/event1\\"], \\"names\\": [\\"Foo Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Foo Device\\"}", "{\\"paths\\": [\\"/dev/input/event11\\", \\"/dev/input/event10\\", \\"/dev/input/event13\\", \\"/dev/input/event15\\"], \\"names\\": [\\"Foo Device foo\\", \\"Foo Device\\", \\"Foo Device\\", \\"Foo Device bar\\"], \\"types\\": [\\"gamepad\\", \\"keyboard\\", \\"mouse\\"], \\"key\\": \\"Foo Device 2\\"}", "{\\"paths\\": [\\"/dev/input/event20\\"], \\"names\\": [\\"Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event30\\"], \\"names\\": [\\"gamepad\\"], \\"types\\": [\\"gamepad\\"], \\"key\\": \\"gamepad\\"}", "{\\"paths\\": [\\"/dev/input/event40\\"], \\"names\\": [\\"input-remapper Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"input-remapper Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event52\\"], \\"names\\": [\\"Qux/Device?\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Qux/Device?\\"}"]'} 14:39:19.534555 436248 pytest DEBUG reader_service.py:195: Received command "Foo Device 2" 14:39:20.133730 435078 pytest DEBUG message_broker.py:76: from reader_client.py:282: Signal=groups: GroupsData(groups={'Foo Device': [], 'Foo Device 2': [, , ], 'Bar Device': [], 'gamepad': [], 'Qux/Device?': []}) Test: Quick cleanup... 14:39:22.360135 436232 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:39:26.369609 436248 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event11, fd 16 14:39:26.783332 436248 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event10, fd 18 14:39:27.130156 436248 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event13, fd 20 14:39:27.526953 436248 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event15, fd 24 Test: Killed pid 436232 because it didn't finish in time Test: Killed pid 436248 because it didn't finish in time 14:39:57.390854 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:39:58.416477 436260 pytest DEBUG shared_dict.py:63: SharedDict process started 14:39:58.399650 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:39:59.397047 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:40:00.712646 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:40:04.553876 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:40:05.137590 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:40:08.102846 436260 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:40:08.124999 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:40:08.157277 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:40:08.760964 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:40:09.121890 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:40:09.144370 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done 14:40:09.527183 435078 pytest DEBUG reader_client.py:120: Sending "terminate" to ReaderService 14:40:09.554984 435078 pytest DEBUG reader_client.py:185: Stopping recorder. 14:40:09.583757 435078 pytest DEBUG reader_client.py:120: Sending "stop-reading" to ReaderService 14:40:10.157046 435078 pytest DEBUG message_broker.py:76: from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ------------------------------ Captured log call ------------------------------- DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" DEBUG input-remapper:pipe.py:133 Ignoring old message [1707853120.570899, 'terminate'] DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.terminate: . at 0xffffff934a6840> DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.combination_recorded: INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 1, 1) KEY_ESC for /dev/input/event10 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 1, 1) KEY_ESC for /dev/input/event10 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 1, 1) KEY_ESC for /dev/input/event10 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 1, 1) KEY_ESC for /dev/input/event10 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 1, 1) KEY_ESC for /dev/input/event10 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 1, 1) KEY_ESC for /dev/input/event10 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 1, 1) KEY_ESC for /dev/input/event10 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 1, 1) KEY_ESC for /dev/input/event10 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 1, 1) KEY_ESC for /dev/input/event10 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 1, 1) KEY_ESC for /dev/input/event10 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 2, 1) KEY_1 for /dev/input/event20 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 2, 0) KEY_1 for /dev/input/event20 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 2, 1) KEY_1 for /dev/input/event20 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 2, 0) KEY_1 for /dev/input/event20 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 2, 1) KEY_1 for /dev/input/event20 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 2, 0) KEY_1 for /dev/input/event20 DEBUG input-remapper:groups.py:354 Discovering device paths DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" DEBUG input-remapper:groups.py:402 Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:391 "Foo Device qux" has no useful capabilities DEBUG input-remapper:groups.py:402 Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" DEBUG input-remapper:groups.py:402 Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" DEBUG input-remapper:groups.py:402 Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" DEBUG input-remapper:groups.py:395 "YuBiCofooYuBiKeYbar" is denylisted DEBUG input-remapper:groups.py:402 Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" INFO input-remapper:groups.py:481 Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" DEBUG input-remapper:reader_client.py:172 Starting recorder. INFO input-remapper-test:patches.py:310 is_running is patched to always return True DEBUG input-remapper:reader_client.py:120 Sending "Foo Device 2" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started DEBUG input-remapper:reader_client.py:141 received {'type': 'status', 'message': 'ready'} DEBUG input-remapper:reader_client.py:141 received {'type': 'groups', 'message': '["{\\"paths\\": [\\"/dev/input/event1\\"], \\"names\\": [\\"Foo Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Foo Device\\"}", "{\\"paths\\": [\\"/dev/input/event11\\", \\"/dev/input/event10\\", \\"/dev/input/event13\\", \\"/dev/input/event15\\"], \\"names\\": [\\"Foo Device foo\\", \\"Foo Device\\", \\"Foo Device\\", \\"Foo Device bar\\"], \\"types\\": [\\"gamepad\\", \\"keyboard\\", \\"mouse\\"], \\"key\\": \\"Foo Device 2\\"}", "{\\"paths\\": [\\"/dev/input/event20\\"], \\"names\\": [\\"Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event30\\"], \\"names\\": [\\"gamepad\\"], \\"types\\": [\\"gamepad\\"], \\"key\\": \\"gamepad\\"}", "{\\"paths\\": [\\"/dev/input/event40\\"], \\"names\\": [\\"input-remapper Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"input-remapper Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event52\\"], \\"names\\": [\\"Qux/Device?\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Qux/Device?\\"}"]'} DEBUG input-remapper:message_broker.py:76 from reader_client.py:282: Signal=groups: GroupsData(groups={'Foo Device': [], 'Foo Device 2': [, , ], 'Bar Device': [], 'gamepad': [], 'Qux/Device?': []}) INFO input-remapper-test:cleanup.py:87 Quick cleanup... INFO input-remapper-test:cleanup.py:59 Killed pid 436232 because it didn't finish in time INFO input-remapper-test:cleanup.py:59 Killed pid 436248 because it didn't finish in time DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done DEBUG input-remapper:reader_client.py:120 Sending "terminate" to ReaderService DEBUG input-remapper:reader_client.py:185 Stopping recorder. DEBUG input-remapper:reader_client.py:120 Sending "stop-reading" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ________________ TestReaderMultiprocessing.test_ignore_value_2 _________________ self = def test_ignore_value_2(self): l1 = Listener() self.message_broker.subscribe(MessageType.combination_recorded, l1) # this is not a combination, because (EV_KEY CODE_3, 2) is ignored push_events( fixtures.foo_device_2_gamepad, [InputEvent.abs(ABS_HAT0X, 1), InputEvent.key(CODE_3, 2)], force=True, ) self.create_reader_service() self.reader_client.set_group(self.groups.find(key="Foo Device 2")) self.reader_client.start_recorder() time.sleep(0.2) self.reader_client._read() self.assertEqual( > l1.calls[-1].combination, InputCombination( [ InputConfig( type=EV_ABS, code=ABS_HAT0X, analog_threshold=1, origin_hash=fixtures.foo_device_2_gamepad.get_device_hash(), ) ] ), ) E IndexError: list index out of range tests/unit/test_reader.py:728: IndexError ----------------------------- Captured stderr call ----------------------------- 14:40:32.598166 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:40:33.120193 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:40:33.168623 435078 pytest DEBUG pipe.py:133: Ignoring old message [1707853209.5475023, 'terminate'] 14:40:33.198750 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.terminate: . at 0xffffff934a5b20> 14:40:33.553931 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.combination_recorded: Test: Simulating InputEvent for (3, 16, 1) ABS_HAT0X for /dev/input/event15 Test: Simulating InputEvent for (1, 102, 2) KEY_HOME for /dev/input/event15 14:40:35.375995 436263 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:40:35.967488 436263 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:40:36.528591 435078 pytest DEBUG groups.py:354: Discovering device paths 14:40:36.910552 436263 pytest DEBUG reader_service.py:154: Discovering initial groups 14:40:36.949974 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:40:37.323140 435078 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:40:37.335595 436263 pytest DEBUG groups.py:354: Discovering device paths 14:40:37.380924 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:40:37.715978 436263 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:40:37.752968 435078 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:40:37.753354 436263 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:40:38.120039 435078 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:40:38.146871 436263 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:40:38.152727 435078 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:40:38.174151 436263 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:40:38.524470 435078 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:40:38.528635 436263 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:40:38.553046 435078 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:40:38.559236 436263 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:40:38.966662 435078 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:40:38.968877 436263 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:40:38.996188 436263 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:40:39.008348 435078 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:40:39.354856 435078 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:40:39.712792 436263 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:40:39.759416 436263 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:40:39.814962 436263 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:40:40.179428 435078 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:40:40.214571 435078 pytest DEBUG reader_client.py:172: Starting recorder. Test: is_running is patched to always return True 14:40:40.746654 435078 pytest DEBUG reader_client.py:120: Sending "Foo Device 2" to ReaderService 14:40:40.748600 436263 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:40:40.778738 436263 pytest DEBUG reader_service.py:161: Sending groups 14:40:41.318561 435078 pytest DEBUG message_broker.py:76: from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started 14:40:41.345345 436263 pytest DEBUG reader_service.py:193: Waiting for commands 14:40:41.722785 435078 pytest DEBUG reader_client.py:141: received {'type': 'status', 'message': 'ready'} 14:40:41.757711 436263 pytest DEBUG reader_service.py:195: Received command "Foo Device 2" 14:40:41.759378 435078 pytest DEBUG reader_client.py:141: received {'type': 'groups', 'message': '["{\\"paths\\": [\\"/dev/input/event1\\"], \\"names\\": [\\"Foo Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Foo Device\\"}", "{\\"paths\\": [\\"/dev/input/event11\\", \\"/dev/input/event10\\", \\"/dev/input/event13\\", \\"/dev/input/event15\\"], \\"names\\": [\\"Foo Device foo\\", \\"Foo Device\\", \\"Foo Device\\", \\"Foo Device bar\\"], \\"types\\": [\\"gamepad\\", \\"keyboard\\", \\"mouse\\"], \\"key\\": \\"Foo Device 2\\"}", "{\\"paths\\": [\\"/dev/input/event20\\"], \\"names\\": [\\"Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event30\\"], \\"names\\": [\\"gamepad\\"], \\"types\\": [\\"gamepad\\"], \\"key\\": \\"gamepad\\"}", "{\\"paths\\": [\\"/dev/input/event40\\"], \\"names\\": [\\"input-remapper Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"input-remapper Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event52\\"], \\"names\\": [\\"Qux/Device?\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Qux/Device?\\"}"]'} 14:40:42.157975 435078 pytest DEBUG message_broker.py:76: from reader_client.py:282: Signal=groups: GroupsData(groups={'Foo Device': [], 'Foo Device 2': [, , ], 'Bar Device': [], 'gamepad': [], 'Qux/Device?': []}) Test: Quick cleanup... 14:40:43.775976 436260 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:40:47.741468 436263 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event11, fd 16 14:40:47.773421 436263 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event10, fd 18 14:40:48.136603 436263 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event13, fd 20 14:40:48.555582 436263 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event15, fd 24 Test: Killed pid 436260 because it didn't finish in time Test: Killed pid 436263 because it didn't finish in time 14:41:21.932591 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:41:23.178303 436270 pytest DEBUG shared_dict.py:63: SharedDict process started 14:41:23.178878 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:41:24.145047 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:41:24.737223 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:41:26.544471 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:41:26.601015 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:41:31.122092 436270 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:41:31.153572 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:41:31.179558 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:41:31.421938 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:41:31.935249 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:41:31.960359 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done 14:41:32.743663 435078 pytest DEBUG reader_client.py:120: Sending "terminate" to ReaderService 14:41:32.773366 435078 pytest DEBUG reader_client.py:185: Stopping recorder. 14:41:32.793948 435078 pytest DEBUG reader_client.py:120: Sending "stop-reading" to ReaderService 14:41:33.254807 435078 pytest DEBUG message_broker.py:76: from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ------------------------------ Captured log call ------------------------------- DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" DEBUG input-remapper:pipe.py:133 Ignoring old message [1707853209.5475023, 'terminate'] DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.terminate: . at 0xffffff934a5b20> DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.combination_recorded: INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (3, 16, 1) ABS_HAT0X for /dev/input/event15 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 102, 2) KEY_HOME for /dev/input/event15 DEBUG input-remapper:groups.py:354 Discovering device paths DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" DEBUG input-remapper:groups.py:402 Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:391 "Foo Device qux" has no useful capabilities DEBUG input-remapper:groups.py:402 Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" DEBUG input-remapper:groups.py:402 Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" DEBUG input-remapper:groups.py:402 Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" DEBUG input-remapper:groups.py:395 "YuBiCofooYuBiKeYbar" is denylisted DEBUG input-remapper:groups.py:402 Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" INFO input-remapper:groups.py:481 Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" DEBUG input-remapper:reader_client.py:172 Starting recorder. INFO input-remapper-test:patches.py:310 is_running is patched to always return True DEBUG input-remapper:reader_client.py:120 Sending "Foo Device 2" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started DEBUG input-remapper:reader_client.py:141 received {'type': 'status', 'message': 'ready'} DEBUG input-remapper:reader_client.py:141 received {'type': 'groups', 'message': '["{\\"paths\\": [\\"/dev/input/event1\\"], \\"names\\": [\\"Foo Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Foo Device\\"}", "{\\"paths\\": [\\"/dev/input/event11\\", \\"/dev/input/event10\\", \\"/dev/input/event13\\", \\"/dev/input/event15\\"], \\"names\\": [\\"Foo Device foo\\", \\"Foo Device\\", \\"Foo Device\\", \\"Foo Device bar\\"], \\"types\\": [\\"gamepad\\", \\"keyboard\\", \\"mouse\\"], \\"key\\": \\"Foo Device 2\\"}", "{\\"paths\\": [\\"/dev/input/event20\\"], \\"names\\": [\\"Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event30\\"], \\"names\\": [\\"gamepad\\"], \\"types\\": [\\"gamepad\\"], \\"key\\": \\"gamepad\\"}", "{\\"paths\\": [\\"/dev/input/event40\\"], \\"names\\": [\\"input-remapper Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"input-remapper Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event52\\"], \\"names\\": [\\"Qux/Device?\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Qux/Device?\\"}"]'} DEBUG input-remapper:message_broker.py:76 from reader_client.py:282: Signal=groups: GroupsData(groups={'Foo Device': [], 'Foo Device 2': [, , ], 'Bar Device': [], 'gamepad': [], 'Qux/Device?': []}) INFO input-remapper-test:cleanup.py:87 Quick cleanup... INFO input-remapper-test:cleanup.py:59 Killed pid 436260 because it didn't finish in time INFO input-remapper-test:cleanup.py:59 Killed pid 436263 because it didn't finish in time DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done DEBUG input-remapper:reader_client.py:120 Sending "terminate" to ReaderService DEBUG input-remapper:reader_client.py:185 Stopping recorder. DEBUG input-remapper:reader_client.py:120 Sending "stop-reading" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ___________ TestReaderMultiprocessing.test_reader_service_times_out ____________ self = def test_reader_service_times_out(self): # after some time the reader-service just stops, to avoid leaving a hole # that exposes user-input forever with patch.object(ReaderService, "_maximum_lifetime", 1): self.create_reader_service() self.assertTrue(self.reader_service_process.is_alive()) time.sleep(0.5) self.assertTrue(self.reader_service_process.is_alive()) time.sleep(1) > self.assertFalse(self.reader_service_process.is_alive()) E AssertionError: True is not false tests/unit/test_reader.py:969: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:42:55.987613 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:42:56.038385 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:42:56.573691 435078 pytest DEBUG pipe.py:133: Ignoring old message [1707853371.3773413, 'terminate'] 14:42:56.598414 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.terminate: . at 0xffffff936c94e0> 14:42:57.864663 436280 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:42:58.319905 436280 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:42:58.764934 436280 pytest DEBUG reader_service.py:154: Discovering initial groups 14:42:59.366418 436280 pytest DEBUG groups.py:354: Discovering device paths Test: Quick cleanup... 14:42:59.954746 436280 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:43:00.007550 436280 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:43:00.575094 436280 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:43:01.114229 436279 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:43:01.123542 436280 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:43:01.170012 436280 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:43:01.737956 436280 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:43:02.139261 436280 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:43:02.169862 436280 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:43:02.720125 436280 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:43:03.323313 436280 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:43:03.391955 436280 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:43:03.992566 436280 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:43:04.316389 436280 pytest DEBUG reader_service.py:161: Sending groups 14:43:04.921343 436280 pytest DEBUG reader_service.py:193: Waiting for commands 14:43:06.127594 436280 pytest DEBUG reader_service.py:186: Maximum life-span reached, terminating 14:43:06.986161 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:43:08.377726 436283 pytest DEBUG shared_dict.py:63: SharedDict process started 14:43:08.382638 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:43:09.751388 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:43:09.802076 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:43:12.608658 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:43:12.981116 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:43:16.199344 436283 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:43:16.928255 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:43:16.952386 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:43:16.980401 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:43:17.006927 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:43:17.408917 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done 14:43:17.840473 435078 pytest DEBUG reader_client.py:120: Sending "terminate" to ReaderService 14:43:17.866019 435078 pytest DEBUG reader_client.py:185: Stopping recorder. 14:43:17.888522 435078 pytest DEBUG reader_client.py:120: Sending "stop-reading" to ReaderService 14:43:17.910388 435078 pytest DEBUG reader_client.py:194: No recording generator existed 14:43:18.374800 435078 pytest DEBUG message_broker.py:76: from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ------------------------------ Captured log call ------------------------------- DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" DEBUG input-remapper:pipe.py:133 Ignoring old message [1707853371.3773413, 'terminate'] DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.terminate: . at 0xffffff936c94e0> INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done DEBUG input-remapper:reader_client.py:120 Sending "terminate" to ReaderService DEBUG input-remapper:reader_client.py:185 Stopping recorder. DEBUG input-remapper:reader_client.py:120 Sending "stop-reading" to ReaderService DEBUG input-remapper:reader_client.py:194 No recording generator existed DEBUG input-remapper:message_broker.py:76 from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ___ TestReaderMultiprocessing.test_reader_service_waits_for_client_to_finish ___ self = def test_reader_service_waits_for_client_to_finish(self): # if the client is currently reading, it waits a bit longer until the # client finishes reading with patch.object(ReaderService, "_maximum_lifetime", 1): self.create_reader_service() self.assertTrue(self.reader_service_process.is_alive()) self.reader_client.set_group(self.groups.find(key="Foo Device 2")) self.reader_client.start_recorder() time.sleep(2) # still alive, without start_recorder it should have already exited self.assertTrue(self.reader_service_process.is_alive()) self.reader_client.stop_recorder() time.sleep(1) > self.assertFalse(self.reader_service_process.is_alive()) E AssertionError: True is not false tests/unit/test_reader.py:988: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:43:36.919715 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:43:36.951206 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:43:36.990889 435078 pytest DEBUG pipe.py:133: Ignoring old message [1707853397.859188, 'terminate'] 14:43:37.354531 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.terminate: . at 0xffffff936cab60> 14:43:38.624333 436285 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:43:39.317577 435078 pytest DEBUG groups.py:354: Discovering device paths 14:43:39.326256 436285 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:43:39.772996 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:43:40.135491 436285 pytest DEBUG reader_service.py:154: Discovering initial groups 14:43:40.148078 435078 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:43:40.203144 436285 pytest DEBUG groups.py:354: Discovering device paths 14:43:40.726850 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:43:40.770687 436285 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:43:40.777632 435078 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:43:40.813466 435078 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:43:41.313768 436285 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:43:41.351514 435078 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:43:41.393324 436285 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:43:41.748501 435078 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:43:41.783648 436285 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:43:41.783984 435078 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:43:42.171220 436285 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:43:42.208120 436285 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:43:42.212320 435078 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:43:42.260203 435078 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:43:42.917350 436285 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:43:42.948397 436285 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:43:42.957769 435078 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:43:43.228661 436285 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:43:43.717185 436285 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:43:43.721251 435078 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:43:43.758728 435078 pytest DEBUG reader_client.py:172: Starting recorder. 14:43:43.771344 436285 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" Test: is_running is patched to always return True 14:43:44.321273 435078 pytest DEBUG reader_client.py:120: Sending "Foo Device 2" to ReaderService 14:43:44.389019 435078 pytest DEBUG message_broker.py:76: from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started 14:43:44.392429 436285 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:43:44.722283 436285 pytest DEBUG reader_service.py:161: Sending groups 14:43:45.134050 436285 pytest DEBUG reader_service.py:193: Waiting for commands 14:43:45.194573 436285 pytest DEBUG reader_service.py:195: Received command "Foo Device 2" 14:43:46.731334 435078 pytest DEBUG reader_client.py:185: Stopping recorder. 14:43:46.760348 435078 pytest DEBUG reader_client.py:120: Sending "stop-reading" to ReaderService 14:43:47.143447 435078 pytest DEBUG message_broker.py:76: from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished Test: Quick cleanup... 14:43:49.405407 436283 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:43:51.923643 436285 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event11, fd 16 14:43:51.966401 436285 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event10, fd 18 14:43:51.995028 436285 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event13, fd 20 14:43:52.364071 436285 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event15, fd 24 14:43:52.399526 436285 pytest DEBUG reader_service.py:195: Received command "stop-reading" 14:43:52.930347 436285 pytest DEBUG reader_service.py:177: Waiting a bit longer for the gui to finish reading 14:43:52.986014 436285 pytest DEBUG event_reader.py:108: read loop stopped 14:43:53.341243 436285 pytest INFO event_reader.py:207: read loop for /dev/input/event11 stopped 14:43:53.716342 436285 pytest DEBUG event_reader.py:108: read loop stopped 14:43:53.736053 436285 pytest INFO event_reader.py:207: read loop for /dev/input/event10 stopped 14:43:53.758878 436285 pytest DEBUG event_reader.py:108: read loop stopped 14:43:53.779799 436285 pytest INFO event_reader.py:207: read loop for /dev/input/event13 stopped 14:43:54.341372 436285 pytest DEBUG event_reader.py:108: read loop stopped 14:43:54.369052 436285 pytest INFO event_reader.py:207: read loop for /dev/input/event15 stopped 14:43:54.409073 436285 pytest DEBUG reader_service.py:186: Maximum life-span reached, terminating 14:43:56.121817 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:43:57.170592 436288 pytest DEBUG shared_dict.py:63: SharedDict process started 14:43:58.333230 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:43:59.027603 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:43:59.572245 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:44:02.751123 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:44:03.124172 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:44:06.691055 436288 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:44:06.976961 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:44:07.375933 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:44:07.769424 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:44:07.798505 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:44:07.823142 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done 14:44:08.418391 435078 pytest DEBUG reader_client.py:120: Sending "terminate" to ReaderService 14:44:08.445448 435078 pytest DEBUG reader_client.py:185: Stopping recorder. 14:44:08.463170 435078 pytest DEBUG reader_client.py:120: Sending "stop-reading" to ReaderService 14:44:09.343708 435078 pytest DEBUG reader_client.py:194: No recording generator existed 14:44:09.392708 435078 pytest DEBUG message_broker.py:76: from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ------------------------------ Captured log call ------------------------------- DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" DEBUG input-remapper:pipe.py:133 Ignoring old message [1707853397.859188, 'terminate'] DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.terminate: . at 0xffffff936cab60> DEBUG input-remapper:groups.py:354 Discovering device paths DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" DEBUG input-remapper:groups.py:402 Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:391 "Foo Device qux" has no useful capabilities DEBUG input-remapper:groups.py:402 Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" DEBUG input-remapper:groups.py:402 Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" DEBUG input-remapper:groups.py:402 Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" DEBUG input-remapper:groups.py:395 "YuBiCofooYuBiKeYbar" is denylisted DEBUG input-remapper:groups.py:402 Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" INFO input-remapper:groups.py:481 Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" DEBUG input-remapper:reader_client.py:172 Starting recorder. INFO input-remapper-test:patches.py:310 is_running is patched to always return True DEBUG input-remapper:reader_client.py:120 Sending "Foo Device 2" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started DEBUG input-remapper:reader_client.py:185 Stopping recorder. DEBUG input-remapper:reader_client.py:120 Sending "stop-reading" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done DEBUG input-remapper:reader_client.py:120 Sending "terminate" to ReaderService DEBUG input-remapper:reader_client.py:185 Stopping recorder. DEBUG input-remapper:reader_client.py:120 Sending "stop-reading" to ReaderService DEBUG input-remapper:reader_client.py:194 No recording generator existed DEBUG input-remapper:message_broker.py:76 from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished _______ TestReaderMultiprocessing.test_reader_service_wont_wait_forever ________ self = def test_reader_service_wont_wait_forever(self): # if the client is reading forever, stop it after another timeout with patch.object(ReaderService, "_maximum_lifetime", 1): with patch.object(ReaderService, "_timeout_tolerance", 1): self.create_reader_service() self.assertTrue(self.reader_service_process.is_alive()) self.reader_client.set_group(self.groups.find(key="Foo Device 2")) self.reader_client.start_recorder() time.sleep(1.5) # still alive, without start_recorder it should have already exited self.assertTrue(self.reader_service_process.is_alive()) time.sleep(1) # now it stopped, even though the reader is still reading > self.assertFalse(self.reader_service_process.is_alive()) E AssertionError: True is not false tests/unit/test_reader.py:1006: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:44:58.366600 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:44:58.412961 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:44:59.769137 435078 pytest DEBUG pipe.py:133: Ignoring old message [1707853478.1585395, 'foo'] 14:45:00.155505 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.terminate: . at 0xffffff934a71a0> 14:45:01.986883 436312 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:45:02.913312 435078 pytest DEBUG groups.py:354: Discovering device paths 14:45:02.979355 436312 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:45:03.353909 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:45:03.741189 435078 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:45:03.797973 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:45:04.335332 436312 pytest DEBUG reader_service.py:154: Discovering initial groups 14:45:04.384093 435078 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:45:04.939954 435078 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:45:04.953898 436312 pytest DEBUG groups.py:354: Discovering device paths 14:45:04.973758 435078 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:45:05.006414 436312 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:45:05.527346 435078 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:45:05.538784 436312 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:45:05.558977 435078 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:45:05.969278 435078 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:45:05.974077 436312 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:45:06.002412 436312 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:45:06.010266 435078 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:45:06.523786 436312 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:45:06.556743 435078 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:45:06.918460 436312 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:45:06.995699 436312 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:45:07.525025 435078 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:45:07.567783 436312 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:45:07.582878 435078 pytest DEBUG reader_client.py:172: Starting recorder. Test: is_running is patched to always return True 14:45:08.117080 436312 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:45:08.128486 435078 pytest DEBUG reader_client.py:120: Sending "Foo Device 2" to ReaderService 14:45:08.173245 436312 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:45:08.194382 435078 pytest DEBUG message_broker.py:76: from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started 14:45:08.723426 436312 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:45:09.142907 436312 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:45:09.170656 436312 pytest DEBUG reader_service.py:161: Sending groups 14:45:09.532277 436312 pytest DEBUG reader_service.py:193: Waiting for commands 14:45:10.158076 436312 pytest DEBUG reader_service.py:195: Received command "Foo Device 2" Test: Quick cleanup... 14:45:12.414397 436299 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:45:16.938175 436312 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event11, fd 16 14:45:17.004909 436312 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event10, fd 18 14:45:17.034067 436312 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event13, fd 20 14:45:17.061042 436312 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event15, fd 24 14:45:17.719264 436312 pytest DEBUG reader_service.py:177: Waiting a bit longer for the gui to finish reading 14:45:18.770440 436312 pytest DEBUG reader_service.py:186: Maximum life-span reached, terminating 14:45:21.410661 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:45:22.801274 436328 pytest DEBUG shared_dict.py:63: SharedDict process started 14:45:22.800505 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:45:23.788988 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:45:24.347440 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:45:26.195000 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:45:26.740005 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:45:30.688052 436328 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:45:30.706531 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:45:31.122767 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:45:31.163993 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:45:31.194749 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:45:31.547527 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done 14:45:31.596596 435078 pytest DEBUG reader_client.py:120: Sending "terminate" to ReaderService 14:45:32.132268 435078 pytest DEBUG reader_client.py:185: Stopping recorder. 14:45:32.173168 435078 pytest DEBUG reader_client.py:120: Sending "stop-reading" to ReaderService 14:45:32.754126 435078 pytest DEBUG message_broker.py:76: from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ------------------------------ Captured log call ------------------------------- DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" DEBUG input-remapper:pipe.py:133 Ignoring old message [1707853478.1585395, 'foo'] DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.terminate: . at 0xffffff934a71a0> DEBUG input-remapper:groups.py:354 Discovering device paths DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" DEBUG input-remapper:groups.py:402 Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:391 "Foo Device qux" has no useful capabilities DEBUG input-remapper:groups.py:402 Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" DEBUG input-remapper:groups.py:402 Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" DEBUG input-remapper:groups.py:402 Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" DEBUG input-remapper:groups.py:395 "YuBiCofooYuBiKeYbar" is denylisted DEBUG input-remapper:groups.py:402 Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" INFO input-remapper:groups.py:481 Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" DEBUG input-remapper:reader_client.py:172 Starting recorder. INFO input-remapper-test:patches.py:310 is_running is patched to always return True DEBUG input-remapper:reader_client.py:120 Sending "Foo Device 2" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started INFO input-remapper-test:cleanup.py:87 Quick cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done DEBUG input-remapper:reader_client.py:120 Sending "terminate" to ReaderService DEBUG input-remapper:reader_client.py:185 Stopping recorder. DEBUG input-remapper:reader_client.py:120 Sending "stop-reading" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ____________________ TestReaderMultiprocessing.test_reading ____________________ self = def test_reading(self): l1 = Listener() l2 = Listener() self.message_broker.subscribe(MessageType.combination_recorded, l1) self.message_broker.subscribe(MessageType.recording_finished, l2) self.create_reader_service() self.reader_client.set_group(self.groups.find(key="Foo Device 2")) self.reader_client.start_recorder() push_events(fixtures.foo_device_2_gamepad, [InputEvent.abs(ABS_HAT0X, 1)]) # we need to sleep because we have two different fixtures, # which will lead to race conditions time.sleep(0.1) # relative axis events should be released automagically after 0.3s push_events(fixtures.foo_device_2_mouse, [InputEvent.rel(REL_X, 5)]) time.sleep(0.1) # read all pending events. Having a glib mainloop would be better, # as it would call read automatically periodically self.reader_client._read() > self.assertEqual( [ CombinationRecorded( InputCombination( [ InputConfig( type=3, code=16, analog_threshold=1, origin_hash=fixtures.foo_device_2_gamepad.get_device_hash(), ) ] ) ), CombinationRecorded( InputCombination( [ InputConfig( type=3, code=16, analog_threshold=1, origin_hash=fixtures.foo_device_2_gamepad.get_device_hash(), ), InputConfig( type=2, code=0, analog_threshold=1, origin_hash=fixtures.foo_device_2_mouse.get_device_hash(), ), ] ) ), ], l1.calls, ) E AssertionError: Lists differ: [CombinationRecorded(combination=)] != [] E E First list contains 2 additional elements. E First extra element 0: E CombinationRecorded(combination=) at 0xffffff931eefd0>) E E + [] E - [CombinationRecorded(combination=) at 0xffffff931eefd0>), E - CombinationRecorded(combination=, ) at 0xffffff931ef930>)] tests/unit/test_reader.py:216: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:45:51.551293 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:45:51.932121 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:45:51.967722 435078 pytest DEBUG pipe.py:133: Ignoring old message [1707853532.116751, 'terminate'] 14:45:51.992932 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.terminate: . at 0xffffff93224ae0> 14:45:52.339901 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.combination_recorded: 14:45:52.368816 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.recording_finished: 14:45:53.990849 436338 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:45:54.518061 435078 pytest DEBUG groups.py:354: Discovering device paths 14:45:54.562357 436338 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:45:54.599803 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:45:55.141202 435078 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:45:55.157493 436338 pytest DEBUG reader_service.py:154: Discovering initial groups 14:45:55.193461 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:45:55.548591 436338 pytest DEBUG groups.py:354: Discovering device paths 14:45:55.552856 435078 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:45:55.924667 435078 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:45:55.965507 435078 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:45:55.960648 436338 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:45:56.014315 436338 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:45:56.033715 435078 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:45:56.559513 435078 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:45:56.573551 436338 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:45:56.609393 436338 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:45:57.718680 435078 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:45:57.740216 436338 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:45:57.753227 435078 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:45:57.768616 436338 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:45:58.128428 435078 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:45:58.189297 436338 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:45:58.717769 436338 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:45:58.720927 435078 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:45:58.766966 435078 pytest DEBUG reader_client.py:172: Starting recorder. 14:45:59.120942 436338 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" Test: is_running is patched to always return True 14:45:59.142706 435078 pytest DEBUG reader_client.py:120: Sending "Foo Device 2" to ReaderService 14:45:59.181012 436338 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:45:59.210103 435078 pytest DEBUG message_broker.py:76: from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started 14:45:59.726049 436338 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" Test: Simulating InputEvent for (3, 16, 1) ABS_HAT0X for /dev/input/event15 Test: Simulating InputEvent for (2, 0, 5) REL_X for /dev/input/event11 14:46:00.166016 436338 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:46:00.730447 435078 pytest DEBUG reader_client.py:141: received {'type': 'status', 'message': 'ready'} 14:46:00.750534 436338 pytest DEBUG reader_service.py:161: Sending groups Test: Hash for fixture "/dev/input/event15" "Foo Device bar": "cee831d56755e4bac5b0f5d2fcfd5735" Test: Hash for fixture "/dev/input/event15" "Foo Device bar": "cee831d56755e4bac5b0f5d2fcfd5735" Test: Hash for fixture "/dev/input/event11" "Foo Device foo": "77605ea88cd2159e71044704ef068863" 14:46:01.405605 436338 pytest DEBUG reader_service.py:193: Waiting for commands 14:46:02.327030 436338 pytest DEBUG reader_service.py:195: Received command "Foo Device 2" Test: Quick cleanup... 14:46:04.161547 436328 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:46:08.920621 436338 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event11, fd 16 14:46:08.956857 436338 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event10, fd 18 14:46:09.334606 436338 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event13, fd 20 14:46:09.368527 436338 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event15, fd 24 Test: Killed pid 436328 because it didn't finish in time Test: Killed pid 436338 because it didn't finish in time 14:46:36.535055 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:46:37.400923 436343 pytest DEBUG shared_dict.py:63: SharedDict process started 14:46:37.775210 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:46:38.934139 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:46:38.982290 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:46:42.170817 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:46:42.590153 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:46:48.176415 436343 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:46:48.720208 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:46:48.769817 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:46:49.348339 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:46:49.383138 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:46:49.414871 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done 14:46:49.955133 435078 pytest DEBUG reader_client.py:120: Sending "terminate" to ReaderService 14:46:49.987871 435078 pytest DEBUG reader_client.py:185: Stopping recorder. 14:46:50.010918 435078 pytest DEBUG reader_client.py:120: Sending "stop-reading" to ReaderService 14:46:50.398291 435078 pytest DEBUG message_broker.py:76: from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ------------------------------ Captured log call ------------------------------- DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" DEBUG input-remapper:pipe.py:133 Ignoring old message [1707853532.116751, 'terminate'] DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.terminate: . at 0xffffff93224ae0> DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.combination_recorded: DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.recording_finished: DEBUG input-remapper:groups.py:354 Discovering device paths DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" DEBUG input-remapper:groups.py:402 Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:391 "Foo Device qux" has no useful capabilities DEBUG input-remapper:groups.py:402 Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" DEBUG input-remapper:groups.py:402 Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" DEBUG input-remapper:groups.py:402 Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" DEBUG input-remapper:groups.py:395 "YuBiCofooYuBiKeYbar" is denylisted DEBUG input-remapper:groups.py:402 Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" INFO input-remapper:groups.py:481 Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" DEBUG input-remapper:reader_client.py:172 Starting recorder. INFO input-remapper-test:patches.py:310 is_running is patched to always return True DEBUG input-remapper:reader_client.py:120 Sending "Foo Device 2" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (3, 16, 1) ABS_HAT0X for /dev/input/event15 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (2, 0, 5) REL_X for /dev/input/event11 DEBUG input-remapper:reader_client.py:141 received {'type': 'status', 'message': 'ready'} INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event15" "Foo Device bar": "cee831d56755e4bac5b0f5d2fcfd5735" INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event15" "Foo Device bar": "cee831d56755e4bac5b0f5d2fcfd5735" INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event11" "Foo Device foo": "77605ea88cd2159e71044704ef068863" INFO input-remapper-test:cleanup.py:87 Quick cleanup... INFO input-remapper-test:cleanup.py:59 Killed pid 436328 because it didn't finish in time INFO input-remapper-test:cleanup.py:59 Killed pid 436338 because it didn't finish in time DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done DEBUG input-remapper:reader_client.py:120 Sending "terminate" to ReaderService DEBUG input-remapper:reader_client.py:185 Stopping recorder. DEBUG input-remapper:reader_client.py:120 Sending "stop-reading" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ___________________ TestReaderMultiprocessing.test_reading_2 ___________________ self = def test_reading_2(self): l1 = Listener() self.message_broker.subscribe(MessageType.combination_recorded, l1) # a combination of events push_events( fixtures.foo_device_2_keyboard, [ new_event(EV_KEY, CODE_1, 1, 10000.1234), new_event(EV_KEY, CODE_3, 1, 10001.1234), ], ) pipe = multiprocessing.Pipe() def refresh(): # from within the reader-service process notify this test that # refresh was called as expected pipe[1].send("refreshed") groups = _Groups() groups.refresh = refresh self.create_reader_service(groups) self.reader_client.set_group(self.groups.find(key="Foo Device 2")) self.reader_client.start_recorder() # sending anything arbitrary does not stop the reader-service self.reader_client._commands_pipe.send(856794) time.sleep(0.2) push_events( fixtures.foo_device_2_gamepad, [new_event(EV_ABS, ABS_HAT0X, -1, 10002.1234)], ) time.sleep(0.1) # but it makes it look for new devices because maybe its list of # self.groups is not up-to-date self.assertTrue(pipe[0].poll()) self.assertEqual(pipe[0].recv(), "refreshed") self.reader_client._read() self.assertEqual( > l1.calls[-1].combination, InputCombination( [ InputConfig( type=EV_KEY, code=CODE_1, origin_hash=fixtures.foo_device_2_keyboard.get_device_hash(), ), InputConfig( type=EV_KEY, code=CODE_3, origin_hash=fixtures.foo_device_2_keyboard.get_device_hash(), ), InputConfig( type=EV_ABS, code=ABS_HAT0X, analog_threshold=-1, origin_hash=fixtures.foo_device_2_gamepad.get_device_hash(), ), ] ), ) E IndexError: list index out of range tests/unit/test_reader.py:659: IndexError ----------------------------- Captured stderr call ----------------------------- 14:47:10.993007 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:47:11.735097 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:47:11.773817 435078 pytest DEBUG pipe.py:133: Ignoring old message [1707853609.979263, 'terminate'] 14:47:11.797526 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.terminate: . at 0xffffff932245e0> 14:47:12.146587 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.combination_recorded: Test: Simulating InputEvent for (1, 100, 1) KEY_RIGHTALT for /dev/input/event10 Test: Simulating InputEvent for (1, 102, 1) KEY_HOME for /dev/input/event10 14:47:14.188585 436347 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:47:14.195444 435078 pytest DEBUG groups.py:354: Discovering device paths 14:47:14.578137 436347 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:47:15.143653 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:47:15.209978 435078 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:47:15.714672 436347 pytest DEBUG reader_service.py:154: Discovering initial groups 14:47:15.782188 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:47:15.824018 435078 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:47:15.820510 436347 pytest DEBUG groups.py:354: Discovering device paths 14:47:16.359785 435078 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:47:16.375914 436347 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:47:16.401309 435078 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:47:16.409525 436347 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:47:16.751386 435078 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:47:16.754390 436347 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:47:16.779524 436347 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:47:16.981271 435078 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:47:17.016247 436347 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:47:17.342463 435078 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:47:17.366764 436347 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:47:17.550403 435078 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:47:17.915231 436347 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:47:17.949288 436347 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:47:17.972116 435078 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:47:18.003247 436347 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:47:18.757789 436347 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:47:18.774131 435078 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:47:18.803046 435078 pytest DEBUG reader_client.py:172: Starting recorder. 14:47:18.810875 436347 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" Test: is_running is patched to always return True 14:47:19.185535 435078 pytest DEBUG reader_client.py:120: Sending "Foo Device 2" to ReaderService 14:47:19.521834 436347 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:47:19.549175 435078 pytest DEBUG message_broker.py:76: from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started 14:47:19.554311 436347 pytest DEBUG reader_service.py:161: Sending groups 14:47:19.601985 436347 pytest DEBUG reader_service.py:193: Waiting for commands Test: Simulating InputEvent for (3, 16, -1) ABS_HAT0X for /dev/input/event15 14:47:20.520731 436347 pytest DEBUG reader_service.py:195: Received command "Foo Device 2" 14:47:20.545264 435078 pytest DEBUG reader_client.py:141: received {'type': 'status', 'message': 'ready'} 14:47:20.573861 435078 pytest DEBUG reader_client.py:141: received {'type': 'groups', 'message': '["{\\"paths\\": [\\"/dev/input/event1\\"], \\"names\\": [\\"Foo Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Foo Device\\"}", "{\\"paths\\": [\\"/dev/input/event11\\", \\"/dev/input/event10\\", \\"/dev/input/event13\\", \\"/dev/input/event15\\"], \\"names\\": [\\"Foo Device foo\\", \\"Foo Device\\", \\"Foo Device\\", \\"Foo Device bar\\"], \\"types\\": [\\"gamepad\\", \\"keyboard\\", \\"mouse\\"], \\"key\\": \\"Foo Device 2\\"}", "{\\"paths\\": [\\"/dev/input/event20\\"], \\"names\\": [\\"Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event30\\"], \\"names\\": [\\"gamepad\\"], \\"types\\": [\\"gamepad\\"], \\"key\\": \\"gamepad\\"}", "{\\"paths\\": [\\"/dev/input/event40\\"], \\"names\\": [\\"input-remapper Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"input-remapper Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event52\\"], \\"names\\": [\\"Qux/Device?\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Qux/Device?\\"}"]'} 14:47:21.121010 435078 pytest DEBUG message_broker.py:76: from reader_client.py:282: Signal=groups: GroupsData(groups={'Foo Device': [], 'Foo Device 2': [, , ], 'Bar Device': [], 'gamepad': [], 'Qux/Device?': []}) Test: Quick cleanup... 14:47:22.349816 436343 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:47:25.944140 436347 pytest DEBUG reader_service.py:195: Received command "856794" 14:47:26.338814 436347 pytest DEBUG groups.py:354: Discovering device paths 14:47:26.384771 436347 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:47:26.415705 436347 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:47:26.780704 436347 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:47:27.154107 436347 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:47:27.189807 436347 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:47:27.232187 436347 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:47:27.766589 436347 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:47:27.796137 436347 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:47:28.338952 436347 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:47:28.369506 436347 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:47:28.412867 436347 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:47:28.954570 436347 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:47:28.983301 436347 pytest ERROR reader_service.py:222: Received unknown command "856794" 14:47:29.349559 436347 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event11, fd 16 14:47:29.398910 436347 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event10, fd 18 14:47:29.429880 436347 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event13, fd 20 14:47:29.773126 436347 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event15, fd 24 Test: Killed pid 436343 because it didn't finish in time Test: Killed pid 436347 because it didn't finish in time 14:47:56.528042 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:47:58.125160 436370 pytest DEBUG shared_dict.py:63: SharedDict process started 14:47:58.129985 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:47:58.970987 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:47:59.005603 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:48:03.409188 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:48:04.197922 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:48:07.588685 436370 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:48:07.609623 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:48:07.941038 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:48:07.995311 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:48:08.337173 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:48:08.550022 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done 14:48:08.949547 435078 pytest DEBUG reader_client.py:120: Sending "terminate" to ReaderService 14:48:08.980977 435078 pytest DEBUG reader_client.py:185: Stopping recorder. 14:48:09.000136 435078 pytest DEBUG reader_client.py:120: Sending "stop-reading" to ReaderService 14:48:09.774505 435078 pytest DEBUG message_broker.py:76: from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ------------------------------ Captured log call ------------------------------- DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" DEBUG input-remapper:pipe.py:133 Ignoring old message [1707853609.979263, 'terminate'] DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.terminate: . at 0xffffff932245e0> DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.combination_recorded: INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 100, 1) KEY_RIGHTALT for /dev/input/event10 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 102, 1) KEY_HOME for /dev/input/event10 DEBUG input-remapper:groups.py:354 Discovering device paths DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" DEBUG input-remapper:groups.py:402 Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:391 "Foo Device qux" has no useful capabilities DEBUG input-remapper:groups.py:402 Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" DEBUG input-remapper:groups.py:402 Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" DEBUG input-remapper:groups.py:402 Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" DEBUG input-remapper:groups.py:395 "YuBiCofooYuBiKeYbar" is denylisted DEBUG input-remapper:groups.py:402 Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" INFO input-remapper:groups.py:481 Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" DEBUG input-remapper:reader_client.py:172 Starting recorder. INFO input-remapper-test:patches.py:310 is_running is patched to always return True DEBUG input-remapper:reader_client.py:120 Sending "Foo Device 2" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (3, 16, -1) ABS_HAT0X for /dev/input/event15 DEBUG input-remapper:reader_client.py:141 received {'type': 'status', 'message': 'ready'} DEBUG input-remapper:reader_client.py:141 received {'type': 'groups', 'message': '["{\\"paths\\": [\\"/dev/input/event1\\"], \\"names\\": [\\"Foo Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Foo Device\\"}", "{\\"paths\\": [\\"/dev/input/event11\\", \\"/dev/input/event10\\", \\"/dev/input/event13\\", \\"/dev/input/event15\\"], \\"names\\": [\\"Foo Device foo\\", \\"Foo Device\\", \\"Foo Device\\", \\"Foo Device bar\\"], \\"types\\": [\\"gamepad\\", \\"keyboard\\", \\"mouse\\"], \\"key\\": \\"Foo Device 2\\"}", "{\\"paths\\": [\\"/dev/input/event20\\"], \\"names\\": [\\"Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event30\\"], \\"names\\": [\\"gamepad\\"], \\"types\\": [\\"gamepad\\"], \\"key\\": \\"gamepad\\"}", "{\\"paths\\": [\\"/dev/input/event40\\"], \\"names\\": [\\"input-remapper Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"input-remapper Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event52\\"], \\"names\\": [\\"Qux/Device?\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Qux/Device?\\"}"]'} DEBUG input-remapper:message_broker.py:76 from reader_client.py:282: Signal=groups: GroupsData(groups={'Foo Device': [], 'Foo Device 2': [, , ], 'Bar Device': [], 'gamepad': [], 'Qux/Device?': []}) INFO input-remapper-test:cleanup.py:87 Quick cleanup... INFO input-remapper-test:cleanup.py:59 Killed pid 436343 because it didn't finish in time INFO input-remapper-test:cleanup.py:59 Killed pid 436347 because it didn't finish in time DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done DEBUG input-remapper:reader_client.py:120 Sending "terminate" to ReaderService DEBUG input-remapper:reader_client.py:185 Stopping recorder. DEBUG input-remapper:reader_client.py:120 Sending "stop-reading" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished _______________ TestReaderMultiprocessing.test_reading_ignore_up _______________ self = def test_reading_ignore_up(self): l1 = Listener() self.message_broker.subscribe(MessageType.combination_recorded, l1) push_events( fixtures.foo_device_2_keyboard, [ new_event(EV_KEY, CODE_1, 0, 10), new_event(EV_KEY, CODE_2, 1, 11), new_event(EV_KEY, CODE_3, 0, 12), ], ) self.create_reader_service() self.reader_client.set_group(self.groups.find(key="Foo Device 2")) self.reader_client.start_recorder() time.sleep(0.1) self.reader_client._read() self.assertEqual( > l1.calls[-1].combination, InputCombination( [ InputConfig( type=EV_KEY, code=CODE_2, origin_hash=fixtures.foo_device_2_keyboard.get_device_hash(), ) ] ), ) E IndexError: list index out of range tests/unit/test_reader.py:758: IndexError ----------------------------- Captured stderr call ----------------------------- 14:48:28.374455 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:48:28.742664 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:48:28.784914 435078 pytest DEBUG pipe.py:133: Ignoring old message [1707853688.9701095, 'terminate'] 14:48:28.811346 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.terminate: . at 0xffffff932254e0> 14:48:29.352710 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.combination_recorded: Test: Simulating InputEvent for (1, 100, 0) KEY_RIGHTALT for /dev/input/event10 Test: Simulating InputEvent for (1, 101, 1) KEY_LINEFEED for /dev/input/event10 Test: Simulating InputEvent for (1, 102, 0) KEY_HOME for /dev/input/event10 14:48:31.055061 436374 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:48:31.557127 436374 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:48:31.566422 435078 pytest DEBUG groups.py:354: Discovering device paths 14:48:31.982453 436374 pytest DEBUG reader_service.py:154: Discovering initial groups 14:48:32.368500 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:48:32.730604 435078 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:48:32.738424 436374 pytest DEBUG groups.py:354: Discovering device paths 14:48:32.784458 436374 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:48:32.793480 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:48:32.813153 436374 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:48:33.191020 435078 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:48:33.523110 436374 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:48:33.520570 435078 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:48:33.553911 436374 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:48:33.568911 435078 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:48:33.580982 436374 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:48:33.609624 436374 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:48:33.614166 435078 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:48:34.144052 435078 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:48:34.180207 436374 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:48:34.546674 436374 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:48:34.562430 435078 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:48:34.595443 436374 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:48:34.597086 435078 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:48:35.118608 436374 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:48:35.165247 435078 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:48:35.173381 436374 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:48:36.939933 436374 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:48:36.973255 435078 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:48:37.007805 435078 pytest DEBUG reader_client.py:172: Starting recorder. 14:48:37.008207 436374 pytest DEBUG reader_service.py:161: Sending groups Test: is_running is patched to always return True 14:48:37.346433 435078 pytest DEBUG reader_client.py:120: Sending "Foo Device 2" to ReaderService 14:48:37.369581 436374 pytest DEBUG reader_service.py:193: Waiting for commands 14:48:37.404162 435078 pytest DEBUG message_broker.py:76: from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started 14:48:37.746618 436374 pytest DEBUG reader_service.py:195: Received command "Foo Device 2" 14:48:38.126717 435078 pytest DEBUG reader_client.py:141: received {'type': 'status', 'message': 'ready'} 14:48:38.161316 435078 pytest DEBUG reader_client.py:141: received {'type': 'groups', 'message': '["{\\"paths\\": [\\"/dev/input/event1\\"], \\"names\\": [\\"Foo Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Foo Device\\"}", "{\\"paths\\": [\\"/dev/input/event11\\", \\"/dev/input/event10\\", \\"/dev/input/event13\\", \\"/dev/input/event15\\"], \\"names\\": [\\"Foo Device foo\\", \\"Foo Device\\", \\"Foo Device\\", \\"Foo Device bar\\"], \\"types\\": [\\"gamepad\\", \\"keyboard\\", \\"mouse\\"], \\"key\\": \\"Foo Device 2\\"}", "{\\"paths\\": [\\"/dev/input/event20\\"], \\"names\\": [\\"Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event30\\"], \\"names\\": [\\"gamepad\\"], \\"types\\": [\\"gamepad\\"], \\"key\\": \\"gamepad\\"}", "{\\"paths\\": [\\"/dev/input/event40\\"], \\"names\\": [\\"input-remapper Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"input-remapper Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event52\\"], \\"names\\": [\\"Qux/Device?\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Qux/Device?\\"}"]'} 14:48:38.750144 435078 pytest DEBUG message_broker.py:76: from reader_client.py:282: Signal=groups: GroupsData(groups={'Foo Device': [], 'Foo Device 2': [, , ], 'Bar Device': [], 'gamepad': [], 'Qux/Device?': []}) Test: Quick cleanup... 14:48:40.233931 436370 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:48:43.379955 436374 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event11, fd 16 14:48:43.423878 436374 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event10, fd 18 14:48:43.946976 436374 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event13, fd 20 14:48:43.983441 436374 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event15, fd 24 Test: Killed pid 436370 because it didn't finish in time Test: Killed pid 436374 because it didn't finish in time 14:49:10.610776 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:49:11.979127 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:49:11.981132 436377 pytest DEBUG shared_dict.py:63: SharedDict process started 14:49:13.192833 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:49:13.540882 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:49:15.763631 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:49:16.138394 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:49:18.824187 436377 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:49:19.174486 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:49:19.354617 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:49:19.598977 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:49:19.629873 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:49:19.956268 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done 14:49:20.326799 435078 pytest DEBUG reader_client.py:120: Sending "terminate" to ReaderService 14:49:20.362669 435078 pytest DEBUG reader_client.py:185: Stopping recorder. 14:49:20.404123 435078 pytest DEBUG reader_client.py:120: Sending "stop-reading" to ReaderService 14:49:20.771551 435078 pytest DEBUG message_broker.py:76: from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ------------------------------ Captured log call ------------------------------- DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" DEBUG input-remapper:pipe.py:133 Ignoring old message [1707853688.9701095, 'terminate'] DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.terminate: . at 0xffffff932254e0> DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.combination_recorded: INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 100, 0) KEY_RIGHTALT for /dev/input/event10 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 101, 1) KEY_LINEFEED for /dev/input/event10 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 102, 0) KEY_HOME for /dev/input/event10 DEBUG input-remapper:groups.py:354 Discovering device paths DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" DEBUG input-remapper:groups.py:402 Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:391 "Foo Device qux" has no useful capabilities DEBUG input-remapper:groups.py:402 Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" DEBUG input-remapper:groups.py:402 Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" DEBUG input-remapper:groups.py:402 Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" DEBUG input-remapper:groups.py:395 "YuBiCofooYuBiKeYbar" is denylisted DEBUG input-remapper:groups.py:402 Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" INFO input-remapper:groups.py:481 Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" DEBUG input-remapper:reader_client.py:172 Starting recorder. INFO input-remapper-test:patches.py:310 is_running is patched to always return True DEBUG input-remapper:reader_client.py:120 Sending "Foo Device 2" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started DEBUG input-remapper:reader_client.py:141 received {'type': 'status', 'message': 'ready'} DEBUG input-remapper:reader_client.py:141 received {'type': 'groups', 'message': '["{\\"paths\\": [\\"/dev/input/event1\\"], \\"names\\": [\\"Foo Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Foo Device\\"}", "{\\"paths\\": [\\"/dev/input/event11\\", \\"/dev/input/event10\\", \\"/dev/input/event13\\", \\"/dev/input/event15\\"], \\"names\\": [\\"Foo Device foo\\", \\"Foo Device\\", \\"Foo Device\\", \\"Foo Device bar\\"], \\"types\\": [\\"gamepad\\", \\"keyboard\\", \\"mouse\\"], \\"key\\": \\"Foo Device 2\\"}", "{\\"paths\\": [\\"/dev/input/event20\\"], \\"names\\": [\\"Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event30\\"], \\"names\\": [\\"gamepad\\"], \\"types\\": [\\"gamepad\\"], \\"key\\": \\"gamepad\\"}", "{\\"paths\\": [\\"/dev/input/event40\\"], \\"names\\": [\\"input-remapper Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"input-remapper Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event52\\"], \\"names\\": [\\"Qux/Device?\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Qux/Device?\\"}"]'} DEBUG input-remapper:message_broker.py:76 from reader_client.py:282: Signal=groups: GroupsData(groups={'Foo Device': [], 'Foo Device 2': [, , ], 'Bar Device': [], 'gamepad': [], 'Qux/Device?': []}) INFO input-remapper-test:cleanup.py:87 Quick cleanup... INFO input-remapper-test:cleanup.py:59 Killed pid 436370 because it didn't finish in time INFO input-remapper-test:cleanup.py:59 Killed pid 436374 because it didn't finish in time DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done DEBUG input-remapper:reader_client.py:120 Sending "terminate" to ReaderService DEBUG input-remapper:reader_client.py:185 Stopping recorder. DEBUG input-remapper:reader_client.py:120 Sending "stop-reading" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ____________ TestReaderMultiprocessing.test_should_change_direction ____________ self = def test_should_change_direction(self): l1 = Listener() self.message_broker.subscribe(MessageType.combination_recorded, l1) self.create_reader_service() self.reader_client.set_group(self.groups.find(key="Foo Device 2")) self.reader_client.start_recorder() push_event(fixtures.foo_device_2_keyboard, InputEvent.key(KEY_A, 1)) time.sleep(0.1) push_event( fixtures.foo_device_2_gamepad, InputEvent.abs(ABS_X, int(MAX_ABS * 0.4)) ) time.sleep(0.1) push_event(fixtures.foo_device_2_keyboard, InputEvent.key(KEY_COMMA, 1)) time.sleep(0.1) push_events( fixtures.foo_device_2_gamepad, [ InputEvent.abs(ABS_X, int(MAX_ABS * 0.1)), InputEvent.abs(ABS_X, int(MIN_ABS * 0.4)), ], ) time.sleep(0.1) self.reader_client._read() > self.assertEqual( [ CombinationRecorded( InputCombination( [ InputConfig( type=EV_KEY, code=KEY_A, origin_hash=fixtures.foo_device_2_keyboard.get_device_hash(), ) ] ) ), CombinationRecorded( InputCombination( [ InputConfig( type=EV_KEY, code=KEY_A, origin_hash=fixtures.foo_device_2_keyboard.get_device_hash(), ), InputConfig( type=EV_ABS, code=ABS_X, analog_threshold=1, origin_hash=fixtures.foo_device_2_gamepad.get_device_hash(), ), ] ) ), CombinationRecorded( InputCombination( [ InputConfig( type=EV_KEY, code=KEY_A, origin_hash=fixtures.foo_device_2_keyboard.get_device_hash(), ), InputConfig( type=EV_ABS, code=ABS_X, analog_threshold=1, origin_hash=fixtures.foo_device_2_gamepad.get_device_hash(), ), InputConfig( type=EV_KEY, code=KEY_COMMA, origin_hash=fixtures.foo_device_2_keyboard.get_device_hash(), ), ] ) ), CombinationRecorded( InputCombination( [ InputConfig( type=EV_KEY, code=KEY_A, origin_hash=fixtures.foo_device_2_keyboard.get_device_hash(), ), InputConfig( type=EV_ABS, code=ABS_X, analog_threshold=-1, origin_hash=fixtures.foo_device_2_gamepad.get_device_hash(), ), InputConfig( type=EV_KEY, code=KEY_COMMA, origin_hash=fixtures.foo_device_2_keyboard.get_device_hash(), ), ] ) ), ], l1.calls, ) E AssertionError: Lists differ: [CombinationRecorded(combination=)] != [] E E First list contains 4 additional elements. E First extra element 0: E CombinationRecorded(combination=) at 0xffffff934edb80>) E E Diff is 1120 characters long. Set self.maxDiff to None to see it. tests/unit/test_reader.py:476: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:49:38.009513 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:49:38.384323 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:49:38.775678 435078 pytest DEBUG pipe.py:133: Ignoring old message [1707853760.3546174, 'terminate'] 14:49:38.804812 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.terminate: . at 0xffffff93224e00> 14:49:39.340207 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.combination_recorded: 14:49:40.756246 436383 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:49:41.167162 436383 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:49:41.158226 435078 pytest DEBUG groups.py:354: Discovering device paths 14:49:41.947026 436383 pytest DEBUG reader_service.py:154: Discovering initial groups 14:49:41.956723 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:49:41.994115 435078 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:49:42.006692 436383 pytest DEBUG groups.py:354: Discovering device paths 14:49:42.368969 436383 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:49:42.722192 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:49:42.748220 436383 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:49:42.749786 435078 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:49:42.772769 435078 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:49:42.794040 436383 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:49:42.801346 435078 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:49:43.329796 436383 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:49:43.362407 436383 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:49:43.725441 435078 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:49:43.737153 436383 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:49:43.759012 435078 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:49:43.799782 436383 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:49:43.812884 435078 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:49:44.237181 436383 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:49:44.265551 435078 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:49:44.738533 436383 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:49:44.736483 435078 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:49:44.780456 436383 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:49:45.153959 436383 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:49:45.181094 435078 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:49:45.566810 435078 pytest DEBUG reader_client.py:172: Starting recorder. 14:49:45.587757 436383 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" Test: is_running is patched to always return True 14:49:45.605162 435078 pytest DEBUG reader_client.py:120: Sending "Foo Device 2" to ReaderService 14:49:45.614458 436383 pytest DEBUG reader_service.py:161: Sending groups 14:49:46.153430 436383 pytest DEBUG reader_service.py:193: Waiting for commands 14:49:46.154378 435078 pytest DEBUG message_broker.py:76: from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started Test: Simulating InputEvent for (1, 30, 1) KEY_A for /dev/input/event10 14:49:46.753593 436383 pytest DEBUG reader_service.py:195: Received command "Foo Device 2" Test: Simulating InputEvent for (3, 0, 13107) ABS_X for /dev/input/event15 Test: Simulating InputEvent for (1, 51, 1) KEY_COMMA for /dev/input/event10 Test: Simulating InputEvent for (3, 0, 3276) ABS_X for /dev/input/event15 Test: Simulating InputEvent for (3, 0, -13107) ABS_X for /dev/input/event15 14:49:48.345495 435078 pytest DEBUG reader_client.py:141: received {'type': 'status', 'message': 'ready'} 14:49:48.385021 435078 pytest DEBUG reader_client.py:141: received {'type': 'groups', 'message': '["{\\"paths\\": [\\"/dev/input/event1\\"], \\"names\\": [\\"Foo Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Foo Device\\"}", "{\\"paths\\": [\\"/dev/input/event11\\", \\"/dev/input/event10\\", \\"/dev/input/event13\\", \\"/dev/input/event15\\"], \\"names\\": [\\"Foo Device foo\\", \\"Foo Device\\", \\"Foo Device\\", \\"Foo Device bar\\"], \\"types\\": [\\"gamepad\\", \\"keyboard\\", \\"mouse\\"], \\"key\\": \\"Foo Device 2\\"}", "{\\"paths\\": [\\"/dev/input/event20\\"], \\"names\\": [\\"Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event30\\"], \\"names\\": [\\"gamepad\\"], \\"types\\": [\\"gamepad\\"], \\"key\\": \\"gamepad\\"}", "{\\"paths\\": [\\"/dev/input/event40\\"], \\"names\\": [\\"input-remapper Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"input-remapper Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event52\\"], \\"names\\": [\\"Qux/Device?\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Qux/Device?\\"}"]'} 14:49:48.964202 435078 pytest DEBUG message_broker.py:76: from reader_client.py:282: Signal=groups: GroupsData(groups={'Foo Device': [], 'Foo Device 2': [, , ], 'Bar Device': [], 'gamepad': [], 'Qux/Device?': []}) Test: Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" Test: Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" Test: Hash for fixture "/dev/input/event15" "Foo Device bar": "cee831d56755e4bac5b0f5d2fcfd5735" Test: Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" Test: Hash for fixture "/dev/input/event15" "Foo Device bar": "cee831d56755e4bac5b0f5d2fcfd5735" Test: Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" Test: Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" Test: Hash for fixture "/dev/input/event15" "Foo Device bar": "cee831d56755e4bac5b0f5d2fcfd5735" Test: Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" Test: Quick cleanup... 14:49:52.741305 436377 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:49:54.602826 436383 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event11, fd 16 14:49:55.134102 436383 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event10, fd 18 14:49:55.163649 436383 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event13, fd 20 14:49:55.534357 436383 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event15, fd 24 Test: Killed pid 436377 because it didn't finish in time Test: Killed pid 436383 because it didn't finish in time 14:50:24.985022 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:50:26.383204 436389 pytest DEBUG shared_dict.py:63: SharedDict process started 14:50:26.407628 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:50:27.201029 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:50:27.597116 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:50:30.394939 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:50:30.742632 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:50:33.972027 436389 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:50:34.336887 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:50:34.363534 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:50:34.727328 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:50:34.753205 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:50:34.776573 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done 14:50:34.815779 435078 pytest DEBUG reader_client.py:120: Sending "terminate" to ReaderService 14:50:35.347646 435078 pytest DEBUG reader_client.py:185: Stopping recorder. 14:50:35.372311 435078 pytest DEBUG reader_client.py:120: Sending "stop-reading" to ReaderService 14:50:35.770741 435078 pytest DEBUG message_broker.py:76: from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ------------------------------ Captured log call ------------------------------- DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" DEBUG input-remapper:pipe.py:133 Ignoring old message [1707853760.3546174, 'terminate'] DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.terminate: . at 0xffffff93224e00> DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.combination_recorded: DEBUG input-remapper:groups.py:354 Discovering device paths DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" DEBUG input-remapper:groups.py:402 Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:391 "Foo Device qux" has no useful capabilities DEBUG input-remapper:groups.py:402 Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" DEBUG input-remapper:groups.py:402 Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" DEBUG input-remapper:groups.py:402 Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" DEBUG input-remapper:groups.py:395 "YuBiCofooYuBiKeYbar" is denylisted DEBUG input-remapper:groups.py:402 Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" INFO input-remapper:groups.py:481 Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" DEBUG input-remapper:reader_client.py:172 Starting recorder. INFO input-remapper-test:patches.py:310 is_running is patched to always return True DEBUG input-remapper:reader_client.py:120 Sending "Foo Device 2" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 30, 1) KEY_A for /dev/input/event10 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (3, 0, 13107) ABS_X for /dev/input/event15 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 51, 1) KEY_COMMA for /dev/input/event10 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (3, 0, 3276) ABS_X for /dev/input/event15 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (3, 0, -13107) ABS_X for /dev/input/event15 DEBUG input-remapper:reader_client.py:141 received {'type': 'status', 'message': 'ready'} DEBUG input-remapper:reader_client.py:141 received {'type': 'groups', 'message': '["{\\"paths\\": [\\"/dev/input/event1\\"], \\"names\\": [\\"Foo Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Foo Device\\"}", "{\\"paths\\": [\\"/dev/input/event11\\", \\"/dev/input/event10\\", \\"/dev/input/event13\\", \\"/dev/input/event15\\"], \\"names\\": [\\"Foo Device foo\\", \\"Foo Device\\", \\"Foo Device\\", \\"Foo Device bar\\"], \\"types\\": [\\"gamepad\\", \\"keyboard\\", \\"mouse\\"], \\"key\\": \\"Foo Device 2\\"}", "{\\"paths\\": [\\"/dev/input/event20\\"], \\"names\\": [\\"Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event30\\"], \\"names\\": [\\"gamepad\\"], \\"types\\": [\\"gamepad\\"], \\"key\\": \\"gamepad\\"}", "{\\"paths\\": [\\"/dev/input/event40\\"], \\"names\\": [\\"input-remapper Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"input-remapper Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event52\\"], \\"names\\": [\\"Qux/Device?\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Qux/Device?\\"}"]'} DEBUG input-remapper:message_broker.py:76 from reader_client.py:282: Signal=groups: GroupsData(groups={'Foo Device': [], 'Foo Device 2': [, , ], 'Bar Device': [], 'gamepad': [], 'Qux/Device?': []}) INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event15" "Foo Device bar": "cee831d56755e4bac5b0f5d2fcfd5735" INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event15" "Foo Device bar": "cee831d56755e4bac5b0f5d2fcfd5735" INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event15" "Foo Device bar": "cee831d56755e4bac5b0f5d2fcfd5735" INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" INFO input-remapper-test:cleanup.py:87 Quick cleanup... INFO input-remapper-test:cleanup.py:59 Killed pid 436377 because it didn't finish in time INFO input-remapper-test:cleanup.py:59 Killed pid 436383 because it didn't finish in time DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done DEBUG input-remapper:reader_client.py:120 Sending "terminate" to ReaderService DEBUG input-remapper:reader_client.py:185 Stopping recorder. DEBUG input-remapper:reader_client.py:120 Sending "stop-reading" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ___________ TestReaderMultiprocessing.test_should_read_absolut_axis ____________ self = def test_should_read_absolut_axis(self): l1 = Listener() l2 = Listener() self.message_broker.subscribe(MessageType.combination_recorded, l1) self.message_broker.subscribe(MessageType.recording_finished, l2) self.create_reader_service() self.reader_client.set_group(self.groups.find(key="Foo Device 2")) self.reader_client.start_recorder() # over 30% should trigger push_events( fixtures.foo_device_2_gamepad, [InputEvent.abs(ABS_X, int(MAX_ABS * 0.4))], ) time.sleep(0.1) self.reader_client._read() > self.assertEqual( [ CombinationRecorded( InputCombination( [ InputConfig( type=3, code=0, analog_threshold=1, origin_hash=fixtures.foo_device_2_gamepad.get_device_hash(), ) ] ) ) ], l1.calls, ) E AssertionError: Lists differ: [CombinationRecorded(combination=)] != [] E E First list contains 1 additional elements. E First extra element 0: E CombinationRecorded(combination=) at 0xffffff931f8d20>) E E - [CombinationRecorded(combination=) at 0xffffff931f8d20>)] E + [] tests/unit/test_reader.py:407: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:52:04.152453 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:52:04.204762 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:52:04.754531 435078 pytest DEBUG pipe.py:133: Ignoring old message [1707853917.8421235, 'terminate'] 14:52:04.784800 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.terminate: . at 0xffffff93224ea0> 14:52:04.814534 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.combination_recorded: 14:52:05.142658 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.recording_finished: 14:52:06.580629 436398 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:52:07.142086 435078 pytest DEBUG groups.py:354: Discovering device paths 14:52:07.161426 436398 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:52:07.744833 436398 pytest DEBUG reader_service.py:154: Discovering initial groups 14:52:07.775299 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:52:08.140950 435078 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:52:08.167948 436398 pytest DEBUG groups.py:354: Discovering device paths 14:52:08.745794 436398 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:52:08.754713 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:52:08.779527 436398 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:52:08.786127 435078 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:52:08.808611 435078 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:52:09.329828 436398 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:52:09.335434 435078 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:52:09.359639 436398 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:52:09.724317 435078 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:52:09.734550 436398 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:52:09.774105 435078 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:52:09.775641 436398 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:52:10.136909 436398 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:52:10.147679 435078 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:52:10.188032 436398 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:52:10.530743 435078 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:52:10.566472 436398 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:52:10.576859 435078 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:52:10.926922 436398 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:52:10.978124 436398 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:52:10.985616 435078 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:52:11.355303 435078 pytest DEBUG reader_client.py:172: Starting recorder. Test: is_running is patched to always return True 14:52:11.418326 436398 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:52:11.419396 435078 pytest DEBUG reader_client.py:120: Sending "Foo Device 2" to ReaderService 14:52:11.959427 436398 pytest DEBUG reader_service.py:161: Sending groups 14:52:12.022240 436398 pytest DEBUG reader_service.py:193: Waiting for commands 14:52:12.589391 436398 pytest DEBUG reader_service.py:195: Received command "Foo Device 2" 14:52:12.949944 435078 pytest DEBUG message_broker.py:76: from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started Test: Simulating InputEvent for (3, 0, 13107) ABS_X for /dev/input/event15 14:52:13.734410 435078 pytest DEBUG reader_client.py:141: received {'type': 'status', 'message': 'ready'} 14:52:13.773669 435078 pytest DEBUG reader_client.py:141: received {'type': 'groups', 'message': '["{\\"paths\\": [\\"/dev/input/event1\\"], \\"names\\": [\\"Foo Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Foo Device\\"}", "{\\"paths\\": [\\"/dev/input/event11\\", \\"/dev/input/event10\\", \\"/dev/input/event13\\", \\"/dev/input/event15\\"], \\"names\\": [\\"Foo Device foo\\", \\"Foo Device\\", \\"Foo Device\\", \\"Foo Device bar\\"], \\"types\\": [\\"gamepad\\", \\"keyboard\\", \\"mouse\\"], \\"key\\": \\"Foo Device 2\\"}", "{\\"paths\\": [\\"/dev/input/event20\\"], \\"names\\": [\\"Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event30\\"], \\"names\\": [\\"gamepad\\"], \\"types\\": [\\"gamepad\\"], \\"key\\": \\"gamepad\\"}", "{\\"paths\\": [\\"/dev/input/event40\\"], \\"names\\": [\\"input-remapper Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"input-remapper Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event52\\"], \\"names\\": [\\"Qux/Device?\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Qux/Device?\\"}"]'} 14:52:14.150540 435078 pytest DEBUG message_broker.py:76: from reader_client.py:282: Signal=groups: GroupsData(groups={'Foo Device': [], 'Foo Device 2': [, , ], 'Bar Device': [], 'gamepad': [], 'Qux/Device?': []}) Test: Hash for fixture "/dev/input/event15" "Foo Device bar": "cee831d56755e4bac5b0f5d2fcfd5735" Test: Quick cleanup... 14:52:16.753084 436395 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:52:21.395332 436398 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event11, fd 16 14:52:21.732326 436398 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event10, fd 18 14:52:21.755519 436398 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event13, fd 20 14:52:22.134569 436398 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event15, fd 24 Test: Killed pid 436395 because it didn't finish in time Test: Killed pid 436398 because it didn't finish in time 14:52:50.168146 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:52:51.422570 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:52:51.799594 436422 pytest DEBUG shared_dict.py:63: SharedDict process started 14:52:52.955307 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:52:53.344281 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:52:56.206108 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:52:56.785566 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:52:59.797582 436422 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:52:59.813523 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:53:00.254525 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:53:00.285840 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:53:00.759350 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:53:00.792893 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done 14:53:01.164023 435078 pytest DEBUG reader_client.py:120: Sending "terminate" to ReaderService 14:53:01.220259 435078 pytest DEBUG reader_client.py:185: Stopping recorder. 14:53:01.752602 435078 pytest DEBUG reader_client.py:120: Sending "stop-reading" to ReaderService 14:53:01.810684 435078 pytest DEBUG message_broker.py:76: from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ------------------------------ Captured log call ------------------------------- DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" DEBUG input-remapper:pipe.py:133 Ignoring old message [1707853917.8421235, 'terminate'] DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.terminate: . at 0xffffff93224ea0> DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.combination_recorded: DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.recording_finished: DEBUG input-remapper:groups.py:354 Discovering device paths DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" DEBUG input-remapper:groups.py:402 Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:391 "Foo Device qux" has no useful capabilities DEBUG input-remapper:groups.py:402 Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" DEBUG input-remapper:groups.py:402 Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" DEBUG input-remapper:groups.py:402 Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" DEBUG input-remapper:groups.py:395 "YuBiCofooYuBiKeYbar" is denylisted DEBUG input-remapper:groups.py:402 Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" INFO input-remapper:groups.py:481 Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" DEBUG input-remapper:reader_client.py:172 Starting recorder. INFO input-remapper-test:patches.py:310 is_running is patched to always return True DEBUG input-remapper:reader_client.py:120 Sending "Foo Device 2" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (3, 0, 13107) ABS_X for /dev/input/event15 DEBUG input-remapper:reader_client.py:141 received {'type': 'status', 'message': 'ready'} DEBUG input-remapper:reader_client.py:141 received {'type': 'groups', 'message': '["{\\"paths\\": [\\"/dev/input/event1\\"], \\"names\\": [\\"Foo Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Foo Device\\"}", "{\\"paths\\": [\\"/dev/input/event11\\", \\"/dev/input/event10\\", \\"/dev/input/event13\\", \\"/dev/input/event15\\"], \\"names\\": [\\"Foo Device foo\\", \\"Foo Device\\", \\"Foo Device\\", \\"Foo Device bar\\"], \\"types\\": [\\"gamepad\\", \\"keyboard\\", \\"mouse\\"], \\"key\\": \\"Foo Device 2\\"}", "{\\"paths\\": [\\"/dev/input/event20\\"], \\"names\\": [\\"Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event30\\"], \\"names\\": [\\"gamepad\\"], \\"types\\": [\\"gamepad\\"], \\"key\\": \\"gamepad\\"}", "{\\"paths\\": [\\"/dev/input/event40\\"], \\"names\\": [\\"input-remapper Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"input-remapper Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event52\\"], \\"names\\": [\\"Qux/Device?\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Qux/Device?\\"}"]'} DEBUG input-remapper:message_broker.py:76 from reader_client.py:282: Signal=groups: GroupsData(groups={'Foo Device': [], 'Foo Device 2': [, , ], 'Bar Device': [], 'gamepad': [], 'Qux/Device?': []}) INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event15" "Foo Device bar": "cee831d56755e4bac5b0f5d2fcfd5735" INFO input-remapper-test:cleanup.py:87 Quick cleanup... INFO input-remapper-test:cleanup.py:59 Killed pid 436395 because it didn't finish in time INFO input-remapper-test:cleanup.py:59 Killed pid 436398 because it didn't finish in time DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done DEBUG input-remapper:reader_client.py:120 Sending "terminate" to ReaderService DEBUG input-remapper:reader_client.py:185 Stopping recorder. DEBUG input-remapper:reader_client.py:120 Sending "stop-reading" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished _________ TestReaderMultiprocessing.test_should_release_relative_axis __________ self = def test_should_release_relative_axis(self): # the timeout is set to 0.3s l1 = Listener() l2 = Listener() self.message_broker.subscribe(MessageType.combination_recorded, l1) self.message_broker.subscribe(MessageType.recording_finished, l2) self.create_reader_service() self.reader_client.set_group(self.groups.find(key="Foo Device 2")) self.reader_client.start_recorder() push_events(fixtures.foo_device_2_mouse, [InputEvent.rel(REL_X, -5)]) time.sleep(0.1) self.reader_client._read() > self.assertEqual( [ CombinationRecorded( InputCombination( [ InputConfig( type=2, code=0, analog_threshold=-1, origin_hash=fixtures.foo_device_2_mouse.get_device_hash(), ) ] ) ) ], l1.calls, ) E AssertionError: Lists differ: [CombinationRecorded(combination=)] != [] E E First list contains 1 additional elements. E First extra element 0: E CombinationRecorded(combination=) at 0xffffff934bec10>) E E - [CombinationRecorded(combination=) at 0xffffff934bec10>)] E + [] tests/unit/test_reader.py:273: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:53:26.605726 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:53:26.634581 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:53:27.166964 435078 pytest DEBUG pipe.py:133: Ignoring old message [1707853981.2098768, 'terminate'] 14:53:27.215171 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.terminate: . at 0xffffff936c94e0> 14:53:27.759933 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.combination_recorded: 14:53:27.785309 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.recording_finished: 14:53:29.968054 436446 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:53:29.970561 435078 pytest DEBUG groups.py:354: Discovering device paths 14:53:30.755745 436446 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:53:30.778104 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:53:31.177677 435078 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:53:31.770807 436446 pytest DEBUG reader_service.py:154: Discovering initial groups 14:53:31.785652 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:53:32.154924 435078 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:53:32.734482 436446 pytest DEBUG groups.py:354: Discovering device paths 14:53:32.736187 435078 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:53:32.781374 435078 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:53:32.796503 436446 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:53:33.359835 436446 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:53:33.371485 435078 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:53:33.409135 435078 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:53:33.753238 436446 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:53:33.788584 435078 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:53:33.789429 436446 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:53:33.822355 436446 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:53:34.167643 435078 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:53:34.202524 436446 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:53:34.227204 435078 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:53:34.749933 436446 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:53:35.123083 436446 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:53:35.174023 435078 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:53:35.530300 435078 pytest DEBUG reader_client.py:172: Starting recorder. 14:53:35.538602 436446 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" Test: is_running is patched to always return True 14:53:35.560595 435078 pytest DEBUG reader_client.py:120: Sending "Foo Device 2" to ReaderService 14:53:35.575968 436446 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:53:35.955923 435078 pytest DEBUG message_broker.py:76: from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started 14:53:36.329101 436446 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" Test: Simulating InputEvent for (2, 0, -5) REL_X for /dev/input/event11 14:53:36.802798 435078 pytest DEBUG reader_client.py:141: received {'type': 'status', 'message': 'ready'} Test: Hash for fixture "/dev/input/event11" "Foo Device foo": "77605ea88cd2159e71044704ef068863" 14:53:36.828359 436446 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:53:37.139981 436446 pytest DEBUG reader_service.py:161: Sending groups 14:53:37.584615 436446 pytest DEBUG reader_service.py:193: Waiting for commands Test: Quick cleanup... 14:53:38.602076 436446 pytest DEBUG reader_service.py:195: Received command "Foo Device 2" 14:53:39.123671 436422 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:53:46.355348 436446 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event11, fd 16 14:53:46.415995 436446 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event10, fd 18 14:53:46.949830 436446 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event13, fd 20 14:53:47.350123 436446 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event15, fd 24 Test: Killed pid 436422 because it didn't finish in time Test: Killed pid 436446 because it didn't finish in time 14:54:19.229310 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:54:20.819770 436457 pytest DEBUG shared_dict.py:63: SharedDict process started 14:54:21.161065 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:54:23.145166 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:54:23.213698 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:54:27.564535 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:54:27.975815 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:54:31.598048 436457 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:54:31.611765 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:54:31.650710 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:54:32.003767 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:54:32.327890 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:54:32.358288 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done 14:54:32.738696 435078 pytest DEBUG reader_client.py:120: Sending "terminate" to ReaderService 14:54:32.773213 435078 pytest DEBUG reader_client.py:185: Stopping recorder. 14:54:32.797238 435078 pytest DEBUG reader_client.py:120: Sending "stop-reading" to ReaderService 14:54:33.425231 435078 pytest DEBUG message_broker.py:76: from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ------------------------------ Captured log call ------------------------------- DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" DEBUG input-remapper:pipe.py:133 Ignoring old message [1707853981.2098768, 'terminate'] DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.terminate: . at 0xffffff936c94e0> DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.combination_recorded: DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.recording_finished: DEBUG input-remapper:groups.py:354 Discovering device paths DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" DEBUG input-remapper:groups.py:402 Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:391 "Foo Device qux" has no useful capabilities DEBUG input-remapper:groups.py:402 Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" DEBUG input-remapper:groups.py:402 Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" DEBUG input-remapper:groups.py:402 Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" DEBUG input-remapper:groups.py:395 "YuBiCofooYuBiKeYbar" is denylisted DEBUG input-remapper:groups.py:402 Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" INFO input-remapper:groups.py:481 Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" DEBUG input-remapper:reader_client.py:172 Starting recorder. INFO input-remapper-test:patches.py:310 is_running is patched to always return True DEBUG input-remapper:reader_client.py:120 Sending "Foo Device 2" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (2, 0, -5) REL_X for /dev/input/event11 DEBUG input-remapper:reader_client.py:141 received {'type': 'status', 'message': 'ready'} INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event11" "Foo Device foo": "77605ea88cd2159e71044704ef068863" INFO input-remapper-test:cleanup.py:87 Quick cleanup... INFO input-remapper-test:cleanup.py:59 Killed pid 436422 because it didn't finish in time INFO input-remapper-test:cleanup.py:59 Killed pid 436446 because it didn't finish in time DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done DEBUG input-remapper:reader_client.py:120 Sending "terminate" to ReaderService DEBUG input-remapper:reader_client.py:185 Stopping recorder. DEBUG input-remapper:reader_client.py:120 Sending "stop-reading" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished _______ TestReaderMultiprocessing.test_should_trigger_wheel_at_low_speed _______ self = def test_should_trigger_wheel_at_low_speed(self): l1 = Listener() self.message_broker.subscribe(MessageType.combination_recorded, l1) self.create_reader_service() self.reader_client.set_group(self.groups.find(key="Foo Device 2")) self.reader_client.start_recorder() push_events( fixtures.foo_device_2_mouse, [InputEvent.rel(REL_WHEEL, -1), InputEvent.rel(REL_HWHEEL, 1)], ) time.sleep(0.1) self.reader_client._read() > self.assertEqual( [ CombinationRecorded( InputCombination( [ InputConfig( type=2, code=8, analog_threshold=-1, origin_hash=fixtures.foo_device_2_mouse.get_device_hash(), ) ] ) ), CombinationRecorded( InputCombination( [ InputConfig( type=2, code=8, analog_threshold=-1, origin_hash=fixtures.foo_device_2_mouse.get_device_hash(), ), InputConfig( type=2, code=6, analog_threshold=1, origin_hash=fixtures.foo_device_2_mouse.get_device_hash(), ), ] ) ), ], l1.calls, ) E AssertionError: Lists differ: [CombinationRecorded(combination=)] != [] E E First list contains 2 additional elements. E First extra element 0: E CombinationRecorded(combination=) at 0xffffff931694f0>) E E + [] E - [CombinationRecorded(combination=) at 0xffffff931694f0>), E - CombinationRecorded(combination=, ) at 0xffffff931fa3a0>)] tests/unit/test_reader.py:322: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:54:51.024659 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:54:51.558634 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:54:51.587968 435078 pytest DEBUG pipe.py:133: Ignoring old message [1707854072.7644277, 'terminate'] 14:54:51.610451 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.terminate: . at 0xffffff934a4860> 14:54:51.960701 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.combination_recorded: 14:54:53.203098 436461 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:54:53.261658 435078 pytest DEBUG groups.py:354: Discovering device paths 14:54:53.756876 436461 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:54:53.809271 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:54:54.530069 435078 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:54:54.565990 436461 pytest DEBUG reader_service.py:154: Discovering initial groups 14:54:54.588977 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:54:55.132764 435078 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:54:55.168996 436461 pytest DEBUG groups.py:354: Discovering device paths 14:54:55.958739 435078 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:54:55.998836 436461 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:54:56.003078 435078 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:54:56.030123 436461 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:54:56.641179 435078 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:54:56.670896 436461 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:54:56.702614 436461 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:54:56.702603 435078 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:54:57.128680 436461 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:54:57.155239 435078 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:54:57.179998 436461 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:54:57.194897 435078 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:54:57.741051 436461 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:54:57.769529 436461 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:54:57.788448 435078 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:54:58.179304 436461 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:54:58.730597 436461 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:54:58.776020 435078 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:54:59.140347 436461 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:54:59.167939 435078 pytest DEBUG reader_client.py:172: Starting recorder. Test: is_running is patched to always return True 14:54:59.414204 435078 pytest DEBUG reader_client.py:120: Sending "Foo Device 2" to ReaderService 14:54:59.945074 436461 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:55:00.006594 436461 pytest DEBUG reader_service.py:161: Sending groups 14:55:00.346785 435078 pytest DEBUG message_broker.py:76: from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started Test: Simulating InputEvent for (2, 8, -1) REL_WHEEL for /dev/input/event11 14:55:00.614488 436461 pytest DEBUG reader_service.py:193: Waiting for commands Test: Simulating InputEvent for (2, 6, 1) REL_HWHEEL for /dev/input/event11 14:55:00.950696 435078 pytest DEBUG reader_client.py:141: received {'type': 'status', 'message': 'ready'} 14:55:01.352710 435078 pytest DEBUG reader_client.py:141: received {'type': 'groups', 'message': '["{\\"paths\\": [\\"/dev/input/event1\\"], \\"names\\": [\\"Foo Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Foo Device\\"}", "{\\"paths\\": [\\"/dev/input/event11\\", \\"/dev/input/event10\\", \\"/dev/input/event13\\", \\"/dev/input/event15\\"], \\"names\\": [\\"Foo Device foo\\", \\"Foo Device\\", \\"Foo Device\\", \\"Foo Device bar\\"], \\"types\\": [\\"gamepad\\", \\"keyboard\\", \\"mouse\\"], \\"key\\": \\"Foo Device 2\\"}", "{\\"paths\\": [\\"/dev/input/event20\\"], \\"names\\": [\\"Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event30\\"], \\"names\\": [\\"gamepad\\"], \\"types\\": [\\"gamepad\\"], \\"key\\": \\"gamepad\\"}", "{\\"paths\\": [\\"/dev/input/event40\\"], \\"names\\": [\\"input-remapper Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"input-remapper Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event52\\"], \\"names\\": [\\"Qux/Device?\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Qux/Device?\\"}"]'} 14:55:01.366335 436461 pytest DEBUG reader_service.py:195: Received command "Foo Device 2" 14:55:01.957747 435078 pytest DEBUG message_broker.py:76: from reader_client.py:282: Signal=groups: GroupsData(groups={'Foo Device': [], 'Foo Device 2': [, , ], 'Bar Device': [], 'gamepad': [], 'Qux/Device?': []}) Test: Hash for fixture "/dev/input/event11" "Foo Device foo": "77605ea88cd2159e71044704ef068863" Test: Hash for fixture "/dev/input/event11" "Foo Device foo": "77605ea88cd2159e71044704ef068863" Test: Hash for fixture "/dev/input/event11" "Foo Device foo": "77605ea88cd2159e71044704ef068863" Test: Quick cleanup... 14:55:04.823565 436457 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:55:09.229101 436461 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event11, fd 16 14:55:09.605504 436461 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event10, fd 18 14:55:09.971543 436461 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event13, fd 20 14:55:10.013680 436461 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event15, fd 24 Test: Killed pid 436457 because it didn't finish in time Test: Killed pid 436461 because it didn't finish in time 14:55:42.355244 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:55:43.556118 436467 pytest DEBUG shared_dict.py:63: SharedDict process started 14:55:43.555639 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:55:44.396203 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:55:44.769045 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:55:49.141227 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:55:49.188832 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:55:53.537930 436467 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:55:53.561218 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:55:53.968553 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:55:54.344341 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:55:54.380785 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:55:54.406776 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done 14:55:54.766619 435078 pytest DEBUG reader_client.py:120: Sending "terminate" to ReaderService 14:55:55.161948 435078 pytest DEBUG reader_client.py:185: Stopping recorder. 14:55:55.191376 435078 pytest DEBUG reader_client.py:120: Sending "stop-reading" to ReaderService 14:55:55.570353 435078 pytest DEBUG message_broker.py:76: from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ------------------------------ Captured log call ------------------------------- DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" DEBUG input-remapper:pipe.py:133 Ignoring old message [1707854072.7644277, 'terminate'] DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.terminate: . at 0xffffff934a4860> DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.combination_recorded: DEBUG input-remapper:groups.py:354 Discovering device paths DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" DEBUG input-remapper:groups.py:402 Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:391 "Foo Device qux" has no useful capabilities DEBUG input-remapper:groups.py:402 Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" DEBUG input-remapper:groups.py:402 Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" DEBUG input-remapper:groups.py:402 Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" DEBUG input-remapper:groups.py:395 "YuBiCofooYuBiKeYbar" is denylisted DEBUG input-remapper:groups.py:402 Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" INFO input-remapper:groups.py:481 Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" DEBUG input-remapper:reader_client.py:172 Starting recorder. INFO input-remapper-test:patches.py:310 is_running is patched to always return True DEBUG input-remapper:reader_client.py:120 Sending "Foo Device 2" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (2, 8, -1) REL_WHEEL for /dev/input/event11 INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (2, 6, 1) REL_HWHEEL for /dev/input/event11 DEBUG input-remapper:reader_client.py:141 received {'type': 'status', 'message': 'ready'} DEBUG input-remapper:reader_client.py:141 received {'type': 'groups', 'message': '["{\\"paths\\": [\\"/dev/input/event1\\"], \\"names\\": [\\"Foo Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Foo Device\\"}", "{\\"paths\\": [\\"/dev/input/event11\\", \\"/dev/input/event10\\", \\"/dev/input/event13\\", \\"/dev/input/event15\\"], \\"names\\": [\\"Foo Device foo\\", \\"Foo Device\\", \\"Foo Device\\", \\"Foo Device bar\\"], \\"types\\": [\\"gamepad\\", \\"keyboard\\", \\"mouse\\"], \\"key\\": \\"Foo Device 2\\"}", "{\\"paths\\": [\\"/dev/input/event20\\"], \\"names\\": [\\"Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event30\\"], \\"names\\": [\\"gamepad\\"], \\"types\\": [\\"gamepad\\"], \\"key\\": \\"gamepad\\"}", "{\\"paths\\": [\\"/dev/input/event40\\"], \\"names\\": [\\"input-remapper Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"input-remapper Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event52\\"], \\"names\\": [\\"Qux/Device?\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Qux/Device?\\"}"]'} DEBUG input-remapper:message_broker.py:76 from reader_client.py:282: Signal=groups: GroupsData(groups={'Foo Device': [], 'Foo Device 2': [, , ], 'Bar Device': [], 'gamepad': [], 'Qux/Device?': []}) INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event11" "Foo Device foo": "77605ea88cd2159e71044704ef068863" INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event11" "Foo Device foo": "77605ea88cd2159e71044704ef068863" INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event11" "Foo Device foo": "77605ea88cd2159e71044704ef068863" INFO input-remapper-test:cleanup.py:87 Quick cleanup... INFO input-remapper-test:cleanup.py:59 Killed pid 436457 because it didn't finish in time INFO input-remapper-test:cleanup.py:59 Killed pid 436461 because it didn't finish in time DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done DEBUG input-remapper:reader_client.py:120 Sending "terminate" to ReaderService DEBUG input-remapper:reader_client.py:185 Stopping recorder. DEBUG input-remapper:reader_client.py:120 Sending "stop-reading" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished _____ TestReaderMultiprocessing.test_wont_emit_the_same_combination_twice ______ self = def test_wont_emit_the_same_combination_twice(self): l1 = Listener() self.message_broker.subscribe(MessageType.combination_recorded, l1) self.create_reader_service() self.reader_client.set_group(self.groups.find(key="Foo Device 2")) self.reader_client.start_recorder() push_events(fixtures.foo_device_2_keyboard, [InputEvent.key(KEY_A, 1)]) time.sleep(0.1) self.reader_client._read() # the duplicate event should be ignored push_events(fixtures.foo_device_2_keyboard, [InputEvent.key(KEY_A, 1)]) time.sleep(0.1) self.reader_client._read() > self.assertEqual( [ CombinationRecorded( InputCombination( [ InputConfig( type=1, code=30, analog_threshold=1, origin_hash=fixtures.foo_device_2_keyboard.get_device_hash(), ) ] ) ) ], l1.calls, ) E AssertionError: Lists differ: [CombinationRecorded(combination=)] != [] E E First list contains 1 additional elements. E First extra element 0: E CombinationRecorded(combination=) at 0xffffff934eebc0>) E E - [CombinationRecorded(combination=) at 0xffffff934eebc0>)] E + [] tests/unit/test_reader.py:373: AssertionError ----------------------------- Captured stderr call ----------------------------- 14:57:05.381273 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:57:05.956641 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:57:06.002532 435078 pytest DEBUG pipe.py:133: Ignoring old message [1707854221.2227929, 'terminate'] 14:57:06.374990 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.terminate: . at 0xffffff93226200> 14:57:06.766977 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.combination_recorded: 14:57:07.982937 436478 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 14:57:08.587177 436478 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 14:57:08.995922 435078 pytest DEBUG groups.py:354: Discovering device paths 14:57:09.354274 436478 pytest DEBUG reader_service.py:154: Discovering initial groups 14:57:09.423822 436478 pytest DEBUG groups.py:354: Discovering device paths 14:57:10.138557 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:57:10.154070 436478 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 14:57:10.186406 435078 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:57:10.204882 436478 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 14:57:10.236423 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:57:10.771272 435078 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:57:10.778391 436478 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 14:57:10.798319 435078 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:57:10.811272 436478 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 14:57:10.827255 435078 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:57:11.133268 436478 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 14:57:11.175485 436478 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 14:57:11.179057 435078 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:57:11.383374 435078 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:57:11.396451 436478 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 14:57:11.765630 435078 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:57:11.778385 436478 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 14:57:12.145568 435078 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:57:12.166096 436478 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 14:57:12.196658 435078 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:57:12.374424 436478 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 14:57:12.780087 436478 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 14:57:13.179326 435078 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:57:13.368495 436478 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 14:57:13.380779 435078 pytest DEBUG reader_client.py:172: Starting recorder. 14:57:13.733307 436478 pytest DEBUG reader_service.py:161: Sending groups Test: is_running is patched to always return True 14:57:13.764638 435078 pytest DEBUG reader_client.py:120: Sending "Foo Device 2" to ReaderService 14:57:14.128780 436478 pytest DEBUG reader_service.py:193: Waiting for commands 14:57:14.160071 435078 pytest DEBUG message_broker.py:76: from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started Test: Simulating InputEvent for (1, 30, 1) KEY_A for /dev/input/event10 14:57:14.769985 436478 pytest DEBUG reader_service.py:195: Received command "Foo Device 2" 14:57:15.336292 435078 pytest DEBUG reader_client.py:141: received {'type': 'status', 'message': 'ready'} 14:57:15.361464 435078 pytest DEBUG reader_client.py:141: received {'type': 'groups', 'message': '["{\\"paths\\": [\\"/dev/input/event1\\"], \\"names\\": [\\"Foo Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Foo Device\\"}", "{\\"paths\\": [\\"/dev/input/event11\\", \\"/dev/input/event10\\", \\"/dev/input/event13\\", \\"/dev/input/event15\\"], \\"names\\": [\\"Foo Device foo\\", \\"Foo Device\\", \\"Foo Device\\", \\"Foo Device bar\\"], \\"types\\": [\\"gamepad\\", \\"keyboard\\", \\"mouse\\"], \\"key\\": \\"Foo Device 2\\"}", "{\\"paths\\": [\\"/dev/input/event20\\"], \\"names\\": [\\"Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event30\\"], \\"names\\": [\\"gamepad\\"], \\"types\\": [\\"gamepad\\"], \\"key\\": \\"gamepad\\"}", "{\\"paths\\": [\\"/dev/input/event40\\"], \\"names\\": [\\"input-remapper Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"input-remapper Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event52\\"], \\"names\\": [\\"Qux/Device?\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Qux/Device?\\"}"]'} 14:57:15.410434 435078 pytest DEBUG message_broker.py:76: from reader_client.py:282: Signal=groups: GroupsData(groups={'Foo Device': [], 'Foo Device 2': [, , ], 'Bar Device': [], 'gamepad': [], 'Qux/Device?': []}) Test: Simulating InputEvent for (1, 30, 1) KEY_A for /dev/input/event10 Test: Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" Test: Quick cleanup... 14:57:17.410766 436476 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 14:57:20.335099 436478 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event11, fd 16 14:57:20.381408 436478 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event10, fd 18 14:57:20.408988 436478 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event13, fd 20 14:57:21.145577 436478 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event15, fd 24 Test: Killed pid 436476 because it didn't finish in time Test: Killed pid 436478 because it didn't finish in time 14:57:47.975359 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 14:57:49.171039 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 14:57:49.183806 436482 pytest DEBUG shared_dict.py:63: SharedDict process started 14:57:50.208599 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 14:57:50.749482 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 14:57:52.746155 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:57:52.788900 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 14:57:55.791568 436482 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 14:57:55.809871 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 14:57:55.836317 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 14:57:56.207898 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 14:57:56.233794 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 14:57:56.747996 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done 14:57:56.797571 435078 pytest DEBUG reader_client.py:120: Sending "terminate" to ReaderService 14:57:56.830469 435078 pytest DEBUG reader_client.py:185: Stopping recorder. 14:57:57.199891 435078 pytest DEBUG reader_client.py:120: Sending "stop-reading" to ReaderService 14:57:57.756783 435078 pytest DEBUG message_broker.py:76: from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished ------------------------------ Captured log call ------------------------------- DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" DEBUG input-remapper:pipe.py:133 Ignoring old message [1707854221.2227929, 'terminate'] DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.terminate: . at 0xffffff93226200> DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.combination_recorded: DEBUG input-remapper:groups.py:354 Discovering device paths DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" DEBUG input-remapper:groups.py:402 Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:391 "Foo Device qux" has no useful capabilities DEBUG input-remapper:groups.py:402 Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" DEBUG input-remapper:groups.py:402 Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" DEBUG input-remapper:groups.py:402 Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" DEBUG input-remapper:groups.py:395 "YuBiCofooYuBiKeYbar" is denylisted DEBUG input-remapper:groups.py:402 Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" INFO input-remapper:groups.py:481 Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" DEBUG input-remapper:reader_client.py:172 Starting recorder. INFO input-remapper-test:patches.py:310 is_running is patched to always return True DEBUG input-remapper:reader_client.py:120 Sending "Foo Device 2" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 30, 1) KEY_A for /dev/input/event10 DEBUG input-remapper:reader_client.py:141 received {'type': 'status', 'message': 'ready'} DEBUG input-remapper:reader_client.py:141 received {'type': 'groups', 'message': '["{\\"paths\\": [\\"/dev/input/event1\\"], \\"names\\": [\\"Foo Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Foo Device\\"}", "{\\"paths\\": [\\"/dev/input/event11\\", \\"/dev/input/event10\\", \\"/dev/input/event13\\", \\"/dev/input/event15\\"], \\"names\\": [\\"Foo Device foo\\", \\"Foo Device\\", \\"Foo Device\\", \\"Foo Device bar\\"], \\"types\\": [\\"gamepad\\", \\"keyboard\\", \\"mouse\\"], \\"key\\": \\"Foo Device 2\\"}", "{\\"paths\\": [\\"/dev/input/event20\\"], \\"names\\": [\\"Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event30\\"], \\"names\\": [\\"gamepad\\"], \\"types\\": [\\"gamepad\\"], \\"key\\": \\"gamepad\\"}", "{\\"paths\\": [\\"/dev/input/event40\\"], \\"names\\": [\\"input-remapper Bar Device\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"input-remapper Bar Device\\"}", "{\\"paths\\": [\\"/dev/input/event52\\"], \\"names\\": [\\"Qux/Device?\\"], \\"types\\": [\\"keyboard\\"], \\"key\\": \\"Qux/Device?\\"}"]'} DEBUG input-remapper:message_broker.py:76 from reader_client.py:282: Signal=groups: GroupsData(groups={'Foo Device': [], 'Foo Device 2': [, , ], 'Bar Device': [], 'gamepad': [], 'Qux/Device?': []}) INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 30, 1) KEY_A for /dev/input/event10 INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event10" "Foo Device": "698702013ccc49179d9669854f6c2b69" INFO input-remapper-test:cleanup.py:87 Quick cleanup... INFO input-remapper-test:cleanup.py:59 Killed pid 436476 because it didn't finish in time INFO input-remapper-test:cleanup.py:59 Killed pid 436478 because it didn't finish in time DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done DEBUG input-remapper:reader_client.py:120 Sending "terminate" to ReaderService DEBUG input-remapper:reader_client.py:185 Stopping recorder. DEBUG input-remapper:reader_client.py:120 Sending "stop-reading" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:196: Signal=recording_finished: Signal: MessageType.recording_finished __________________________ TestTest.test_push_events ___________________________ self = def test_push_events(self): """Test that push_event works properly between reader service and client. Using push_events after the reader-service is already started should work, as well as using push_event twice """ reader_client = ReaderClient(MessageBroker(), groups) def create_reader_service(): # this will cause pending events to be copied over to the reader-service # process def start_reader_service(): # there is no point in using the global groups object # because the reader-service runs in a different process reader_service = ReaderService(_Groups()) loop = asyncio.new_event_loop() loop.run_until_complete(reader_service.run()) self.reader_service = multiprocessing.Process(target=start_reader_service) self.reader_service.start() time.sleep(0.1) def wait_for_results(): # wait for the reader-service to send stuff for _ in range(10): time.sleep(EVENT_READ_TIMEOUT) if reader_client._results_pipe.poll(): break create_reader_service() reader_client.set_group(groups.find(key="Foo Device 2")) reader_client.start_recorder() time.sleep(START_READING_DELAY) event = InputEvent.key(102, 1) push_events(fixtures.foo_device_2_keyboard, [event]) wait_for_results() self.assertTrue(reader_client._results_pipe.poll()) reader_client._read() self.assertFalse(reader_client._results_pipe.poll()) # can push more events to the reader-service that is inside a separate # process, which end up being sent to the reader event = InputEvent.key(102, 0) logger.info("push_events") push_events(fixtures.foo_device_2_keyboard, [event]) wait_for_results() logger.info("assert") > self.assertTrue(reader_client._results_pipe.poll()) E AssertionError: False is not true tests/unit/test_test.py:133: AssertionError ----------------------------- Captured stderr call ----------------------------- 15:03:06.395738 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" 15:03:06.442272 435078 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 15:03:06.960647 435078 pytest DEBUG pipe.py:133: Ignoring old message [1707854379.784231, 'terminate'] 15:03:06.998765 435078 pytest DEBUG message_broker.py:97: adding new Listener for MessageType.terminate: . at 0xffffff934a6160> 15:03:08.200336 435078 pytest DEBUG reader_client.py:172: Starting recorder. 15:03:08.200721 436565 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" Test: is_running is patched to always return True 15:03:08.787309 436565 pytest DEBUG pipe.py:87: Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" 15:03:08.790076 435078 pytest DEBUG reader_client.py:120: Sending "Foo Device 2" to ReaderService 15:03:09.333990 436565 pytest DEBUG pipe.py:102: Cleared leftover message "Foo Device 2" 15:03:09.370094 435078 pytest DEBUG message_broker.py:76: from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started 15:03:09.433574 436565 pytest DEBUG reader_service.py:154: Discovering initial groups Test: Simulating InputEvent for (1, 102, 1) KEY_HOME for /dev/input/event10 15:03:09.817652 435078 pytest DEBUG reader_client.py:141: received {'type': 'status', 'message': 'ready'} 15:03:09.835253 436565 pytest DEBUG groups.py:354: Discovering device paths Test: push_events Test: Simulating InputEvent for (1, 102, 0) KEY_HOME for /dev/input/event10 15:03:10.455196 436565 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" Test: assert 15:03:11.006309 436565 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" Test: Quick cleanup... 15:03:11.976783 436565 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 15:03:12.036204 436565 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 15:03:12.571106 436565 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 15:03:12.578369 436564 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 15:03:12.612010 436565 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 15:03:13.154637 436565 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 15:03:13.190946 436565 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 15:03:13.572942 436565 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 15:03:13.953331 436565 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 15:03:14.011510 436565 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 15:03:14.824141 436565 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" 15:03:15.155521 436565 pytest DEBUG reader_service.py:161: Sending groups 15:03:15.587923 436565 pytest DEBUG reader_service.py:193: Waiting for commands Test: Killed pid 436564 because it didn't finish in time Test: Killed pid 436565 because it didn't finish in time 15:03:45.380738 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 15:03:46.825129 436568 pytest DEBUG shared_dict.py:63: SharedDict process started 15:03:47.255143 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 15:03:48.196218 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 15:03:48.804898 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 15:03:52.376932 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 15:03:52.775134 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 15:03:56.590170 436568 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 15:03:56.946586 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 15:03:56.980847 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 15:03:57.365741 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 15:03:57.756373 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 15:03:57.791321 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" Test: Quick cleanup done ------------------------------ Captured log call ------------------------------- DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-results" DEBUG input-remapper:pipe.py:87 Using existing pipe for "/tmp/input-remapper-mockbuild/reader-commands" DEBUG input-remapper:pipe.py:133 Ignoring old message [1707854379.784231, 'terminate'] DEBUG input-remapper:message_broker.py:97 adding new Listener for MessageType.terminate: . at 0xffffff934a6160> DEBUG input-remapper:reader_client.py:172 Starting recorder. INFO input-remapper-test:patches.py:310 is_running is patched to always return True DEBUG input-remapper:reader_client.py:120 Sending "Foo Device 2" to ReaderService DEBUG input-remapper:message_broker.py:76 from reader_client.py:178: Signal=recording_started: Signal: MessageType.recording_started INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 102, 1) KEY_HOME for /dev/input/event10 DEBUG input-remapper:reader_client.py:141 received {'type': 'status', 'message': 'ready'} INFO input-remapper-test:test_test.py:129 push_events INFO input-remapper-test:pipes.py:81 Simulating InputEvent for (1, 102, 0) KEY_HOME for /dev/input/event10 INFO input-remapper-test:test_test.py:132 assert INFO input-remapper-test:cleanup.py:87 Quick cleanup... INFO input-remapper-test:cleanup.py:59 Killed pid 436564 because it didn't finish in time INFO input-remapper-test:cleanup.py:59 Killed pid 436565 because it didn't finish in time DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" INFO input-remapper-test:cleanup.py:160 Quick cleanup done _________________________ TestRelToBtn.test_rel_to_btn _________________________ self = async def test_rel_to_btn(self): """Rel axis mapped to buttons are automatically released if no new rel event arrives.""" # map those two to stuff w_up = (EV_REL, REL_WHEEL, -1) hw_right = (EV_REL, REL_HWHEEL, 1) # should be forwarded and present in the capabilities hw_left = (EV_REL, REL_HWHEEL, -1) system_mapping.clear() code_b = 91 code_c = 92 system_mapping._set("b", code_b) system_mapping._set("c", code_c) # set a high release timeout to make sure the tests pass release_timeout = 0.2 mapping_1 = Mapping.from_combination( InputCombination(InputCombination.from_tuples(hw_right)), "keyboard", "k(b)" ) mapping_2 = Mapping.from_combination( InputCombination(InputCombination.from_tuples(w_up)), "keyboard", "c" ) mapping_1.release_timeout = release_timeout mapping_2.release_timeout = release_timeout preset = Preset() preset.add(mapping_1) preset.add(mapping_2) event_reader = self.create_event_reader(preset, fixtures.foo_device_2_mouse) await self.send_events( [InputEvent.from_tuple(hw_right), InputEvent.from_tuple(w_up)] * 5, event_reader, ) # wait less than the release timeout and send more events await asyncio.sleep(release_timeout / 5) await self.send_events( [InputEvent.from_tuple(hw_right), InputEvent.from_tuple(w_up)] * 5 + [InputEvent.from_tuple(hw_left)] * 3, # one event will release hw_right, the others are forwarded event_reader, ) # wait more than the release_timeout to make sure all handlers finish await asyncio.sleep(release_timeout * 1.2) keyboard_history = global_uinputs.get_uinput("keyboard").write_history forwarded_history = self.forward_uinput.write_history > self.assertEqual(keyboard_history.count((EV_KEY, code_b, 1)), 1) E AssertionError: 2 != 1 tests/unit/test_event_pipeline/test_event_pipeline.py:1368: AssertionError ----------------------------- Captured stderr call ----------------------------- 15:19:09.684916 435078 pytest WARNING input_config.py:272: No origin_hash set for {'type': 2, 'code': 6, 'analog_threshold': 1} 15:19:10.607204 435078 pytest DEBUG parse.py:456: parsing macro k(b) 15:19:10.679989 435078 pytest WARNING input_config.py:272: No origin_hash set for {'type': 2, 'code': 8, 'analog_threshold': -1} 15:19:11.619793 435078 pytest DEBUG parse.py:456: parsing macro k(b) Test: Hash for fixture "/dev/input/event11" "Foo Device foo": "77605ea88cd2159e71044704ef068863" 15:19:12.222832 435078 pytest WARNING context.py:90: Not source_devices set 15:19:12.254422 435078 pytest DEBUG parse.py:456: parsing macro k(b) 15:19:12.755985 435078 pytest DEBUG parse.py:244: calls k with b 15:19:12.779202 435078 pytest DEBUG parse.py:244: string b 15:19:12.799233 435078 pytest DEBUG parse.py:244: add call to k with ['b'], {} 15:19:12.849327 435078 pytest WARNING input_config.py:272: No origin_hash set for {'type': 2, 'code': 6, 'analog_threshold': 1} 15:19:13.424026 435078 pytest DEBUG combination_handler.py:56: {'input_combination': ) at 0xffffff93514af0>, 'target_uinput': 'keyboard'} 15:19:13.947257 435078 pytest WARNING input_config.py:272: No origin_hash set for {'type': 2, 'code': 8, 'analog_threshold': -1} 15:19:13.982741 435078 pytest DEBUG combination_handler.py:56: {'input_combination': ) at 0xffffff93516c10>, 'target_uinput': 'keyboard'} 15:19:14.450799 435078 pytest DEBUG mapping_parser.py:133: event-pipeline with entry point: REL_HWHEEL (2, 6, None) 15:19:14.496069 435078 pytest DEBUG logger.py:77: 15:19:14.520474 435078 pytest DEBUG logger.py:77: ) at 0xffffff93514a50>" ((2, 6, None),) at 0xffffff936bb020> 15:19:14.541924 435078 pytest DEBUG logger.py:77: 15:19:15.158473 435078 pytest DEBUG logger.py:77: 'maps to on keyboard' 15:19:15.179581 435078 pytest DEBUG mapping_parser.py:133: event-pipeline with entry point: REL_WHEEL (2, 8, None) 15:19:15.205025 435078 pytest DEBUG logger.py:77: 15:19:15.224001 435078 pytest DEBUG logger.py:77: ) at 0xffffff935154a0>" ((2, 8, None),) at 0xffffff95fb49b0> 15:19:15.244643 435078 pytest DEBUG logger.py:77: 15:19:15.263860 435078 pytest DEBUG logger.py:77: 'maps to: KEY_HENKAN (1, 92) on keyboard' 15:19:15.796519 435078 pytest DEBUG context.py:110: Adding NotifyCallback for (2, 6, None) 15:19:15.823595 435078 pytest DEBUG context.py:110: Adding NotifyCallback for (2, 8, None) Test: sending into event_pipeline: InputEvent for (2, 6, 1) REL_HWHEEL 15:19:16.289369 435078 pytest DEBUG combination_handler.py:138: Sending Combination (InputConfig REL_HWHEEL) to sub-handler Test: sending into event_pipeline: InputEvent for (2, 8, -1) REL_WHEEL 15:19:16.732113 435078 pytest DEBUG combination_handler.py:138: Sending Combination (InputConfig REL_WHEEL) to sub-handler 15:19:17.178202 435078 pytest DEBUG logger.py:105: Writing (1, 92, 1) to "input-remapper keyboard" Test: (1, 92, 1) KEY_HENKAN written to "input-remapper keyboard" Test: sending into event_pipeline: InputEvent for (2, 6, 1) REL_HWHEEL Test: sending into event_pipeline: InputEvent for (2, 8, -1) REL_WHEEL Test: sending into event_pipeline: InputEvent for (2, 6, 1) REL_HWHEEL Test: sending into event_pipeline: InputEvent for (2, 8, -1) REL_WHEEL Test: sending into event_pipeline: InputEvent for (2, 6, 1) REL_HWHEEL Test: sending into event_pipeline: InputEvent for (2, 8, -1) REL_WHEEL Test: sending into event_pipeline: InputEvent for (2, 6, 1) REL_HWHEEL Test: sending into event_pipeline: InputEvent for (2, 8, -1) REL_WHEEL 15:19:17.878475 435078 pytest DEBUG event_reader.py:191: Starting to listen for events from /dev/input/event11, fd 16 15:19:18.977330 435078 pytest DEBUG rel_to_btn_handler.py:93: Sending InputEvent for (2, 6, 0) REL_HWHEEL to sub_handler 15:19:19.005866 435078 pytest DEBUG combination_handler.py:138: Sending Combination (InputConfig REL_HWHEEL) to sub-handler 15:19:19.409911 435078 pytest DEBUG logger.py:105: Writing (1, 91, 1) to "input-remapper keyboard" Test: (1, 91, 1) KEY_HIRAGANA written to "input-remapper keyboard" 15:19:19.447387 435078 pytest DEBUG rel_to_btn_handler.py:93: Sending InputEvent for (2, 8, 0) REL_WHEEL to sub_handler 15:19:19.980096 435078 pytest DEBUG combination_handler.py:138: Sending Combination (InputConfig REL_WHEEL) to sub-handler 15:19:20.012845 435078 pytest DEBUG logger.py:105: Writing (1, 92, 0) to "input-remapper keyboard" Test: (1, 92, 0) KEY_HENKAN written to "input-remapper keyboard" 15:19:20.427132 435078 pytest DEBUG logger.py:105: Writing (1, 91, 0) to "input-remapper keyboard" Test: (1, 91, 0) KEY_HIRAGANA written to "input-remapper keyboard" Test: sending into event_pipeline: InputEvent for (2, 6, 1) REL_HWHEEL 15:19:20.863249 435078 pytest DEBUG combination_handler.py:138: Sending Combination (InputConfig REL_HWHEEL) to sub-handler Test: sending into event_pipeline: InputEvent for (2, 8, -1) REL_WHEEL 15:19:21.954803 435078 pytest DEBUG combination_handler.py:138: Sending Combination (InputConfig REL_WHEEL) to sub-handler 15:19:22.004566 435078 pytest DEBUG logger.py:105: Writing (1, 92, 1) to "input-remapper keyboard" Test: (1, 92, 1) KEY_HENKAN written to "input-remapper keyboard" Test: sending into event_pipeline: InputEvent for (2, 6, 1) REL_HWHEEL Test: sending into event_pipeline: InputEvent for (2, 8, -1) REL_WHEEL Test: sending into event_pipeline: InputEvent for (2, 6, 1) REL_HWHEEL Test: sending into event_pipeline: InputEvent for (2, 8, -1) REL_WHEEL Test: sending into event_pipeline: InputEvent for (2, 6, 1) REL_HWHEEL Test: sending into event_pipeline: InputEvent for (2, 8, -1) REL_WHEEL Test: sending into event_pipeline: InputEvent for (2, 6, 1) REL_HWHEEL Test: sending into event_pipeline: InputEvent for (2, 8, -1) REL_WHEEL Test: sending into event_pipeline: InputEvent for (2, 6, -1) REL_HWHEEL 15:19:22.835450 435078 pytest DEBUG rel_to_btn_handler.py:117: Sending InputEvent for (2, 6, 0) REL_HWHEEL to sub_handler 15:19:23.354976 435078 pytest DEBUG combination_handler.py:138: Sending Combination (InputConfig REL_HWHEEL) to sub-handler Test: sending into event_pipeline: InputEvent for (2, 6, -1) REL_HWHEEL Test: (2, 6, -1) REL_HWHEEL written to "unnamed" Test: sending into event_pipeline: InputEvent for (2, 6, -1) REL_HWHEEL Test: (2, 6, -1) REL_HWHEEL written to "unnamed" 15:19:24.023553 435078 pytest DEBUG logger.py:105: Writing (1, 91, 1) to "input-remapper keyboard" Test: (1, 91, 1) KEY_HIRAGANA written to "input-remapper keyboard" 15:19:24.369877 435078 pytest DEBUG rel_to_btn_handler.py:93: Sending InputEvent for (2, 8, 0) REL_WHEEL to sub_handler 15:19:24.409143 435078 pytest DEBUG combination_handler.py:138: Sending Combination (InputConfig REL_WHEEL) to sub-handler 15:19:24.772401 435078 pytest DEBUG logger.py:105: Writing (1, 92, 0) to "input-remapper keyboard" Test: (1, 92, 0) KEY_HENKAN written to "input-remapper keyboard" 15:19:24.807623 435078 pytest DEBUG logger.py:105: Writing (1, 91, 0) to "input-remapper keyboard" Test: (1, 91, 0) KEY_HIRAGANA written to "input-remapper keyboard" Test: setting stop_event for the reader 15:19:25.884839 435078 pytest DEBUG event_reader.py:108: read loop stopped 15:19:26.264782 435078 pytest DEBUG key_handler.py:81: resetting key_handler 15:19:26.284262 435078 pytest INFO event_reader.py:207: read loop for /dev/input/event11 stopped Test: Cleanup... 15:19:36.183314 436654 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 15:19:38.837685 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 15:19:40.393042 436659 pytest DEBUG shared_dict.py:63: SharedDict process started 15:19:40.429466 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 15:19:42.178033 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 15:19:42.218824 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 15:19:45.784919 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 15:19:45.832133 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 15:19:49.432202 436659 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 15:19:49.989196 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 15:19:50.026697 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 15:19:50.387016 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 15:19:50.413623 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 15:19:50.750390 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" 15:19:51.246367 435078 pytest DEBUG groups.py:354: Discovering device paths 15:19:51.300877 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 15:19:51.780976 435078 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 15:19:51.833074 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 15:19:52.221144 435078 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 15:19:52.248096 435078 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 15:19:52.278670 435078 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 15:19:52.798620 435078 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 15:19:52.832078 435078 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 15:19:53.159924 435078 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 15:19:53.207046 435078 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 15:19:53.581353 435078 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 15:19:54.232300 435078 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" Test: Cleanup done ------------------------------ Captured log call ------------------------------- WARNING input-remapper:input_config.py:272 No origin_hash set for {'type': 2, 'code': 6, 'analog_threshold': 1} DEBUG input-remapper:parse.py:456 parsing macro k(b) WARNING input-remapper:input_config.py:272 No origin_hash set for {'type': 2, 'code': 8, 'analog_threshold': -1} DEBUG input-remapper:parse.py:456 parsing macro k(b) INFO input-remapper-test:fixtures.py:56 Hash for fixture "/dev/input/event11" "Foo Device foo": "77605ea88cd2159e71044704ef068863" WARNING input-remapper:context.py:90 Not source_devices set DEBUG input-remapper:parse.py:456 parsing macro k(b) DEBUG input-remapper:parse.py:244 calls k with b DEBUG input-remapper:parse.py:244 string b DEBUG input-remapper:parse.py:244 add call to k with ['b'], {} WARNING input-remapper:input_config.py:272 No origin_hash set for {'type': 2, 'code': 6, 'analog_threshold': 1} DEBUG input-remapper:combination_handler.py:56 {'input_combination': ) at 0xffffff93514af0>, 'target_uinput': 'keyboard'} WARNING input-remapper:input_config.py:272 No origin_hash set for {'type': 2, 'code': 8, 'analog_threshold': -1} DEBUG input-remapper:combination_handler.py:56 {'input_combination': ) at 0xffffff93516c10>, 'target_uinput': 'keyboard'} DEBUG input-remapper:mapping_parser.py:133 event-pipeline with entry point: REL_HWHEEL (2, 6, None) DEBUG input-remapper:logger.py:77 DEBUG input-remapper:logger.py:77 ) at 0xffffff93514a50>" ((2, 6, None),) at 0xffffff936bb020> DEBUG input-remapper:logger.py:77 DEBUG input-remapper:logger.py:77 'maps to on keyboard' DEBUG input-remapper:mapping_parser.py:133 event-pipeline with entry point: REL_WHEEL (2, 8, None) DEBUG input-remapper:logger.py:77 DEBUG input-remapper:logger.py:77 ) at 0xffffff935154a0>" ((2, 8, None),) at 0xffffff95fb49b0> DEBUG input-remapper:logger.py:77 DEBUG input-remapper:logger.py:77 'maps to: KEY_HENKAN (1, 92) on keyboard' DEBUG input-remapper:context.py:110 Adding NotifyCallback for (2, 6, None) DEBUG input-remapper:context.py:110 Adding NotifyCallback for (2, 8, None) INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 6, 1) REL_HWHEEL DEBUG input-remapper:combination_handler.py:138 Sending Combination (InputConfig REL_HWHEEL) to sub-handler INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 8, -1) REL_WHEEL DEBUG input-remapper:combination_handler.py:138 Sending Combination (InputConfig REL_WHEEL) to sub-handler DEBUG input-remapper:logger.py:105 Writing (1, 92, 1) to "input-remapper keyboard" INFO input-remapper-test:patches.py:229 (1, 92, 1) KEY_HENKAN written to "input-remapper keyboard" INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 6, 1) REL_HWHEEL INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 8, -1) REL_WHEEL INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 6, 1) REL_HWHEEL INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 8, -1) REL_WHEEL INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 6, 1) REL_HWHEEL INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 8, -1) REL_WHEEL INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 6, 1) REL_HWHEEL INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 8, -1) REL_WHEEL WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 8.850 seconds DEBUG input-remapper:event_reader.py:191 Starting to listen for events from /dev/input/event11, fd 16 WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 1.088 seconds DEBUG input-remapper:rel_to_btn_handler.py:93 Sending InputEvent for (2, 6, 0) REL_HWHEEL to sub_handler DEBUG input-remapper:combination_handler.py:138 Sending Combination (InputConfig REL_HWHEEL) to sub-handler WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.409 seconds DEBUG input-remapper:logger.py:105 Writing (1, 91, 1) to "input-remapper keyboard" INFO input-remapper-test:patches.py:229 (1, 91, 1) KEY_HIRAGANA written to "input-remapper keyboard" DEBUG input-remapper:rel_to_btn_handler.py:93 Sending InputEvent for (2, 8, 0) REL_WHEEL to sub_handler DEBUG input-remapper:combination_handler.py:138 Sending Combination (InputConfig REL_WHEEL) to sub-handler DEBUG input-remapper:logger.py:105 Writing (1, 92, 0) to "input-remapper keyboard" INFO input-remapper-test:patches.py:229 (1, 92, 0) KEY_HENKAN written to "input-remapper keyboard" WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.594 seconds WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_wait.._on_completion() at /usr/lib64/python3.12/asyncio/tasks.py:524] created at /builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/event_reader.py:86> took 0.346 seconds DEBUG input-remapper:logger.py:105 Writing (1, 91, 0) to "input-remapper keyboard" INFO input-remapper-test:patches.py:229 (1, 91, 0) KEY_HIRAGANA written to "input-remapper keyboard" WARNING asyncio:base_events.py:1946 Executing created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.364 seconds INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 6, 1) REL_HWHEEL DEBUG input-remapper:combination_handler.py:138 Sending Combination (InputConfig REL_HWHEEL) to sub-handler INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 8, -1) REL_WHEEL DEBUG input-remapper:combination_handler.py:138 Sending Combination (InputConfig REL_WHEEL) to sub-handler DEBUG input-remapper:logger.py:105 Writing (1, 92, 1) to "input-remapper keyboard" INFO input-remapper-test:patches.py:229 (1, 92, 1) KEY_HENKAN written to "input-remapper keyboard" INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 6, 1) REL_HWHEEL INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 8, -1) REL_WHEEL INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 6, 1) REL_HWHEEL INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 8, -1) REL_WHEEL INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 6, 1) REL_HWHEEL INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 8, -1) REL_WHEEL INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 6, 1) REL_HWHEEL INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 8, -1) REL_WHEEL INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 6, -1) REL_HWHEEL DEBUG input-remapper:rel_to_btn_handler.py:117 Sending InputEvent for (2, 6, 0) REL_HWHEEL to sub_handler DEBUG input-remapper:combination_handler.py:138 Sending Combination (InputConfig REL_HWHEEL) to sub-handler INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 6, -1) REL_HWHEEL INFO input-remapper-test:patches.py:229 (2, 6, -1) REL_HWHEEL written to "unnamed" INFO input-remapper-test:test_event_pipeline.py:88 sending into event_pipeline: InputEvent for (2, 6, -1) REL_HWHEEL INFO input-remapper-test:patches.py:229 (2, 6, -1) REL_HWHEEL written to "unnamed" WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 3.196 seconds DEBUG input-remapper:logger.py:105 Writing (1, 91, 1) to "input-remapper keyboard" INFO input-remapper-test:patches.py:229 (1, 91, 1) KEY_HIRAGANA written to "input-remapper keyboard" WARNING asyncio:base_events.py:1946 Executing created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.344 seconds DEBUG input-remapper:rel_to_btn_handler.py:93 Sending InputEvent for (2, 8, 0) REL_WHEEL to sub_handler DEBUG input-remapper:combination_handler.py:138 Sending Combination (InputConfig REL_WHEEL) to sub-handler DEBUG input-remapper:logger.py:105 Writing (1, 92, 0) to "input-remapper keyboard" INFO input-remapper-test:patches.py:229 (1, 92, 0) KEY_HENKAN written to "input-remapper keyboard" WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.429 seconds DEBUG input-remapper:logger.py:105 Writing (1, 91, 0) to "input-remapper keyboard" INFO input-remapper-test:patches.py:229 (1, 91, 0) KEY_HIRAGANA written to "input-remapper keyboard" WARNING asyncio:base_events.py:1946 Executing created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.369 seconds INFO input-remapper-test:test_event_pipeline.py:81 setting stop_event for the reader DEBUG input-remapper:event_reader.py:108 read loop stopped DEBUG input-remapper:key_handler.py:81 resetting key_handler INFO input-remapper:event_reader.py:207 read loop for /dev/input/event11 stopped WARNING asyncio:base_events.py:1946 Executing result=None created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.428 seconds INFO input-remapper-test:cleanup.py:170 Cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" DEBUG input-remapper:groups.py:354 Discovering device paths DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" DEBUG input-remapper:groups.py:402 Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:391 "Foo Device qux" has no useful capabilities DEBUG input-remapper:groups.py:402 Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" DEBUG input-remapper:groups.py:402 Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" DEBUG input-remapper:groups.py:402 Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" DEBUG input-remapper:groups.py:395 "YuBiCofooYuBiKeYbar" is denylisted DEBUG input-remapper:groups.py:402 Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" INFO input-remapper:groups.py:481 Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" INFO input-remapper-test:cleanup.py:179 Cleanup done ________________________ TestAbsToRelHandler.test_reset ________________________ self = async def test_reset(self): self.handler.notify( InputEvent(0, 0, EV_ABS, ABS_X, MAX_ABS), source=InputDevice("/dev/input/event15"), ) await asyncio.sleep(0.2) self.handler.reset() await asyncio.sleep(0.05) count = global_uinputs.get_uinput("mouse").write_count > self.assertGreater(count, 6) # count should be 60*0.2 = 12 E AssertionError: 2 not greater than 6 tests/unit/test_event_pipeline/test_mapping_handlers.py:240: AssertionError ----------------------------- Captured stderr call ----------------------------- 15:28:06.835066 435078 pytest WARNING input_config.py:272: No origin_hash set for {'type': 3, 'code': 0} 15:28:07.242979 435078 pytest WARNING input_config.py:272: No origin_hash set for {'type': 3, 'code': 0} 15:28:11.573630 435078 pytest DEBUG logger.py:105: Writing (2, 0, 60) to "input-remapper mouse" Test: (2, 0, 60) REL_X written to "input-remapper mouse" Test: (2, 0, 60) REL_X written to "input-remapper mouse" Test: Cleanup... 15:28:22.616670 436739 pytest DEBUG shared_dict.py:67: SharedDict got ('stop',) 15:28:25.826676 435078 pytest DEBUG shared_dict.py:57: Starting SharedDict process 15:28:27.011160 436744 pytest DEBUG shared_dict.py:63: SharedDict process started 15:28:27.015419 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" 15:28:28.256537 435078 pytest INFO global_config.py:129: Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json 15:28:28.290548 435078 pytest DEBUG system_mapping.py:128: Gathering available keycodes 15:28:32.809193 435078 pytest INFO paths.py:55: Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 15:28:33.194200 435078 pytest DEBUG system_mapping.py:114: Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" 15:28:36.258219 436744 pytest DEBUG shared_dict.py:67: SharedDict got ('ping',) 15:28:36.796573 435078 service DEBUG global_uinputs.py:132: Creating regular UInputs 15:28:36.821376 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard" 15:28:37.050792 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper gamepad" 15:28:37.365865 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper mouse" 15:28:37.400357 435078 service DEBUG global_uinputs.py:80: creating UInput device: "input-remapper keyboard + mouse" 15:28:38.363816 435078 pytest DEBUG groups.py:354: Discovering device paths 15:28:38.416474 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" 15:28:38.442791 435078 pytest DEBUG groups.py:402: Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" 15:28:38.867725 435078 pytest DEBUG groups.py:402: Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" 15:28:38.900766 435078 pytest DEBUG groups.py:402: Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" 15:28:38.928156 435078 pytest DEBUG groups.py:391: "Foo Device qux" has no useful capabilities 15:28:38.952840 435078 pytest DEBUG groups.py:402: Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" 15:28:39.422889 435078 pytest DEBUG groups.py:402: Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" 15:28:39.463775 435078 pytest DEBUG groups.py:402: Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" 15:28:40.011074 435078 pytest DEBUG groups.py:402: Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" 15:28:40.043688 435078 pytest DEBUG groups.py:395: "YuBiCofooYuBiKeYbar" is denylisted 15:28:40.567150 435078 pytest DEBUG groups.py:402: Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" 15:28:40.663670 435078 pytest INFO groups.py:481: Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" Test: Cleanup done ------------------------------ Captured log call ------------------------------- WARNING input-remapper:input_config.py:272 No origin_hash set for {'type': 3, 'code': 0} WARNING input-remapper:input_config.py:272 No origin_hash set for {'type': 3, 'code': 0} ERROR asyncio:base_events.py:1785 Task exception was never retrieved future: exception=TypeError('Passing coroutines is forbidden, use tasks explicitly.') created at /usr/lib64/python3.12/asyncio/tasks.py:410> source_traceback: Object created at (most recent call last): File "/usr/bin/pytest", line 8, in sys.exit(console_main()) File "/usr/lib/python3.12/site-packages/_pytest/config/__init__.py", line 189, in console_main code = main() File "/usr/lib/python3.12/site-packages/_pytest/config/__init__.py", line 166, in main ret: Union[ExitCode, int] = config.hook.pytest_cmdline_main( File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 316, in pytest_cmdline_main return wrap_session(config, _main) File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 269, in wrap_session session.exitstatus = doit(config, session) or 0 File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 323, in _main config.hook.pytest_runtestloop(session=session) File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 348, in pytest_runtestloop item.config.hook.pytest_runtest_protocol(item=item, nextitem=nextitem) File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 114, in pytest_runtest_protocol runtestprotocol(item, nextitem=nextitem) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 133, in runtestprotocol reports.append(call_and_report(item, "call", log)) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 222, in call_and_report call = call_runtest_hook(item, when, **kwds) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 261, in call_runtest_hook return CallInfo.from_call( File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 341, in from_call result: Optional[TResult] = func() File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 262, in lambda: ihook(item=item, **kwds), when=when, reraise=reraise File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 169, in pytest_runtest_call item.runtest() File "/usr/lib/python3.12/site-packages/_pytest/unittest.py", line 314, in runtest self._testcase(result=self) # type: ignore[arg-type] File "/usr/lib64/python3.12/unittest/case.py", line 690, in __call__ return self.run(*args, **kwds) File "/usr/lib64/python3.12/unittest/async_case.py", line 131, in run return super().run(result) File "/usr/lib64/python3.12/unittest/case.py", line 634, in run self._callTestMethod(testMethod) File "/usr/lib64/python3.12/unittest/async_case.py", line 90, in _callTestMethod if self._callMaybeAsync(method) is not None: File "/usr/lib64/python3.12/unittest/async_case.py", line 112, in _callMaybeAsync return self._asyncioRunner.run( File "/usr/lib64/python3.12/asyncio/runners.py", line 118, in run return self._loop.run_until_complete(task) File "/usr/lib64/python3.12/asyncio/base_events.py", line 651, in run_until_complete self.run_forever() File "/usr/lib64/python3.12/asyncio/base_events.py", line 618, in run_forever self._run_once() File "/usr/lib64/python3.12/asyncio/base_events.py", line 1943, in _run_once handle._run() File "/usr/lib64/python3.12/asyncio/events.py", line 84, in _run self._context.run(self._callback, *self._args) File "/builddir/build/BUILD/input-remapper-2.0.1/tests/unit/test_event_pipeline/test_mapping_handlers.py", line 204, in test_rate_stays self.handler.notify( File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/mapping_handlers/rel_to_abs_handler.py", line 179, in notify self._recenter_loop = asyncio.create_task(self._create_recenter_loop()) File "/usr/lib64/python3.12/asyncio/tasks.py", line 410, in create_task task = loop.create_task(coro) Traceback (most recent call last): File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/mapping_handlers/rel_to_abs_handler.py", line 206, in _create_recenter_loop await asyncio.wait( File "/usr/lib64/python3.12/asyncio/tasks.py", line 451, in wait raise TypeError("Passing coroutines is forbidden, use tasks explicitly.") TypeError: Passing coroutines is forbidden, use tasks explicitly. WARNING asyncio:base_events.py:1946 Executing wait_for= cb=[_run_until_complete_cb() at /usr/lib64/python3.12/asyncio/base_events.py:180] created at /usr/lib64/python3.12/asyncio/runners.py:100> took 2.922 seconds DEBUG input-remapper:logger.py:105 Writing (2, 0, 60) to "input-remapper mouse" INFO input-remapper-test:patches.py:229 (2, 0, 60) REL_X written to "input-remapper mouse" WARNING asyncio:base_events.py:1946 Executing created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.402 seconds INFO input-remapper-test:patches.py:229 (2, 0, 60) REL_X written to "input-remapper mouse" WARNING asyncio:base_events.py:1946 Executing wait_for= created at /usr/lib64/python3.12/asyncio/tasks.py:685> took 0.548 seconds WARNING asyncio:base_events.py:1946 Executing , None) at /usr/lib64/python3.12/asyncio/futures.py:311 created at /usr/lib64/python3.12/asyncio/tasks.py:651> took 0.510 seconds INFO input-remapper-test:cleanup.py:170 Cleanup... DEBUG input-remapper:shared_dict.py:57 Starting SharedDict process INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json" INFO input-remapper:global_config.py:129 Saved config to /builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/config.json DEBUG input-remapper:system_mapping.py:128 Gathering available keycodes INFO input-remapper:paths.py:55 Creating file "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:system_mapping.py:114 Writing "/builddir/build/BUILD/input-remapper-2.0.1/test_tmp/input-remapper-testymu_qy_e/.config/input-remapper-2/xmodmap.json" DEBUG input-remapper:global_uinputs.py:132 Creating regular UInputs DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper gamepad" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper mouse" DEBUG input-remapper:global_uinputs.py:80 creating UInput device: "input-remapper keyboard + mouse" DEBUG input-remapper:groups.py:354 Discovering device paths DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event1", hash "878ea5f55f1029438c87d2631b882225", key "1_1_1_usb-0000:03:00.0-0" DEBUG input-remapper:groups.py:402 Found mouse "Foo Device foo" at "/dev/input/event11", hash "77605ea88cd2159e71044704ef068863", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Foo Device" at "/dev/input/event10", hash "698702013ccc49179d9669854f6c2b69", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found unknown "Foo Device" at "/dev/input/event13", hash "d7acf3a5d6121e07cfa3b499737817a3", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:391 "Foo Device qux" has no useful capabilities DEBUG input-remapper:groups.py:402 Found gamepad "Foo Device bar" at "/dev/input/event15", hash "cee831d56755e4bac5b0f5d2fcfd5735", key "1_1_1_usb-0000:03:00.0-1" DEBUG input-remapper:groups.py:402 Found keyboard "Bar Device" at "/dev/input/event20", hash "12c4e395bbf31316008b197e827e92c1", key "2_1_2_usb-0000:03:00.0-2" DEBUG input-remapper:groups.py:402 Found gamepad "gamepad" at "/dev/input/event30", hash "be7d866387c266d10cb76ef3a7dca90d", key "3_1_3_-" DEBUG input-remapper:groups.py:402 Found keyboard "input-remapper Bar Device" at "/dev/input/event40", hash "f7d8cf3905e8fabab38ead8aef00703e", key "5_1_5_input-remapper" DEBUG input-remapper:groups.py:395 "YuBiCofooYuBiKeYbar" is denylisted DEBUG input-remapper:groups.py:402 Found keyboard "Qux/Device?" at "/dev/input/event52", hash "97912a52f6c070f2366bedd3d0e8038a", key "2_1_2_usb-0000:03:00.0-3" INFO input-remapper:groups.py:481 Found "Foo Device", "Foo Device 2", "Bar Device", "gamepad", "input-remapper Bar Device", "Qux/Device?" INFO input-remapper-test:cleanup.py:179 Cleanup done =============================== warnings summary =============================== ../../../../usr/lib/python3.12/site-packages/gi/overrides/__init__.py:108: 14 warnings /usr/lib/python3.12/site-packages/gi/overrides/__init__.py:108: DeprecationWarning: 'pkgutil.get_loader' is deprecated and slated for removal in Python 3.14; use importlib.util.find_spec() instead override_loader = get_loader(override_package_name) ../../../../usr/lib64/python3.12/pkgutil.py:291: 14 warnings /usr/lib64/python3.12/pkgutil.py:291: DeprecationWarning: 'pkgutil.find_loader' is deprecated and slated for removal in Python 3.14; use importlib.util.find_spec() instead return find_loader(fullname) inputremapper/gui/messages/message_data.py:45 /builddir/build/BUILD/input-remapper-2.0.1/inputremapper/gui/messages/message_data.py:45: SyntaxWarning: invalid escape sequence '\d' all_matches = list(re.finditer("(\d+, )+", string)) inputremapper/gui/controller.py:304 /builddir/build/BUILD/input-remapper-2.0.1/inputremapper/gui/controller.py:304: SyntaxWarning: invalid escape sequence '\d' match = re.search(" copy *\d*$", name) tests/unit/test_config.py::TestConfig::test_autoload /builddir/build/BUILD/input-remapper-2.0.1/tests/lib/cleanup.py:105: DeprecationWarning: There is no current event loop if asyncio.get_event_loop().is_running(): tests/unit/test_event_pipeline/test_mapping_handlers.py::TestAbsToRelHandler::test_reset /usr/lib64/python3.12/traceback.py:268: RuntimeWarning: coroutine 'Event.wait' was never awaited Coroutine created at (most recent call last) File "/usr/lib64/python3.12/unittest/async_case.py", line 131, in run return super().run(result) File "/usr/lib64/python3.12/unittest/case.py", line 634, in run self._callTestMethod(testMethod) File "/usr/lib64/python3.12/unittest/async_case.py", line 90, in _callTestMethod if self._callMaybeAsync(method) is not None: File "/usr/lib64/python3.12/unittest/async_case.py", line 112, in _callMaybeAsync return self._asyncioRunner.run( File "/usr/lib64/python3.12/asyncio/runners.py", line 118, in run return self._loop.run_until_complete(task) File "/usr/lib64/python3.12/asyncio/base_events.py", line 651, in run_until_complete self.run_forever() File "/usr/lib64/python3.12/asyncio/base_events.py", line 618, in run_forever self._run_once() File "/usr/lib64/python3.12/asyncio/base_events.py", line 1943, in _run_once handle._run() File "/usr/lib64/python3.12/asyncio/events.py", line 84, in _run self._context.run(self._callback, *self._args) File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/mapping_handlers/rel_to_abs_handler.py", line 207, in _create_recenter_loop (self._moving.wait(),), timeout=self.mapping.release_timeout def __init__(self, filename, lineno, name, *, lookup_line=True, Object allocated at: File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/mapping_handlers/rel_to_abs_handler.py", line 207 (self._moving.wait(),), timeout=self.mapping.release_timeout -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html =========================== short test summary info ============================ FAILED tests/unit/test_event_reader.py::TestEventReader::test_if_single_joystick_then FAILED tests/unit/test_event_reader.py::TestEventReader::test_if_single_joystick_under_threshold FAILED tests/unit/test_injector.py::TestInjector::test_fail_grab - AssertionE... FAILED tests/unit/test_injector.py::TestInjector::test_injector - AssertionEr... FAILED tests/unit/test_ipc.py::TestSharedDict::test_set_get - AssertionError:... FAILED tests/unit/test_macros.py::TestMacros::test_add - AssertionError: 0 != 2 FAILED tests/unit/test_macros.py::TestMacros::test_dont_hold - AssertionError... FAILED tests/unit/test_macros.py::TestMacros::test_dont_just_hold - Assertion... FAILED tests/unit/test_macros.py::TestMacros::test_duplicate_run - AssertionE... FAILED tests/unit/test_macros.py::TestMacros::test_hold - AssertionError: 2 n... FAILED tests/unit/test_macros.py::TestMacros::test_hold_keys - AssertionError... FAILED tests/unit/test_macros.py::TestMacros::test_hold_variable - inputremap... FAILED tests/unit/test_macros.py::TestMacros::test_just_hold - AssertionError... FAILED tests/unit/test_macros.py::TestMacros::test_key - inputremapper.config... FAILED tests/unit/test_macros.py::TestMacros::test_key_down_up - inputremappe... FAILED tests/unit/test_macros.py::TestMacros::test_macro_breaks - AssertionEr... FAILED tests/unit/test_macros.py::TestMacros::test_modify - inputremapper.con... FAILED tests/unit/test_macros.py::TestMacros::test_multiline_macro_and_comments FAILED tests/unit/test_macros.py::TestMacros::test_resolve - AssertionError: ... FAILED tests/unit/test_macros.py::TestMacros::test_run_plus_syntax - IndexErr... FAILED tests/unit/test_macros.py::TestMacros::test_set - AssertionError: 'pon... FAILED tests/unit/test_macros.py::TestIfEq::test_if_eq - AssertionError: 'pon... FAILED tests/unit/test_macros.py::TestIfEq::test_if_eq_runs_multiprocessed - ... FAILED tests/unit/test_macros.py::TestIfEq::test_ifeq_none - AssertionError: ... FAILED tests/unit/test_macros.py::TestIfEq::test_ifeq_runs - AssertionError: ... FAILED tests/unit/test_macros.py::TestIfEq::test_ifeq_unknown_key - Assertion... FAILED tests/unit/test_macros.py::TestIfSingle::test_if_not_single - Assertio... FAILED tests/unit/test_macros.py::TestIfSingle::test_if_single - AssertionErr... FAILED tests/unit/test_macros.py::TestIfSingle::test_if_single_ignores_joystick FAILED tests/unit/test_macros.py::TestIfSingle::test_if_single_ignores_releases FAILED tests/unit/test_macros.py::TestIfSingle::test_if_single_times_out - As... FAILED tests/unit/test_macros.py::TestIfTap::test_if_double_tap - AssertionEr... FAILED tests/unit/test_macros.py::TestIfTap::test_if_not_tap - AssertionError... FAILED tests/unit/test_macros.py::TestIfTap::test_if_not_tap_named - Assertio... FAILED tests/unit/test_macros.py::TestIfTap::test_if_tap - AssertionError: Li... FAILED tests/unit/test_macros.py::TestIfTap::test_if_tap_2 - AssertionError: ... FAILED tests/unit/test_macros.py::TestIfTap::test_if_tap_none - AssertionErro... FAILED tests/unit/test_reader.py::TestReaderAsyncio::test_should_forward_to_dummy FAILED tests/unit/test_reader.py::TestReaderMultiprocessing::test_are_new_groups_available FAILED tests/unit/test_reader.py::TestReaderMultiprocessing::test_blacklisted_events FAILED tests/unit/test_reader.py::TestReaderMultiprocessing::test_change_device FAILED tests/unit/test_reader.py::TestReaderMultiprocessing::test_ignore_value_2 FAILED tests/unit/test_reader.py::TestReaderMultiprocessing::test_reader_service_times_out FAILED tests/unit/test_reader.py::TestReaderMultiprocessing::test_reader_service_waits_for_client_to_finish FAILED tests/unit/test_reader.py::TestReaderMultiprocessing::test_reader_service_wont_wait_forever FAILED tests/unit/test_reader.py::TestReaderMultiprocessing::test_reading - A... FAILED tests/unit/test_reader.py::TestReaderMultiprocessing::test_reading_2 FAILED tests/unit/test_reader.py::TestReaderMultiprocessing::test_reading_ignore_up FAILED tests/unit/test_reader.py::TestReaderMultiprocessing::test_should_change_direction FAILED tests/unit/test_reader.py::TestReaderMultiprocessing::test_should_read_absolut_axis FAILED tests/unit/test_reader.py::TestReaderMultiprocessing::test_should_release_relative_axis FAILED tests/unit/test_reader.py::TestReaderMultiprocessing::test_should_trigger_wheel_at_low_speed FAILED tests/unit/test_reader.py::TestReaderMultiprocessing::test_wont_emit_the_same_combination_twice FAILED tests/unit/test_test.py::TestTest::test_push_events - AssertionError: ... FAILED tests/unit/test_event_pipeline/test_event_pipeline.py::TestRelToBtn::test_rel_to_btn FAILED tests/unit/test_event_pipeline/test_mapping_handlers.py::TestAbsToRelHandler::test_reset ERROR tests/unit/test_injector.py::TestInjector::test_fail_grab - AssertionEr... ERROR tests/unit/test_injector.py::TestInjector::test_injector - AssertionErr... ERROR tests/unit/test_macros.py::TestMacros::test_add - AssertionError ERROR tests/unit/test_macros.py::TestMacros::test_hold_keys - AssertionError ERROR tests/unit/test_macros.py::TestMacros::test_hold_variable - AssertionError ERROR tests/unit/test_macros.py::TestMacros::test_key - AssertionError ERROR tests/unit/test_macros.py::TestMacros::test_key_down_up - AssertionError ERROR tests/unit/test_macros.py::TestMacros::test_macro_breaks - AssertionError ERROR tests/unit/test_macros.py::TestMacros::test_modify - AssertionError ERROR tests/unit/test_macros.py::TestMacros::test_multiline_macro_and_comments ERROR tests/unit/test_macros.py::TestMacros::test_resolve - AssertionError ERROR tests/unit/test_macros.py::TestMacros::test_set - AssertionError ERROR tests/unit/test_macros.py::TestIfEq::test_if_eq - AssertionError ERROR tests/unit/test_macros.py::TestIfEq::test_if_eq_runs_multiprocessed - A... ERROR tests/unit/test_macros.py::TestIfEq::test_ifeq_none - AssertionError ERROR tests/unit/test_macros.py::TestIfEq::test_ifeq_runs - AssertionError ERROR tests/unit/test_macros.py::TestIfSingle::test_if_single_times_out - Ass... = 56 failed, 341 passed, 8 deselected, 32 warnings, 17 errors in 12073.66s (3:21:13) = --- Logging error --- Traceback (most recent call last): File "/usr/lib64/python3.12/logging/__init__.py", line 1163, in emit stream.write(msg + self.terminator) ValueError: I/O operation on closed file. Call stack: File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/daemon.py", line 528, in stop_all logger.info("Stopping all injections") Message: 'Stopping all injections' Arguments: () --- Logging error --- Traceback (most recent call last): File "/usr/lib64/python3.12/logging/__init__.py", line 1163, in emit stream.write(msg + self.terminator) ValueError: I/O operation on closed file. Call stack: File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/daemon.py", line 528, in stop_all logger.info("Stopping all injections") Message: 'Stopping all injections' Arguments: () --- Logging error --- Traceback (most recent call last): File "/usr/lib64/python3.12/logging/__init__.py", line 1163, in emit stream.write(msg + self.terminator) ValueError: I/O operation on closed file. Call stack: File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/daemon.py", line 528, in stop_all logger.info("Stopping all injections") Message: 'Stopping all injections' Arguments: () --- Logging error --- Traceback (most recent call last): File "/usr/lib64/python3.12/logging/__init__.py", line 1163, in emit stream.write(msg + self.terminator) ValueError: I/O operation on closed file. Call stack: File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/daemon.py", line 528, in stop_all logger.info("Stopping all injections") Message: 'Stopping all injections' Arguments: () --- Logging error --- Traceback (most recent call last): File "/usr/lib64/python3.12/logging/__init__.py", line 1163, in emit stream.write(msg + self.terminator) ValueError: I/O operation on closed file. Call stack: File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/daemon.py", line 528, in stop_all logger.info("Stopping all injections") Message: 'Stopping all injections' Arguments: () Task exception was never retrieved future: exception=TypeError('Passing coroutines is forbidden, use tasks explicitly.') created at /usr/lib64/python3.12/asyncio/tasks.py:410> source_traceback: Object created at (most recent call last): File "/usr/bin/pytest", line 8, in sys.exit(console_main()) File "/usr/lib/python3.12/site-packages/_pytest/config/__init__.py", line 189, in console_main code = main() File "/usr/lib/python3.12/site-packages/_pytest/config/__init__.py", line 166, in main ret: Union[ExitCode, int] = config.hook.pytest_cmdline_main( File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 316, in pytest_cmdline_main return wrap_session(config, _main) File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 269, in wrap_session session.exitstatus = doit(config, session) or 0 File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 323, in _main config.hook.pytest_runtestloop(session=session) File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/main.py", line 348, in pytest_runtestloop item.config.hook.pytest_runtest_protocol(item=item, nextitem=nextitem) File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 114, in pytest_runtest_protocol runtestprotocol(item, nextitem=nextitem) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 133, in runtestprotocol reports.append(call_and_report(item, "call", log)) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 222, in call_and_report call = call_runtest_hook(item, when, **kwds) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 261, in call_runtest_hook return CallInfo.from_call( File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 341, in from_call result: Optional[TResult] = func() File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 262, in lambda: ihook(item=item, **kwds), when=when, reraise=reraise File "/usr/lib/python3.12/site-packages/pluggy/_hooks.py", line 493, in __call__ return self._hookexec(self.name, self._hookimpls, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_manager.py", line 115, in _hookexec return self._inner_hookexec(hook_name, methods, kwargs, firstresult) File "/usr/lib/python3.12/site-packages/pluggy/_callers.py", line 77, in _multicall res = hook_impl.function(*args) File "/usr/lib/python3.12/site-packages/_pytest/runner.py", line 169, in pytest_runtest_call item.runtest() File "/usr/lib/python3.12/site-packages/_pytest/unittest.py", line 314, in runtest self._testcase(result=self) # type: ignore[arg-type] File "/usr/lib64/python3.12/unittest/case.py", line 690, in __call__ return self.run(*args, **kwds) File "/usr/lib64/python3.12/unittest/async_case.py", line 131, in run return super().run(result) File "/usr/lib64/python3.12/unittest/case.py", line 634, in run self._callTestMethod(testMethod) File "/usr/lib64/python3.12/unittest/async_case.py", line 90, in _callTestMethod if self._callMaybeAsync(method) is not None: File "/usr/lib64/python3.12/unittest/async_case.py", line 112, in _callMaybeAsync return self._asyncioRunner.run( File "/usr/lib64/python3.12/asyncio/runners.py", line 118, in run return self._loop.run_until_complete(task) File "/usr/lib64/python3.12/asyncio/base_events.py", line 651, in run_until_complete self.run_forever() File "/usr/lib64/python3.12/asyncio/base_events.py", line 618, in run_forever self._run_once() File "/usr/lib64/python3.12/asyncio/base_events.py", line 1943, in _run_once handle._run() File "/usr/lib64/python3.12/asyncio/events.py", line 84, in _run self._context.run(self._callback, *self._args) File "/builddir/build/BUILD/input-remapper-2.0.1/tests/unit/test_event_pipeline/test_mapping_handlers.py", line 188, in test_rate_changes self.handler.notify( File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/mapping_handlers/rel_to_abs_handler.py", line 179, in notify self._recenter_loop = asyncio.create_task(self._create_recenter_loop()) File "/usr/lib64/python3.12/asyncio/tasks.py", line 410, in create_task task = loop.create_task(coro) Traceback (most recent call last): File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/mapping_handlers/rel_to_abs_handler.py", line 206, in _create_recenter_loop await asyncio.wait( File "/usr/lib64/python3.12/asyncio/tasks.py", line 451, in wait raise TypeError("Passing coroutines is forbidden, use tasks explicitly.") TypeError: Passing coroutines is forbidden, use tasks explicitly. sys:1: RuntimeWarning: coroutine 'Event.wait' was never awaited Coroutine created at (most recent call last) File "/usr/lib64/python3.12/unittest/async_case.py", line 131, in run return super().run(result) File "/usr/lib64/python3.12/unittest/case.py", line 634, in run self._callTestMethod(testMethod) File "/usr/lib64/python3.12/unittest/async_case.py", line 90, in _callTestMethod if self._callMaybeAsync(method) is not None: File "/usr/lib64/python3.12/unittest/async_case.py", line 112, in _callMaybeAsync return self._asyncioRunner.run( File "/usr/lib64/python3.12/asyncio/runners.py", line 118, in run return self._loop.run_until_complete(task) File "/usr/lib64/python3.12/asyncio/base_events.py", line 651, in run_until_complete self.run_forever() File "/usr/lib64/python3.12/asyncio/base_events.py", line 618, in run_forever self._run_once() File "/usr/lib64/python3.12/asyncio/base_events.py", line 1943, in _run_once handle._run() File "/usr/lib64/python3.12/asyncio/events.py", line 84, in _run self._context.run(self._callback, *self._args) File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/mapping_handlers/rel_to_abs_handler.py", line 207, in _create_recenter_loop (self._moving.wait(),), timeout=self.mapping.release_timeout Object allocated at (most recent call last): File "/builddir/build/BUILD/input-remapper-2.0.1/inputremapper/injection/mapping_handlers/rel_to_abs_handler.py", lineno 207 (self._moving.wait(),), timeout=self.mapping.release_timeout error: Bad exit status from /var/tmp/rpm-tmp.SYrYsN (%check) RPM build errors: Bad exit status from /var/tmp/rpm-tmp.SYrYsN (%check) Child return code was: 1 EXCEPTION: [Error('Command failed: \n # bash --login -c /usr/bin/rpmbuild -ba --noprep --noclean --target noarch --nodeps /builddir/build/SPECS/input-remapper.spec\n', 1)] Traceback (most recent call last): File "/usr/lib/python3.11/site-packages/mockbuild/trace_decorator.py", line 93, in trace result = func(*args, **kw) ^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/site-packages/mockbuild/util.py", line 597, in do_with_status raise exception.Error("Command failed: \n # %s\n%s" % (command, output), child.returncode) mockbuild.exception.Error: Command failed: # bash --login -c /usr/bin/rpmbuild -ba --noprep --noclean --target noarch --nodeps /builddir/build/SPECS/input-remapper.spec