Merge pull request #113948 from fabaff/bump-mitmproxy
mitmproxy: 5.3.0 -> 6.0.2
This commit is contained in:
commit
25c7c6ac31
|
@ -1,21 +1,25 @@
|
||||||
{ lib, stdenv
|
{ lib
|
||||||
|
, stdenv
|
||||||
, fetchFromGitHub
|
, fetchFromGitHub
|
||||||
, buildPythonPackage
|
, buildPythonPackage
|
||||||
, isPy27
|
, pythonOlder
|
||||||
, fetchpatch
|
# Mitmproxy requirements
|
||||||
# Mitmproxy requirements
|
, asgiref
|
||||||
, blinker
|
, blinker
|
||||||
, brotli
|
, brotli
|
||||||
, certifi
|
, certifi
|
||||||
, click
|
, click
|
||||||
, cryptography
|
, cryptography
|
||||||
, flask
|
, flask
|
||||||
|
, h11
|
||||||
, h2
|
, h2
|
||||||
, hyperframe
|
, hyperframe
|
||||||
, kaitaistruct
|
, kaitaistruct
|
||||||
, ldap3
|
, ldap3
|
||||||
|
, msgpack
|
||||||
, passlib
|
, passlib
|
||||||
, protobuf
|
, protobuf
|
||||||
|
, publicsuffix2
|
||||||
, pyasn1
|
, pyasn1
|
||||||
, pyopenssl
|
, pyopenssl
|
||||||
, pyparsing
|
, pyparsing
|
||||||
|
@ -26,45 +30,31 @@
|
||||||
, tornado
|
, tornado
|
||||||
, urwid
|
, urwid
|
||||||
, wsproto
|
, wsproto
|
||||||
, publicsuffix2
|
|
||||||
, zstandard
|
, zstandard
|
||||||
# Additional check requirements
|
# Additional check requirements
|
||||||
, beautifulsoup4
|
, beautifulsoup4
|
||||||
, glibcLocales
|
, glibcLocales
|
||||||
, pytest
|
, hypothesis
|
||||||
, requests
|
|
||||||
, asynctest
|
|
||||||
, parver
|
, parver
|
||||||
, pytest-asyncio
|
, pytest-asyncio
|
||||||
, hypothesis
|
, pytest-timeout
|
||||||
, asgiref
|
, pytest-xdist
|
||||||
, msgpack
|
, pytestCheckHook
|
||||||
|
, requests
|
||||||
}:
|
}:
|
||||||
|
|
||||||
buildPythonPackage rec {
|
buildPythonPackage rec {
|
||||||
pname = "mitmproxy";
|
pname = "mitmproxy";
|
||||||
version = "5.3.0";
|
version = "6.0.2";
|
||||||
disabled = isPy27;
|
disabled = pythonOlder "3.8";
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
owner = pname;
|
owner = pname;
|
||||||
repo = pname;
|
repo = pname;
|
||||||
rev = "v${version}";
|
rev = "v${version}";
|
||||||
sha256 = "04y7fxxssrs14i7zl7fwlwrpnms39i7a6m18481sg8vlrkbagxjr";
|
sha256 = "sha256-FyIZKFQtf6qvwo4+NzPa/KOmBCcdGJ3jCqxz26+S2e4=";
|
||||||
};
|
};
|
||||||
|
|
||||||
postPatch = ''
|
|
||||||
# remove dependency constraints
|
|
||||||
sed 's/>=\([0-9]\.\?\)\+\( \?, \?<\([0-9]\.\?\)\+\)\?\( \?, \?!=\([0-9]\.\?\)\+\)\?//' -i setup.py
|
|
||||||
'';
|
|
||||||
|
|
||||||
doCheck = (!stdenv.isDarwin);
|
|
||||||
|
|
||||||
checkPhase = ''
|
|
||||||
export HOME=$(mktemp -d)
|
|
||||||
pytest -k 'not test_get_version' # expects a Git repository
|
|
||||||
'';
|
|
||||||
|
|
||||||
propagatedBuildInputs = [
|
propagatedBuildInputs = [
|
||||||
setuptools
|
setuptools
|
||||||
# setup.py
|
# setup.py
|
||||||
|
@ -75,6 +65,7 @@ buildPythonPackage rec {
|
||||||
click
|
click
|
||||||
cryptography
|
cryptography
|
||||||
flask
|
flask
|
||||||
|
h11
|
||||||
h2
|
h2
|
||||||
hyperframe
|
hyperframe
|
||||||
kaitaistruct
|
kaitaistruct
|
||||||
|
@ -96,21 +87,39 @@ buildPythonPackage rec {
|
||||||
];
|
];
|
||||||
|
|
||||||
checkInputs = [
|
checkInputs = [
|
||||||
asynctest
|
|
||||||
beautifulsoup4
|
beautifulsoup4
|
||||||
flask
|
|
||||||
glibcLocales
|
glibcLocales
|
||||||
hypothesis
|
hypothesis
|
||||||
parver
|
parver
|
||||||
pytest
|
|
||||||
pytest-asyncio
|
pytest-asyncio
|
||||||
|
pytest-timeout
|
||||||
|
pytest-xdist
|
||||||
|
pytestCheckHook
|
||||||
requests
|
requests
|
||||||
];
|
];
|
||||||
|
|
||||||
|
doCheck = !stdenv.isDarwin;
|
||||||
|
|
||||||
|
postPatch = ''
|
||||||
|
# remove dependency constraints
|
||||||
|
sed 's/>=\([0-9]\.\?\)\+\( \?, \?<\([0-9]\.\?\)\+\)\?\( \?, \?!=\([0-9]\.\?\)\+\)\?//' -i setup.py
|
||||||
|
'';
|
||||||
|
|
||||||
|
preCheck = ''
|
||||||
|
export HOME=$(mktemp -d)
|
||||||
|
'';
|
||||||
|
|
||||||
|
disabledTests = [
|
||||||
|
# Tests require a git repository
|
||||||
|
"test_get_version"
|
||||||
|
];
|
||||||
|
|
||||||
|
pythonImportsCheck = [ "mitmproxy" ];
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
description = "Man-in-the-middle proxy";
|
description = "Man-in-the-middle proxy";
|
||||||
homepage = "https://mitmproxy.org/";
|
homepage = "https://mitmproxy.org/";
|
||||||
license = licenses.mit;
|
license = licenses.mit;
|
||||||
maintainers = with maintainers; [ fpletz kamilchm ];
|
maintainers = with maintainers; [ fpletz kamilchm ];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue