Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 19 additions & 2 deletions pkgs/development/python-modules/smolagents/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
wikipedia-api,
}:

buildPythonPackage rec {
(buildPythonPackage rec {
pname = "smolagents";
version = "1.21.3";
pyproject = true;
Expand Down Expand Up @@ -122,6 +122,11 @@ buildPythonPackage rec {
# ];
});

# Split install checks to `passthru.tests.pytest-check`
# as it depends on `optional-dependencies`,
# which contains huge stuff like the GUI library `python3Packages.gradio`.
doCheck = false;

nativeCheckInputs = [
ipython
pytest-datadir
Expand Down Expand Up @@ -179,4 +184,16 @@ buildPythonPackage rec {
license = lib.licenses.asl20;
maintainers = with lib.maintainers; [ fab ];
};
}
}).overrideAttrs
(
finalAttrs: previousAttrs: {
passthru = previousAttrs.passthru // {
tests = previousAttrs.passthru.tests or { } // {
pytest-check = finalAttrs.overrideAttrs {
# buildPythonPackage maps doCheck to doInstallCheck.
doInstallCheck = true;
};
};
};
}
)
Loading