From 45b1b9dcad0b5fb97124239f8d9e12f821d6754a Mon Sep 17 00:00:00 2001 From: Frederik Rietdijk Date: Tue, 29 Oct 2019 14:44:21 +0100 Subject: [PATCH] home-assistant: move cryptography fix to correct place fixup after f1d46d094a19e57dd0b20193ace5a51479285a3c --- pkgs/servers/home-assistant/default.nix | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/pkgs/servers/home-assistant/default.nix b/pkgs/servers/home-assistant/default.nix index 6761c23832a3..e1dd143010ee 100644 --- a/pkgs/servers/home-assistant/default.nix +++ b/pkgs/servers/home-assistant/default.nix @@ -11,13 +11,7 @@ # Applied after defaultOverrides , packageOverrides ? self: super: { # TODO: Remove this override after updating to cryptography 2.8: - cryptography = super.cryptography.overridePythonAttrs (oldAttrs: { - propagatedBuildInputs = oldAttrs.propagatedBuildInputs ++ [ super.asn1crypto ]; - patches = [ (fetchpatch { - url = "https://github.com/pyca/cryptography/commit/e575e3d482f976c4a1f3203d63ea0f5007a49a2a.patch"; - sha256 = "0vg9prqsizd6gzh5j7lscsfxzxlhz7pacvzhgqmj1vhdhjwbblcp"; - }) ]; - }); + } # Skip pip install of required packages on startup @@ -39,7 +33,7 @@ let "0b0069c752ec14172c5f78208f1863d7ad6755a6fae6fe76ec2c80d13be41e42") (mkOverride "pyjwt" "1.7.1" "8d59a976fb773f3e6a39c85636357c4f0e242707394cadadd9814f5cbaa20e96") - (mkOverride "cryptography" "2.7" # TODO for 2.8: Remove the override above + (mkOverride "cryptography" "2.7" # TODO for 2.8: Remove the override below "e6347742ac8f35ded4a46ff835c60e68c22a536a8ae5c4422966d06946b6d4c6") (mkOverride "cryptography_vectors" "2.7" # required by cryptography==2.7 "f12dfb9bd669a68004074cb5b26df6e93ed1a95ebd1a999dff0a840212ff68bc") @@ -74,6 +68,19 @@ let }; }) + (self: super: { + # TODO: Remove this override after updating to cryptography 2.8 + cryptography = super.cryptography.overridePythonAttrs (oldAttrs: { + propagatedBuildInputs = oldAttrs.propagatedBuildInputs ++ [ super.asn1crypto ]; + patches = [ + (fetchpatch { + url = "https://github.com/pyca/cryptography/commit/e575e3d482f976c4a1f3203d63ea0f5007a49a2a.patch"; + sha256 = "0vg9prqsizd6gzh5j7lscsfxzxlhz7pacvzhgqmj1vhdhjwbblcp"; + }) + ]; + }); + }) + # hass-frontend does not exist in python3.pkgs (self: super: { hass-frontend = self.callPackage ./frontend.nix { };