nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at 22.05 52 lines 1.1 kB view raw
1{ lib 2, buildPythonPackage 3, fetchPypi 4, oauthlib 5, pyjwt 6, pythonOlder 7, requests 8, requests-oauthlib 9, six 10}: 11 12buildPythonPackage rec { 13 pname = "mwoauth"; 14 version = "0.3.7"; 15 format = "setuptools"; 16 17 disabled = pythonOlder "3.7"; 18 19 src = fetchPypi { 20 inherit pname version; 21 hash = "sha256-ng1wofpvRSWE3hy4U65sEfQSM1SfeDnPuHn5lBD2rUY="; 22 }; 23 24 propagatedBuildInputs = [ 25 oauthlib 26 pyjwt 27 requests 28 requests-oauthlib 29 six 30 ]; 31 32 postPatch = '' 33 # https://github.com/mediawiki-utilities/python-mwoauth/pull/43 34 substituteInPlace setup.py \ 35 --replace "PyJWT>=1.0.1,<2.0.0" "PyJWT>=1.0.1" 36 ''; 37 38 # PyPI source has no tests included 39 # https://github.com/mediawiki-utilities/python-mwoauth/issues/44 40 doCheck = false; 41 42 pythonImportsCheck = [ 43 "mwoauth" 44 ]; 45 46 meta = with lib; { 47 description = "Python library to perform OAuth handshakes with a MediaWiki installation"; 48 homepage = "https://github.com/mediawiki-utilities/python-mwoauth"; 49 license = licenses.mit; 50 maintainers = with maintainers; [ ixxie ]; 51 }; 52}