blob: 625e2e91d37b09b827d19abbd63bc412010714d5 (
plain)
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
|
{
lib,
buildPythonPackage,
fetchFromGitHub,
# build-system
setuptools,
# dependencies
flatbencode,
# test
pytest-cov-stub,
pytest-httpserver,
pytest-mock,
pytest-xdist,
pytestCheckHook,
}:
buildPythonPackage (finalAttrs: {
pname = "torf";
version = "4.3.0";
pyproject = true;
src = fetchFromGitHub {
owner = "rndusr";
repo = "torf";
tag = "v${finalAttrs.version}";
hash = "sha256-vJapB4Tbn3tLLUIH9LemU9kTqG7TsByiotkWM52lsno=";
};
build-system = [
setuptools
];
dependencies = [
flatbencode
];
nativeCheckInputs = [
pytest-cov-stub
pytest-httpserver
pytest-mock
pytest-xdist
pytestCheckHook
];
disabledTests = [
# Those tests fail DNS resolution in the sandbox
"test_getting_info__xs_fails__as_fails"
"test_getting_info__xs_returns_invalid_bytes"
"test_getting_info__as_returns_invalid_bytes"
"test_file_in_singlefile_torrent_has_wrong_size"
"test_file_in_singlefile_torrent_doesnt_exist"
# Broken assertion
# AssertionError: assert 1000 < 1000
"test_callback_raises_exception"
];
pythonImportsCheck = [ "torf" ];
__darwinAllowLocalNetworking = true;
meta = {
description = "Create, parse and edit torrent files and magnet links";
homepage = "https://github.com/rndusr/torf";
license = lib.licenses.gpl3Plus;
maintainers = with lib.maintainers; [ ambroisie ];
};
})
|