nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix

Merge pull request #91087 from Mic92/python-fixes

authored by

Jörg Thalheim and committed by
GitHub
e5bdf9c2 09e64cf9

+39 -28
+2 -2
pkgs/development/python-modules/astral/default.nix
··· 1 - { stdenv, buildPythonPackage, fetchPypi, isPy27, pytz, requests, pytest }: 1 + { stdenv, buildPythonPackage, fetchPypi, isPy27, pytz, requests, pytest, freezegun }: 2 2 3 3 buildPythonPackage rec { 4 4 pname = "astral"; ··· 10 10 sha256 = "e41d9967d5c48be421346552f0f4dedad43ff39a83574f5ff2ad32b6627b6fbe"; 11 11 }; 12 12 13 - propagatedBuildInputs = [ pytz requests ]; 13 + propagatedBuildInputs = [ pytz requests freezegun ]; 14 14 15 15 checkInputs = [ pytest ]; 16 16 checkPhase = ''
+3
pkgs/development/python-modules/asynctest/default.nix
··· 17 17 --replace "test_events_watched_outside_test_are_ignored" "xtest_events_watched_outside_test_are_ignored" 18 18 ''; 19 19 20 + # https://github.com/Martiusweb/asynctest/issues/132 21 + doCheck = pythonOlder "3.8"; 22 + 20 23 checkPhase = '' 21 24 ${python.interpreter} -m unittest test 22 25 '';
+6 -13
pkgs/development/python-modules/eyed3/default.nix
··· 1 1 { stdenv 2 2 , buildPythonPackage 3 3 , fetchPypi 4 - , pythonAtLeast 5 4 , pythonOlder 6 - , paver 7 5 , python 8 6 , isPyPy 9 7 , six 10 - , pathlib 11 - , python_magic 12 8 , lib 9 + , filetype 10 + , deprecation 11 + , dataclasses 13 12 }: 14 13 15 14 buildPythonPackage rec { ··· 21 22 sha256 = "faf5806197f2093e82c2830d41f2378f07b3a9da07a16fafb14fc6fbdebac50a"; 22 23 }; 23 24 24 - # https://github.com/nicfit/eyeD3/pull/284 25 - postPatch = lib.optionalString (pythonAtLeast "3.4") '' 26 - sed -ie '/pathlib/d' requirements/requirements.yml 27 - ''; 28 - 29 - buildInputs = [ paver ]; 30 - 31 25 # requires special test data: 32 26 # https://github.com/nicfit/eyeD3/blob/103198e265e3279384f35304e8218be6717c2976/Makefile#L97 33 27 doCheck = false; 34 28 35 - propagatedBuildInputs = [ six python_magic ] ++ lib.optional (pythonOlder "3.4") pathlib; 29 + propagatedBuildInputs = [ 30 + six filetype deprecation 31 + ] ++ lib.optional (pythonOlder "3.7") dataclasses; 36 32 37 33 postInstall = '' 38 34 for prog in "$out/bin/"*; do ··· 49 55 and v2.3/v2.4. 50 56 ''; 51 57 }; 52 - 53 58 }
+19 -7
pkgs/development/python-modules/hass-nabucasa/default.nix
··· 1 1 { lib, buildPythonPackage, fetchFromGitHub, fetchpatch 2 2 , acme, aiohttp, snitun, attrs, pycognito, warrant 3 - , pytest-aiohttp, asynctest, pytest }: 3 + , pytest-aiohttp, asynctest, atomicwrites, pytest, pythonOlder }: 4 4 5 5 buildPythonPackage rec { 6 6 pname = "hass-nabucasa"; 7 - version = "0.32.2"; 7 + version = "0.34.6"; 8 8 9 9 src = fetchFromGitHub { 10 10 owner = "nabucasa"; 11 11 repo = pname; 12 12 rev = version; 13 - sha256 = "1hfi5q222kgbgrj5yvr4lbhca49hcs6sc2yhxc4pjxqsc12bv1f1"; 13 + sha256 = "1lkqwj58qr0vn7zf5mhrhaz973ahj9wjp4mgzvyja1gcdh6amv34"; 14 14 }; 15 15 16 - # upstreamed in https://github.com/NabuCasa/hass-nabucasa/pull/119 17 16 postPatch = '' 18 - sed -i 's/"acme.*/"acme>=0.40.0,<2.0"/' setup.py 19 - cat setup.py 17 + sed -i 's/"acme.*"/"acme"/' setup.py 20 18 ''; 21 19 22 - propagatedBuildInputs = [ acme aiohttp snitun attrs warrant pycognito ]; 20 + patches = [ 21 + # relax pytz dependency 22 + (fetchpatch { 23 + url = "https://github.com/NabuCasa/hass-nabucasa/commit/419e80feddc36c68384c032feda0057515b53eaa.patch"; 24 + sha256 = "14dgwci8615cwcf27hg7b42s7da50xhyjys3yx446q7ipk8zw4x6"; 25 + }) 26 + ]; 27 + 28 + propagatedBuildInputs = [ 29 + acme aiohttp atomicwrites snitun attrs warrant pycognito 30 + ]; 23 31 24 32 checkInputs = [ pytest pytest-aiohttp asynctest ]; 33 + 34 + # Asynctest's mocking is broken with python3.8 35 + # https://github.com/Martiusweb/asynctest/issues/132 36 + doCheck = pythonOlder "3.8"; 25 37 26 38 checkPhase = '' 27 39 pytest tests/
+5 -2
pkgs/development/python-modules/janus/default.nix
··· 1 - { lib, buildPythonPackage, fetchPypi, pytest, pythonOlder }: 1 + { lib, buildPythonPackage, fetchPypi, pytestCheckHook, pythonOlder, pytest-asyncio }: 2 2 3 3 buildPythonPackage rec { 4 4 pname = "janus"; ··· 11 11 12 12 disabled = pythonOlder "3.6"; 13 13 14 - checkInputs = [ pytest ]; 14 + checkInputs = [ pytest-asyncio pytestCheckHook ]; 15 + 16 + # also fails upstream: https://github.com/aio-libs/janus/pull/258 17 + disabledTests = [ "test_format" ]; 15 18 16 19 meta = with lib; { 17 20 description = "Mixed sync-async queue";
+2 -2
pkgs/development/python-modules/pycognito/default.nix
··· 12 12 13 13 buildPythonPackage rec { 14 14 pname = "pycognito"; 15 - version = "0.1.2"; 15 + version = "0.1.3"; 16 16 17 17 src = fetchFromGitHub { 18 18 owner = "pvizeli"; 19 19 repo = "pycognito"; 20 20 rev = version; 21 - sha256 = "01zns522awm5yp5cbk1y7k7px534i5akiivip709i1naph3hvnfk"; 21 + sha256 = "0wy6d274xda7v6dazv10h2vwig2avfyz8mh2lpd1a5k7i06r335r"; 22 22 }; 23 23 24 24 postPatch = ''
+2 -2
pkgs/development/python-modules/python-engineio/default.nix
··· 13 13 14 14 buildPythonPackage rec { 15 15 pname = "python-engineio"; 16 - version = "3.10.0"; 16 + version = "3.13.0"; 17 17 18 18 src = fetchFromGitHub { 19 19 owner = "miguelgrinberg"; 20 20 repo = "python-engineio"; 21 21 rev = "v${version}"; 22 - sha256 = "1495r55177c38wq88pb28l50dfd4213iyxwq1k5rmsgp66vww09s"; 22 + sha256 = "1fgfrgcvjg3fyza5lhl1l9cfq073xrwwhh3xs178csrjz4s8s378"; 23 23 }; 24 24 25 25 propagatedBuildInputs = [