python3.pkgs.nbclient: always disable tests

Overriding a Python package in propagatedBuildInputs is a bad idea as
you may end up with multiple versions in your closure. This happened,
and when installing to $out the package for which the tests were run,
the site packages folder was empty.

Possible improvement is to add the tests as a separate derivation.
main
Frederik Rietdijk 2 years ago committed by Kerstin
parent e006a2a2b9
commit ab0bd3aff9
  1. 3
      pkgs/development/python-modules/nbclient/default.nix
  2. 2
      pkgs/development/python-modules/nbconvert/default.nix

@ -1,7 +1,6 @@
{ lib, buildPythonPackage, fetchPypi, pythonOlder,
async_generator, traitlets, nbformat, nest-asyncio, jupyter-client,
pytest, xmltodict, nbconvert, ipywidgets
, doCheck ? true
}:
buildPythonPackage rec {
@ -14,7 +13,7 @@ buildPythonPackage rec {
sha256 = "sha256-QMUsm148MfrsruafICs/U+ONfBxWPeD63enX7aD9r+g=";
};
inherit doCheck;
doCheck = false; # Avoid infinite recursion
checkInputs = [ pytest xmltodict nbconvert ipywidgets ];
propagatedBuildInputs = [ async_generator traitlets nbformat nest-asyncio jupyter-client ];

@ -47,7 +47,7 @@ buildPythonPackage rec {
entrypoints bleach mistune jinja2 pygments traitlets testpath
jupyter_core nbformat ipykernel pandocfilters tornado jupyter-client
defusedxml beautifulsoup4
(nbclient.override { doCheck = false; }) # avoid infinite recursion
nbclient
jupyterlab-pygments
];

Loading…
Cancel
Save