Merge pull request #169302 from kfollesdal/httpie-ntlm

authored by Sandro and committed by GitHub 5eb5ae42 44414b48

+64 -40
+31
pkgs/development/python-modules/httpie-ntlm/default.nix
···
··· 1 + { lib 2 + , buildPythonPackage 3 + , fetchPypi 4 + , httpie 5 + , requests_ntlm 6 + }: 7 + 8 + buildPythonPackage rec { 9 + pname = "httpie-ntlm"; 10 + version = "1.0.2"; 11 + format = "setuptools"; 12 + 13 + src = fetchPypi { 14 + inherit pname version; 15 + sha256 = "b1f757180c0bd60741ea16cf91fc53d47df402a5c287c4a61a14b335ea0552b3"; 16 + }; 17 + 18 + propagatedBuildInputs = [ httpie requests_ntlm ]; 19 + 20 + # Package have no tests 21 + doCheck = false; 22 + 23 + pythonImportsCheck = [ "httpie_ntlm" ]; 24 + 25 + meta = with lib; { 26 + description = "NTLM auth plugin for HTTPie"; 27 + homepage = "https://github.com/httpie/httpie-ntlm"; 28 + license = licenses.bsdOriginal; 29 + maintainers = with maintainers; [ kfollesdal ]; 30 + }; 31 + }
+28 -17
pkgs/tools/networking/httpie/default.nix pkgs/development/python-modules/httpie/default.nix
··· 1 { lib 2 , fetchFromGitHub 3 , installShellFiles 4 - , python3 5 , pandoc 6 }: 7 8 - python3.pkgs.buildPythonApplication rec { 9 pname = "httpie"; 10 - version = "3.1.0"; 11 format = "setuptools"; 12 13 src = fetchFromGitHub { 14 owner = "httpie"; 15 repo = "httpie"; 16 rev = version; 17 - hash = "sha256-x7Zucb2i8D4Xbn77eBzSxOAcc2fGg5MFKFiyJhytQ0s="; 18 }; 19 20 nativeBuildInputs = [ ··· 22 pandoc 23 ]; 24 25 - propagatedBuildInputs = with python3.pkgs; [ 26 charset-normalizer 27 defusedxml 28 multidict ··· 30 requests 31 requests-toolbelt 32 setuptools 33 ]; 34 35 - checkInputs = with python3.pkgs; [ 36 - mock 37 - pytest 38 pytest-httpbin 39 pytest-lazy-fixture 40 pytestCheckHook 41 responses 42 ]; 43 44 postInstall = '' ··· 56 pytestFlagsArray = [ 57 "httpie" 58 "tests" 59 - ]; 60 - 61 - disabledTests = [ 62 - "test_chunked" 63 - "test_verbose_chunked" 64 - "test_multipart_chunked" 65 - "test_request_body_from_file_by_path_chunked" 66 - # Part of doctest 67 - "httpie.encoding.detect_encoding" 68 ]; 69 70 pythonImportsCheck = [
··· 1 { lib 2 + , buildPythonPackage 3 , fetchFromGitHub 4 , installShellFiles 5 , pandoc 6 + , pythonOlder 7 + # BuildInputs 8 + , charset-normalizer 9 + , defusedxml 10 + , multidict 11 + , pygments 12 + , requests 13 + , requests-toolbelt 14 + , setuptools 15 + , rich 16 + , pysocks 17 + # CheckInputs 18 + , pytest-httpbin 19 + , pytest-lazy-fixture 20 + , pytest-mock 21 + , pytestCheckHook 22 + , responses 23 + , werkzeug 24 }: 25 26 + buildPythonPackage rec { 27 pname = "httpie"; 28 + version = "3.2.1"; 29 format = "setuptools"; 30 31 src = fetchFromGitHub { 32 owner = "httpie"; 33 repo = "httpie"; 34 rev = version; 35 + hash = "sha256-WEe8zSlNckl7bPBi6u8mHQ1/xPw3kE81F8Xr15TchgM="; 36 }; 37 38 nativeBuildInputs = [ ··· 40 pandoc 41 ]; 42 43 + propagatedBuildInputs = [ 44 charset-normalizer 45 defusedxml 46 multidict ··· 48 requests 49 requests-toolbelt 50 setuptools 51 + rich 52 + pysocks 53 ]; 54 55 + checkInputs = [ 56 pytest-httpbin 57 pytest-lazy-fixture 58 + pytest-mock 59 pytestCheckHook 60 responses 61 + werkzeug 62 ]; 63 64 postInstall = '' ··· 76 pytestFlagsArray = [ 77 "httpie" 78 "tests" 79 ]; 80 81 pythonImportsCheck = [
-22
pkgs/tools/networking/httpie/strip-venv.patch
··· 1 - diff --git a/tests/test_docs.py b/tests/test_docs.py 2 - index 340e64d..a6b4dc9 100644 3 - --- a/tests/test_docs.py 4 - +++ b/tests/test_docs.py 5 - @@ -42,15 +42,10 @@ assert filenames 6 - # HACK: hardcoded paths, venv should be irrelevant, etc. 7 - # TODO: simplify by using the Python API instead of a subprocess 8 - # then we wont’t need the paths. 9 - -VENV_BIN = Path(__file__).parent.parent / 'venv/bin' 10 - -VENV_PYTHON = VENV_BIN / 'python' 11 - -VENV_RST2PSEUDOXML = VENV_BIN / 'rst2pseudoxml.py' 12 - +VENV_PYTHON = 'python' 13 - +VENV_RST2PSEUDOXML = 'rst2pseudoxml.py' 14 - 15 - 16 - -@pytest.mark.skipif( 17 - - not VENV_RST2PSEUDOXML.exists(), 18 - - reason='docutils not installed', 19 - -) 20 - @pytest.mark.parametrize('filename', filenames) 21 - def test_rst_file_syntax(filename): 22 - p = subprocess.Popen(
···
+1 -1
pkgs/top-level/all-packages.nix
··· 6968 6969 httpdump = callPackage ../tools/security/httpdump { }; 6970 6971 - httpie = callPackage ../tools/networking/httpie { }; 6972 6973 httping = callPackage ../tools/networking/httping {}; 6974
··· 6968 6969 httpdump = callPackage ../tools/security/httpdump { }; 6970 6971 + httpie = with python3Packages; toPythonApplication httpie; 6972 6973 httping = callPackage ../tools/networking/httping {}; 6974
+4
pkgs/top-level/python-packages.nix
··· 3939 3940 httpcore = callPackage ../development/python-modules/httpcore { }; 3941 3942 http-ece = callPackage ../development/python-modules/http-ece { }; 3943 3944 httplib2 = callPackage ../development/python-modules/httplib2 { }; 3945
··· 3939 3940 httpcore = callPackage ../development/python-modules/httpcore { }; 3941 3942 + httpie = callPackage ../development/python-modules/httpie { }; 3943 + 3944 http-ece = callPackage ../development/python-modules/http-ece { }; 3945 + 3946 + httpie-ntlm = callPackage ../development/python-modules/httpie-ntlm { }; 3947 3948 httplib2 = callPackage ../development/python-modules/httplib2 { }; 3949