about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/streaming-form-data/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/python-modules/streaming-form-data/default.nix')
-rw-r--r--nixpkgs/pkgs/development/python-modules/streaming-form-data/default.nix13
1 files changed, 9 insertions, 4 deletions
diff --git a/nixpkgs/pkgs/development/python-modules/streaming-form-data/default.nix b/nixpkgs/pkgs/development/python-modules/streaming-form-data/default.nix
index 8c631510ec43..18df3a778da2 100644
--- a/nixpkgs/pkgs/development/python-modules/streaming-form-data/default.nix
+++ b/nixpkgs/pkgs/development/python-modules/streaming-form-data/default.nix
@@ -1,5 +1,5 @@
 { lib, fetchFromGitHub, buildPythonPackage, pythonOlder,
-cython, smart-open, pytestCheckHook, moto, requests-toolbelt }:
+cython, pytestCheckHook, requests-toolbelt }:
 
 buildPythonPackage rec {
   pname = "streaming-form-data";
@@ -14,11 +14,16 @@ buildPythonPackage rec {
     hash = "sha256-Ntiad5GZtfRd+2uDPgbDzLBzErGFroffK6ZAmMcsfXA=";
   };
 
-  nativeBuildInputs = [ cython ];
+  # streaming-form-data has a small bit of code that uses smart_open, which has a massive closure.
+  # The only consumer of streaming-form-data is Moonraker, which doesn't use that code.
+  # So, just drop the dependency to not have to deal with it.
+  patches = [
+    ./drop-smart-open.patch
+  ];
 
-  propagatedBuildInputs = [ smart-open ];
+  nativeBuildInputs = [ cython ];
 
-  nativeCheckInputs = [ pytestCheckHook moto requests-toolbelt ];
+  nativeCheckInputs = [ pytestCheckHook requests-toolbelt ];
 
   pytestFlagsArray = [ "tests" ];