diff options
Diffstat (limited to 'nixpkgs/pkgs/development/python-modules/asgiref')
-rw-r--r-- | nixpkgs/pkgs/development/python-modules/asgiref/default.nix | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/python-modules/asgiref/default.nix b/nixpkgs/pkgs/development/python-modules/asgiref/default.nix new file mode 100644 index 00000000000..e75be31c85f --- /dev/null +++ b/nixpkgs/pkgs/development/python-modules/asgiref/default.nix @@ -0,0 +1,29 @@ +{ stdenv, buildPythonPackage, pythonOlder, fetchFromGitHub, async-timeout, pytest, pytest-asyncio }: +buildPythonPackage rec { + version = "3.2.2"; + pname = "asgiref"; + + disabled = pythonOlder "3.5"; + + # PyPI tarball doesn't include tests directory + src = fetchFromGitHub { + owner = "django"; + repo = pname; + rev = version; + sha256 = "11lnynspgdi5zp3hd8piy8h9fq0s3ck6lzyl7h0fn2mxxyx83yh2"; + }; + + propagatedBuildInputs = [ async-timeout ]; + + checkInputs = [ pytest pytest-asyncio ]; + + checkPhase = '' + py.test + ''; + + meta = with stdenv.lib; { + description = "Reference ASGI adapters and channel layers"; + license = licenses.bsd3; + homepage = https://github.com/django/asgiref; + }; +} |