diff --git a/pkgs/development/python-modules/napari-console/default.nix b/pkgs/development/python-modules/napari-console/default.nix new file mode 100644 index 000000000000..214553a9821e --- /dev/null +++ b/pkgs/development/python-modules/napari-console/default.nix @@ -0,0 +1,33 @@ +{ lib +, buildPythonPackage +, fetchFromGitHub +, setuptools_scm +, pytestCheckHook +, pytest +, ipython +, ipykernel +, qtconsole +, napari-plugin-engine +, imageio +}: buildPythonPackage rec { + pname = "napari-console"; + version = "0.0.4"; + src = fetchFromGitHub { + owner = "napari"; + repo = pname; + rev = "v${version}"; + sha256 = "sha256-aVdYOzkZ+dqB680oDjNCg6quXU+QgUZI09E/MSTagyA="; + }; + nativeBuildInputs = [ setuptools_scm ]; + # setup.py somehow requires pytest + propagatedBuildInputs = [ pytest ipython ipykernel napari-plugin-engine imageio qtconsole ]; + chechInputs = [ pytestCheckHook ]; + SETUPTOOLS_SCM_PRETEND_VERSION = version; + + meta = with lib; { + description = "A plugin that adds a console to napari"; + homepage = "https://github.com/napari/napari-console"; + license = licenses.bsd3; + maintainers = with maintainers; [ SomeoneSerge ]; + }; +} diff --git a/pkgs/development/python-modules/napari-plugin-engine/default.nix b/pkgs/development/python-modules/napari-plugin-engine/default.nix new file mode 100644 index 000000000000..a722786fb2fc --- /dev/null +++ b/pkgs/development/python-modules/napari-plugin-engine/default.nix @@ -0,0 +1,26 @@ +{ lib +, buildPythonPackage +, fetchFromGitHub +, setuptools_scm +, pytestCheckHook +}: buildPythonPackage rec { + pname = "napari-plugin-engine"; + version = "0.2.0"; + src = fetchFromGitHub { + owner = "napari"; + repo = pname; + rev = "v${version}"; + sha256 = "sha256-cKpCAEYYRq3UPje7REjzhEe1J9mmrtXs8TBnxWukcNE="; + }; + nativeBuildInputs = [ setuptools_scm ]; + checkInputs = [ pytestCheckHook ]; + doCheck = false; + SETUPTOOLS_SCM_PRETEND_VERSION = version; + + meta = with lib; { + description = "A fork of pluggy for napari - plugin management package"; + homepage = "https://github.com/napari/napari-plugin-engine"; + license = licenses.mit; + maintainers = with maintainers; [ SomeoneSerge ]; + }; +} diff --git a/pkgs/development/python-modules/napari-svg/default.nix b/pkgs/development/python-modules/napari-svg/default.nix new file mode 100644 index 000000000000..4df71b01084b --- /dev/null +++ b/pkgs/development/python-modules/napari-svg/default.nix @@ -0,0 +1,30 @@ +{ lib +, buildPythonPackage +, fetchFromGitHub +, setuptools_scm +, pytestCheckHook +, vispy +, napari-plugin-engine +, imageio +}: buildPythonPackage rec { + pname = "napari-svg"; + version = "0.1.5"; + src = fetchFromGitHub { + owner = "napari"; + repo = pname; + rev = "v${version}"; + sha256 = "sha256-20NLi6JTugP+hxqF2AnhSkuvhkGGbeG+tT3M2SZbtRc="; + }; + nativeBuildInputs = [ setuptools_scm ]; + propagatedBuildInputs = [ vispy napari-plugin-engine imageio ]; + checkInputs = [ pytestCheckHook ]; + doCheck = false; # Circular dependency: napari + SETUPTOOLS_SCM_PRETEND_VERSION = version; + + meta = with lib; { + description = "A plugin for writing svg files from napari"; + homepage = "https://github.com/napari/napari-svg"; + license = licenses.bsd3; + maintainers = with maintainers; [ SomeoneSerge ]; + }; +} diff --git a/pkgs/development/python-modules/napari/default.nix b/pkgs/development/python-modules/napari/default.nix new file mode 100644 index 000000000000..7cad250e1f6b --- /dev/null +++ b/pkgs/development/python-modules/napari/default.nix @@ -0,0 +1,75 @@ +{ lib +, mkDerivationWith +, buildPythonPackage +, fetchFromGitHub +, setuptools_scm +, superqt +, typing-extensions +, tifffile +, napari-plugin-engine +, pint +, pyyaml +, numpydoc +, dask +, magicgui +, docstring-parser +, appdirs +, imageio +, pyopengl +, cachey +, napari-svg +, psutil +, napari-console +, wrapt +, pydantic +, tqdm +, jsonschema +, scipy +, wrapQtAppsHook +}: mkDerivationWith buildPythonPackage rec { + pname = "napari"; + version = "0.4.12"; + src = fetchFromGitHub { + owner = "napari"; + repo = pname; + rev = "v${version}"; + sha256 = "sha256-0QSI0mgDjF70/X58fE7uWwlBUCGY5gsvbCm4oJkp2Yk="; + }; + nativeBuildInputs = [ setuptools_scm wrapQtAppsHook ]; + propagatedBuildInputs = [ + napari-plugin-engine + cachey + napari-svg + napari-console + superqt + magicgui + typing-extensions + tifffile + pint + pyyaml + numpydoc + dask + docstring-parser + appdirs + imageio + pyopengl + psutil + wrapt + pydantic + tqdm + jsonschema + scipy + ]; + SETUPTOOLS_SCM_PRETEND_VERSION = version; + dontUseSetuptoolsCheck = true; + postFixup = '' + wrapQtApp $out/bin/napari + ''; + + meta = with lib; { + description = "A fast, interactive, multi-dimensional image viewer for python"; + homepage = "https://github.com/napari/napari"; + license = licenses.bsd3; + maintainers = with maintainers; [ SomeoneSerge ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 76b8467a442f..707173f9781d 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -30110,6 +30110,8 @@ with pkgs; masari = callPackage ../applications/blockchains/masari { boost = boost165; }; + napari = with python3Packages; toPythonApplication napari; + nano-wallet = libsForQt5.callPackage ../applications/blockchains/nano-wallet { boost = boost172; }; diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index b9f7df414d6b..14c0df05c5f8 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -5208,6 +5208,16 @@ in { nanotime = callPackage ../development/python-modules/nanotime { }; + napari = callPackage ../development/python-modules/napari { + inherit (pkgs.libsForQt5) mkDerivationWith wrapQtAppsHook; + }; + + napari-console = callPackage ../development/python-modules/napari-console { }; + + napari-plugin-engine = callPackage ../development/python-modules/napari-plugin-engine { }; + + napari-svg = callPackage ../development/python-modules/napari-svg { }; + nassl = callPackage ../development/python-modules/nassl { }; nats-python = callPackage ../development/python-modules/nats-python { };