diff --git a/ci/hardware_tests/uhubctl.nix b/ci/hardware_tests/uhubctl.nix deleted file mode 100644 index 2ecb7b3d0..000000000 --- a/ci/hardware_tests/uhubctl.nix +++ /dev/null @@ -1,27 +0,0 @@ -{ lib, stdenv -, fetchFromGitHub -, libusb1 -}: - -stdenv.mkDerivation rec { - pname = "uhubctl"; - version = "2.3.0"; - - src = fetchFromGitHub { - owner = "mvp"; - repo = "uhubctl"; - rev = "refs/tags/v${version}"; - sha256 = "1wxsiygw6gwv1h90yassnxylkyi2dfz7y59qkmb7rs8a8javj7nv"; - }; - - buildInputs = [ libusb1 ]; - - installFlags = [ "prefix=${placeholder "out"}" ]; - meta = with lib; { - homepage = "https://github.com/mvp/uhubctl"; - description = "Utility to control USB power per-port on smart USB hubs"; - license = licenses.gpl2; - maintainers = with maintainers; [ prusnak ]; - platforms = with platforms; linux ++ darwin; - }; -} diff --git a/ci/shell.nix b/ci/shell.nix index 2e0f652bb..c2648b61c 100644 --- a/ci/shell.nix +++ b/ci/shell.nix @@ -2,10 +2,10 @@ , hardwareTest ? false }: -# the last successful build of nixpkgs-unstable as of 2020-12-30 +# the last successful build of nixpkgs-unstable as of 2021-03-25 with import (builtins.fetchTarball { - url = "https://github.com/NixOS/nixpkgs/archive/bea44d5ebe332260aa34a1bd48250b6364527356.tar.gz"; - sha256 = "14sfk04iyvyh3jl1s2wayw1y077dwpk2d712nhjk1wwfjkdq03r3"; + url = "https://github.com/NixOS/nixpkgs/archive/c0e881852006b132236cbf0301bd1939bb50867e.tar.gz"; + sha256 = "0fy7z7yxk5n7yslsvx5cyc6h21qwi4bhxf3awhirniszlbvaazy2"; }) { }; @@ -70,7 +70,7 @@ stdenv.mkDerivation ({ darwin.libobjc libiconv ] ++ lib.optionals hardwareTest [ - (callPackage ./hardware_tests/uhubctl.nix { }) # HACK FIXME replace this with just uhubctl once pinned version of nixpkgs is updated + uhubctl ffmpeg dejavu_fonts ]; diff --git a/ci/test.yml b/ci/test.yml index d01ae690b..a803c79f3 100644 --- a/ci/test.yml +++ b/ci/test.yml @@ -280,7 +280,16 @@ python test: - common/**/* - python/**/* script: - - nix-shell --arg fullDeps true --run "cd python && poetry run tox" + # Workaround for nixpkgs+tox integration failure which results in: + # ModuleNotFoundError: No module named '_sysconfigdata__linux_x86_64-linux-gnu' + # The value of _PYTHON_SYSCONFIGDATA_NAME has changed between python 3.7 and 3.8 and with + # multiple versions in your environment the older pythons don't seem to work under tox. + # When the variable is unset the interpreter seems to do the right thing. Can be removed in + # july 2023 when python 3.7 is EOLed. + # See also: + # https://github.com/NixOS/nixpkgs/blob/b00c7c2d1d905eb63c81a0917f1a94b763a7843b/pkgs/development/interpreters/python/cpython/default.nix#L103 + # https://github.com/NixOS/nixpkgs/pull/98915 + - nix-shell --arg fullDeps true --run "unset _PYTHON_SYSCONFIGDATA_NAME && cd python && poetry run tox" # Storage