diff options
author | Martin Weinelt <hexa@darmstadt.ccc.de> | 2021-12-25 20:38:14 +0100 |
---|---|---|
committer | Martin Weinelt <hexa@darmstadt.ccc.de> | 2022-01-06 03:09:46 +0100 |
commit | ec7062492f88984017da132aa28167d0a5d3a456 (patch) | |
tree | d332ba4861ec40a6b591b11a833d833e10f90d68 | |
parent | 7580fbb4be6fa9ef922bd3b1b90aecefffc91616 (diff) | |
download | nixpkgs-ec7062492f88984017da132aa28167d0a5d3a456.tar nixpkgs-ec7062492f88984017da132aa28167d0a5d3a456.tar.gz nixpkgs-ec7062492f88984017da132aa28167d0a5d3a456.tar.bz2 nixpkgs-ec7062492f88984017da132aa28167d0a5d3a456.tar.lz nixpkgs-ec7062492f88984017da132aa28167d0a5d3a456.tar.xz nixpkgs-ec7062492f88984017da132aa28167d0a5d3a456.tar.zst nixpkgs-ec7062492f88984017da132aa28167d0a5d3a456.zip |
python3Packages.pydub: clean up and adopt
-rw-r--r-- | pkgs/development/python-modules/pydub/default.nix | 37 |
1 files changed, 24 insertions, 13 deletions
diff --git a/pkgs/development/python-modules/pydub/default.nix b/pkgs/development/python-modules/pydub/default.nix index 6b67814a222..3adf54281b7 100644 --- a/pkgs/development/python-modules/pydub/default.nix +++ b/pkgs/development/python-modules/pydub/default.nix @@ -1,8 +1,18 @@ -{ lib, stdenv, buildPythonPackage, fetchFromGitHub, scipy, ffmpeg-full }: +{ lib +, stdenv +, buildPythonPackage +, fetchFromGitHub + +# tests +, ffmpeg-full +, python +}: buildPythonPackage rec { pname = "pydub"; version = "0.25.1"; + format = "setuptools"; + # pypi version doesn't include required data files for tests src = fetchFromGitHub { owner = "jiaaro"; @@ -11,23 +21,24 @@ buildPythonPackage rec { sha256 = "0xskllq66wqndjfmvp58k26cv3w480sqsil6ifwp4gghir7hqc8m"; }; + pythonImportsCheck = [ + "pydub" + "pydub.audio_segment" + "pydub.playback" + ]; - # disable a test that fails on aarch64 due to rounding errors - postPatch = lib.optionalString stdenv.isAarch64 '' - substituteInPlace test/test.py \ - --replace "test_overlay_with_gain_change" "notest_overlay_with_gain_change" - ''; - - checkInputs = [ scipy ffmpeg-full ]; + checkInputs = [ + ffmpeg-full + ]; checkPhase = '' - python test/test.py + ${python.interpreter} test/test.py ''; meta = with lib; { - description = "Manipulate audio with a simple and easy high level interface."; - homepage = "http://pydub.com/"; - license = licenses.mit; - platforms = platforms.all; + description = "Manipulate audio with a simple and easy high level interface"; + homepage = "http://pydub.com"; + license = licenses.mit; + maintainers = with maintainers; [ hexa ]; }; } |