diff --git a/pkgs/development/python-modules/myjwt/default.nix b/pkgs/development/python-modules/myjwt/default.nix index d80e66e07bf0..0fecd439e3f5 100644 --- a/pkgs/development/python-modules/myjwt/default.nix +++ b/pkgs/development/python-modules/myjwt/default.nix @@ -1,33 +1,31 @@ { lib , stdenv , buildPythonPackage -, fetchFromGitHub , click , colorama , cryptography , exrex +, fetchFromGitHub , pyopenssl , pyperclip +, pytest-mock +, pytestCheckHook , questionary , requests -, pytestCheckHook -, pytest-mock , requests-mock }: buildPythonPackage rec { pname = "myjwt"; - version = "1.4.0"; + version = "1.5.0"; src = fetchFromGitHub { owner = "mBouamama"; repo = "MyJWT"; rev = version; - sha256 = "1n3lvdrzp6wbbcygjwa7xar2jnhjnrz7a9khmn2phhkkngxm5rc4"; + sha256 = "sha256-kZkqFeaQPd56BVaYmCWAbVu1xwbPAIlQC3u5/x3dh7A="; }; - patches = [ ./pinning.patch ]; - propagatedBuildInputs = [ click colorama @@ -40,15 +38,20 @@ buildPythonPackage rec { ]; checkInputs = [ - pytestCheckHook pytest-mock + pytestCheckHook requests-mock ]; + postPatch = '' + # Remove all version pinning (E.g., tornado==5.1.1 -> tornado) + sed -i -e "s/==[0-9.]*//" requirements.txt + ''; + pythonImportsCheck = [ "myjwt" ]; meta = with lib; { - description = "CLI tool for testing vulnerabilities on Json Web Token(JWT)"; + description = "CLI tool for testing vulnerabilities of JSON Web Tokens (JWT)"; homepage = "https://github.com/mBouamama/MyJWT"; license = with licenses; [ mit ]; maintainers = with maintainers; [ fab ]; diff --git a/pkgs/development/python-modules/myjwt/pinning.patch b/pkgs/development/python-modules/myjwt/pinning.patch deleted file mode 100644 index abae9d0e2ecb..000000000000 --- a/pkgs/development/python-modules/myjwt/pinning.patch +++ /dev/null @@ -1,21 +0,0 @@ -diff --git a/requirements.txt b/requirements.txt -index 3017e02..2b465db 100644 ---- a/requirements.txt -+++ b/requirements.txt -@@ -1,8 +1,8 @@ --click==7.1.2 --colorama==0.4.4 --cryptography==3.3.1 --exrex==0.10.5 --pyOpenSSL==20.0.1 --pyperclip==1.8.1 --questionary==1.9.0 --requests==2.25.1 -+click -+colorama -+cryptography -+exrex -+pyOpenSSL -+pyperclip -+questionary -+requests