1{ lib
2, buildPythonPackage
3, fetchPypi
4, isPy3k
5, pytest
6, sphinx
7}:
8
9buildPythonPackage rec {
10 pname = "curio";
11 version = "0.9";
12
13 src = fetchPypi {
14 inherit pname version;
15 sha256 = "51d1a7b49b4f8dd1486ac785c72d522962e93ccfdcfc1f818f5c7553a307b5ef";
16 };
17
18 disabled = !isPy3k;
19
20 checkInputs = [ pytest sphinx ];
21
22 __darwinAllowLocalNetworking = true;
23
24 # test_aside_basic times out,
25 # test_aside_cancel fails because modifies PYTHONPATH and cant find pytest
26 checkPhase = ''
27 # __pycache__ was packaged accidentally, https://github.com/dabeaz/curio/issues/301
28 rm -r tests/__pycache__
29 pytest --deselect tests/test_task.py::test_aside_basic --deselect tests/test_task.py::test_aside_cancel
30 '';
31
32 meta = with lib; {
33 homepage = "https://github.com/dabeaz/curio";
34 description = "Library for performing concurrent I/O with coroutines in Python 3";
35 license = licenses.bsd3;
36 maintainers = [ maintainers.marsam ];
37 };
38}