1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
|
{
lib,
async-timeout,
buildPythonPackage,
curio,
fetchFromGitHub,
anyio,
flask,
pytest-asyncio,
pytest-trio,
pythonOlder,
pytestCheckHook,
setuptools,
trio,
trustme,
yarl,
}:
buildPythonPackage rec {
pname = "python-socks";
version = "2.7.1";
pyproject = true;
disabled = pythonOlder "3.6.2";
__darwinAllowLocalNetworking = true;
src = fetchFromGitHub {
owner = "romis2012";
repo = "python-socks";
tag = "v${version}";
hash = "sha256-7BfdyQDfRIPSC3Iv+cDcR0VFHX+l1OPRMElzHGL2x3M=";
};
build-system = [ setuptools ];
dependencies = [
trio
curio
async-timeout
];
optional-dependencies = {
asyncio = lib.optionals (pythonOlder "3.11") [ async-timeout ];
trio = [ trio ];
curio = [ curio ];
anyio = [ anyio ];
};
doCheck = false; # requires tiny_proxy module
nativeCheckInputs = [
anyio
flask
pytest-asyncio
pytest-trio
pytestCheckHook
trustme
yarl
];
pythonImportsCheck = [ "python_socks" ];
meta = with lib; {
changelog = "https://github.com/romis2012/python-socks/releases/tag/${src.tag}";
description = "Core proxy client (SOCKS4, SOCKS5, HTTP) functionality for Python";
homepage = "https://github.com/romis2012/python-socks";
license = licenses.asl20;
maintainers = [ ];
};
}
|