From 2e87eb6c8fff602dc1a2fa644944fe67db78a790 Mon Sep 17 00:00:00 2001 From: Morgan Helton Date: Sat, 19 Apr 2025 08:27:54 -0500 Subject: [PATCH] python3Packages.flask-limiter: fix building with latest rich --- .../development/python-modules/flask-limiter/default.nix | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/pkgs/development/python-modules/flask-limiter/default.nix b/pkgs/development/python-modules/flask-limiter/default.nix index 85a977d01eb0..e86cddce2f5d 100644 --- a/pkgs/development/python-modules/flask-limiter/default.nix +++ b/pkgs/development/python-modules/flask-limiter/default.nix @@ -3,6 +3,7 @@ asgiref, buildPythonPackage, fetchFromGitHub, + fetchpatch, flask, hiro, limits, @@ -33,6 +34,14 @@ buildPythonPackage rec { hash = "sha256-3GFbLQExd4c3Cyr7UDX/zOAfedOluXMwCbBhOgoKfn0="; }; + patches = [ + # permit use of rich < 15 -- remove when updating past 3.12 + (fetchpatch { + url = "https://github.com/alisaifee/flask-limiter/commit/008a5c89f249e18e5375f16d79efc3ac518e9bcc.patch"; + hash = "sha256-dvTPVnuPs7xCRfUBBA1bgeWGuevFUZ+Kgl9MBHdgfKU="; + }) + ]; + postPatch = '' # flask-restful is unmaintained and breaks regularly, don't depend on it substituteInPlace tests/test_views.py \