at 23.05-pre 902 B view raw
1{ lib 2, buildPythonPackage 3, fetchPypi 4, pythonOlder 5, idna 6, multidict 7, typing-extensions 8, pytestCheckHook 9}: 10 11buildPythonPackage rec { 12 pname = "yarl"; 13 version = "1.8.1"; 14 15 src = fetchPypi { 16 inherit pname version; 17 sha256 = "sha256-r4h4RbjC4GDrVgX/crby3SqrenYTeTc/2J0xT0dSq78="; 18 }; 19 20 postPatch = '' 21 sed -i '/^addopts/d' setup.cfg 22 ''; 23 24 propagatedBuildInputs = [ 25 idna 26 multidict 27 ] ++ lib.optionals (pythonOlder "3.8") [ 28 typing-extensions 29 ]; 30 31 preCheck = '' 32 # don't import yarl from ./ so the C extension is available 33 pushd tests 34 ''; 35 36 checkInputs = [ 37 pytestCheckHook 38 ]; 39 40 postCheck = '' 41 popd 42 ''; 43 44 pythonImportsCheck = [ "yarl" ]; 45 46 meta = with lib; { 47 description = "Yet another URL library"; 48 homepage = "https://github.com/aio-libs/yarl"; 49 license = licenses.asl20; 50 maintainers = with maintainers; [ dotlambda ]; 51 }; 52}