1{
2 lib,
3 stdenv,
4 automat,
5 buildPythonPackage,
6 cryptography,
7 fetchPypi,
8 geoip,
9 idna,
10 incremental,
11 lsof,
12 mock,
13 pyopenssl,
14 pytestCheckHook,
15 python,
16 pythonOlder,
17 service-identity,
18 twisted,
19 zope-interface,
20}:
21
22buildPythonPackage rec {
23 pname = "txtorcon";
24 version = "23.11.0";
25 format = "setuptools";
26
27 disabled = pythonOlder "3.7";
28
29 src = fetchPypi {
30 inherit pname version;
31 hash = "sha256-cfha6T121yZRAFnJ7XTmCLxaXJ99EDhTtJ5BQoBAai8=";
32 };
33
34 propagatedBuildInputs = [
35 cryptography
36 incremental
37 twisted
38 automat
39 zope-interface
40 ] ++ twisted.optional-dependencies.tls;
41
42 nativeCheckInputs = [
43 pytestCheckHook
44 mock
45 lsof
46 geoip
47 ];
48
49 doCheck = !(stdenv.isDarwin && stdenv.isAarch64);
50
51 meta = with lib; {
52 description = "Twisted-based Tor controller client, with state-tracking and configuration abstractions";
53 homepage = "https://github.com/meejah/txtorcon";
54 changelog = "https://github.com/meejah/txtorcon/releases/tag/v${version}";
55 maintainers = with maintainers; [
56 jluttine
57 exarkun
58 ];
59 license = licenses.mit;
60 };
61}