From f12241311f3dfdc153de7f844237e3c2c81c7fde Mon Sep 17 00:00:00 2001 From: Mel Bourgeois Date: Fri, 3 May 2024 13:59:32 -0500 Subject: [PATCH] overrides: fix pytest-django wheel build --- overrides/default.nix | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/overrides/default.nix b/overrides/default.nix index ac38f68..c0367ab 100644 --- a/overrides/default.nix +++ b/overrides/default.nix @@ -2803,8 +2803,11 @@ lib.composeManyExtensions [ pytest-django = prev.pytest-django.overridePythonAttrs ( _old: { postPatch = '' - substituteInPlace setup.py --replace "'pytest>=3.6'," "" - substituteInPlace setup.py --replace "'pytest>=3.6'" "" + # sometimes setup.py doesn't exist + if [ -f setup.py ]; then + substituteInPlace setup.py --replace "'pytest>=3.6'," "" + substituteInPlace setup.py --replace "'pytest>=3.6'" "" + fi ''; } );