about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/starlette/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/python-modules/starlette/default.nix')
-rw-r--r--nixpkgs/pkgs/development/python-modules/starlette/default.nix51
1 files changed, 51 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/python-modules/starlette/default.nix b/nixpkgs/pkgs/development/python-modules/starlette/default.nix
new file mode 100644
index 000000000000..6e2bd8250b66
--- /dev/null
+++ b/nixpkgs/pkgs/development/python-modules/starlette/default.nix
@@ -0,0 +1,51 @@
+{ lib
+, buildPythonPackage
+, fetchPypi
+, aiofiles
+, graphene
+, itsdangerous
+, jinja2
+, pyyaml
+, requests
+, ujson
+, pytest
+, python
+, uvicorn
+, isPy27
+}:
+
+buildPythonPackage rec {
+  pname = "starlette";
+  version = "0.12.4";
+  disabled = isPy27;
+
+  src = fetchPypi {
+    inherit pname version;
+    sha256 = "1m7qf4g5dn7n36406zbqsag71nmwp2dz91yxpplm7h7wiw2xxw93";
+  };
+
+  propagatedBuildInputs = [
+    aiofiles
+    graphene
+    itsdangerous
+    jinja2
+    pyyaml
+    requests
+    ujson
+    uvicorn
+  ];
+
+  checkPhase = ''
+    ${python.interpreter} -c """
+from starlette.applications import Starlette
+app = Starlette(debug=True)
+"""
+  '';
+
+  meta = with lib; {
+    homepage = https://www.starlette.io/;
+    description = "The little ASGI framework that shines";
+    license = licenses.bsd3;
+    maintainers = with maintainers; [ wd15 ];
+  };
+}