1{ lib 2, buildPythonPackage 3, fetchFromGitHub 4, fetchpatch 5, pytestCheckHook 6, pythonOlder 7, setuptools 8, wheel 9}: 10 11buildPythonPackage rec { 12 pname = "wheel-filename"; 13 version = "1.4.1"; 14 format = "pyproject"; 15 16 disabled = pythonOlder "3.6"; 17 18 src = fetchFromGitHub { 19 owner = "jwodder"; 20 repo = pname; 21 rev = "v${version}"; 22 hash = "sha256-M3XGHG733X5qKuMS6mvFSFHYOwWPaBMXw+w0eYo6ByE="; 23 }; 24 25 patches = [ 26 (fetchpatch { 27 name = "remove-wheel-dependency-constraint.patch"; 28 url = "https://github.com/jwodder/wheel-filename/commit/11cfa57c8a32fa2a52fb5fe537859997bb642e75.patch"; 29 hash = "sha256-ssePCVlJuHPJpPyFET3FnnWRlslLnZbnfn42g52yVN4="; 30 }) 31 ]; 32 33 nativeBuildInputs = [ 34 setuptools 35 wheel 36 ]; 37 38 nativeCheckInputs = [ 39 pytestCheckHook 40 ]; 41 42 postPatch = '' 43 substituteInPlace tox.ini \ 44 --replace " --cov=wheel_filename --no-cov-on-fail" "" 45 ''; 46 47 pythonImportsCheck = [ 48 "wheel_filename" 49 ]; 50 51 meta = with lib; { 52 description = "Parse wheel filenames"; 53 homepage = "https://github.com/jwodder/wheel-filename"; 54 license = with licenses; [ mit ]; 55 maintainers = with lib.maintainers; [ ayazhafiz ]; 56 }; 57}