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

python3Packages.pyjwt: Update various packaging details

- Use pyproject format
- Remove obsolete types-cryptography dependency
- Expose optional crypto dependencies
- Generate documentation

Unbreaks the django-allauth build.

authored by

Martin Weinelt and committed by
Martin Weinelt
750da022 8a59eec4

+23 -2
+23 -2
pkgs/development/python-modules/pyjwt/default.nix
··· 2 2 , buildPythonPackage 3 3 , fetchPypi 4 4 , cryptography 5 + , types-cryptography 5 6 , pytestCheckHook 6 7 , pythonOlder 8 + , sphinxHook 9 + , sphinx-rtd-theme 10 + , zope_interface 7 11 }: 8 12 9 13 buildPythonPackage rec { 10 14 pname = "pyjwt"; 11 15 version = "2.5.0"; 16 + format = "pyproject"; 17 + 12 18 disabled = pythonOlder "3.7"; 13 19 14 20 src = fetchPypi { ··· 23 17 sha256 = "sha256-53q4lICQXYaZhEKsV4jzUzP6hfZQR6U0rcOO3zyI/Ds="; 24 18 }; 25 19 26 - propagatedBuildInputs = [ 20 + postPatch = '' 21 + sed -i '/types-cryptography/d' setup.cfg 22 + ''; 23 + 24 + outputs = [ 25 + "out" 26 + "doc" 27 + ]; 28 + 29 + nativeBuildInputs = [ 30 + sphinxHook 31 + sphinx-rtd-theme 32 + zope_interface 33 + ]; 34 + 35 + passthru.optional-dependencies.crypto = [ 27 36 cryptography 28 37 ]; 29 38 30 39 checkInputs = [ 31 40 pytestCheckHook 32 - ]; 41 + ] ++ (lib.flatten (lib.attrValues passthru.optional-dependencies)); 33 42 34 43 pythonImportsCheck = [ "jwt" ]; 35 44