From e2fee0d48b01f91df3c9e872e6efdb13131750ee Mon Sep 17 00:00:00 2001 From: natsukium Date: Sat, 10 May 2025 15:26:34 +0900 Subject: [PATCH] python3Packages.jupyterlab-git: refactor --- .../python-modules/jupyterlab-git/default.nix | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/pkgs/development/python-modules/jupyterlab-git/default.nix b/pkgs/development/python-modules/jupyterlab-git/default.nix index eced578e768b..a2f392c30210 100644 --- a/pkgs/development/python-modules/jupyterlab-git/default.nix +++ b/pkgs/development/python-modules/jupyterlab-git/default.nix @@ -3,6 +3,7 @@ buildPythonPackage, fetchPypi, git, + writableTmpDirAsHomeHook, jupyter-server, hatch-jupyter-builder, hatch-nodejs-version, @@ -10,12 +11,12 @@ jupyterlab, nbdime, nbformat, + packaging, pexpect, pytest-asyncio, pytest-jupyter, pytest-tornasync, pytestCheckHook, - pythonOlder, traitlets, }: @@ -24,7 +25,6 @@ buildPythonPackage rec { version = "0.51.1"; pyproject = true; - disabled = pythonOlder "3.8"; src = fetchPypi { pname = "jupyterlab_git"; @@ -32,34 +32,33 @@ buildPythonPackage rec { hash = "sha256-t7zol5XVzojIqvDXnrepPQU1Yi+b5rAZyprk07mpymo="; }; - nativeBuildInputs = [ + build-system = [ hatch-jupyter-builder hatch-nodejs-version hatchling jupyterlab ]; - propagatedBuildInputs = [ + dependencies = [ jupyter-server nbdime - git nbformat + packaging pexpect traitlets ]; + propagatedBuildInputs = [ git ]; + nativeCheckInputs = [ jupyterlab pytest-asyncio pytest-jupyter pytest-tornasync pytestCheckHook + writableTmpDirAsHomeHook ]; - preCheck = '' - export HOME=$TMPDIR - ''; - disabledTestPaths = [ "jupyterlab_git/tests/test_handlers.py" # PyPI doesn't ship all required files for the tests