1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 pytestCheckHook,
6 pythonOlder,
7 setuptools,
8 typing-extensions,
9}:
10
11buildPythonPackage rec {
12 pname = "duet";
13 version = "0.2.9";
14 pyproject = true;
15
16 disabled = pythonOlder "3.10";
17
18 src = fetchFromGitHub {
19 owner = "google";
20 repo = "duet";
21 tag = "v${version}";
22 hash = "sha256-P7JxUigD7ZyhtocV+YuAVxuUYVa4F7PpXuA1CCmcMvg=";
23 };
24
25 build-system = [ setuptools ];
26
27 dependencies = [ typing-extensions ];
28
29 nativeCheckInputs = [ pytestCheckHook ];
30
31 pythonImportsCheck = [ "duet" ];
32
33 disabledTests = [
34 # test fails because builder is too busy and cannot finish quickly enough
35 "test_repeated_sleep"
36 ];
37
38 meta = with lib; {
39 description = "Simple future-based async library for python";
40 homepage = "https://github.com/google/duet";
41 maintainers = with maintainers; [ drewrisinger ];
42 };
43}