package: fix running pytest in a dev shell

I have no idea how seemingly I am the only one hitting this, but either
way, this fixes it.

Fixes: https://git.lix.systems/lix-project/lix/issues/964
Workaround-For: https://github.com/NixOS/nixpkgs/pull/435749
Change-Id: If2a7ad89f98f0054928868eabb62b35c2df28e6e
This commit is contained in:
Jade Lovelace
2025-09-11 19:15:51 +00:00
committed by Rutile
parent 95448347ea
commit b5cf7dff7b
+9 -2
View File
@@ -140,6 +140,13 @@ let
# This is for sys/sdt.h
dtrace-headers = if withDtrace then libsystemtap else null;
# FIXME(jade): can be removed once our nixpkgs has https://github.com/NixOS/nixpkgs/pull/435749 (probably 25.11?)
dontWrapPython =
drv:
drv.overridePythonAttrs (old: {
dontWrapPythonPrograms = true;
});
aws-sdk-cpp-nix =
if aws-sdk-cpp == null then
null
@@ -211,7 +218,7 @@ stdenv.mkDerivation (finalAttrs: {
p.pycapnp
]
++ lib.optionals finalAttrs.doCheck [
p.pytest
(dontWrapPython p.pytest)
p.pytest-xdist
p.ruff
p.aiohttp
@@ -526,7 +533,7 @@ stdenv.mkDerivation (finalAttrs: {
p: [
# FIXME: these have to be added twice due to the nix shell using a
# wrapped python instead of build inputs for its python inputs
p.pytest
(dontWrapPython p.pytest)
p.pytest-xdist
p.ruff
p.aiohttp