From ffebc623e90669810d5dce424cdbc65146eb810c Mon Sep 17 00:00:00 2001 From: Daniel Wheeler Date: Fri, 28 Feb 2020 11:17:48 -0500 Subject: [PATCH] python37Packages.starlette: 0.13.0 -> 0.12.9 - Reverting the version of Starlette as FastAPI can not use anything greater than 0.12.12. FastAPI is Starlette's only dependent. - Use fetchurl instead of fetchPypi as this is now the preferred method. This also makes the tests pass and, thus, the build, which was failing. --- .../python-modules/starlette/default.nix | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/pkgs/development/python-modules/starlette/default.nix b/pkgs/development/python-modules/starlette/default.nix index a2170db1bd4..a6d93465ffc 100644 --- a/pkgs/development/python-modules/starlette/default.nix +++ b/pkgs/development/python-modules/starlette/default.nix @@ -1,7 +1,7 @@ { lib , stdenv , buildPythonPackage -, fetchPypi +, fetchFromGitHub , aiofiles , graphene , itsdangerous @@ -20,12 +20,20 @@ buildPythonPackage rec { pname = "starlette"; - version = "0.13.0"; + + # This is not the latest version of Starlette, however, later + # versions of Starlette break FastAPI due to + # https://github.com/tiangolo/fastapi/issues/683. Please update when + # possible. FastAPI is currently Starlette's only dependent. + + version = "0.12.9"; disabled = isPy27; - src = fetchPypi { - inherit pname version; - sha256 = "6bd414152d40d000ccbf6aa40ed89718b40868366a0f69fb83034f416303acef"; + src = fetchFromGitHub { + owner = "encode"; + repo = pname; + rev = version; + sha256 = "0w44s8ynzy8w8dgm755c8jina9i4dd87vqkcv7jc1kwkg384w9i5"; }; propagatedBuildInputs = [