2022-04-15 01:41:22 +00:00
|
|
|
{ lib
|
2022-09-09 14:08:57 +00:00
|
|
|
, appdirs
|
|
|
|
, build
|
2022-04-15 01:41:22 +00:00
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, magicgui
|
|
|
|
, napari # reverse dependency, for tests
|
2022-09-09 14:08:57 +00:00
|
|
|
, psygnal
|
|
|
|
, pydantic
|
|
|
|
, pythonOlder
|
|
|
|
, pytomlpp
|
|
|
|
, pyyaml
|
|
|
|
, rich
|
|
|
|
, setuptools-scm
|
|
|
|
, typer
|
2022-04-15 01:41:22 +00:00
|
|
|
}:
|
|
|
|
|
2022-09-09 14:08:57 +00:00
|
|
|
buildPythonPackage rec {
|
2022-04-15 01:41:22 +00:00
|
|
|
pname = "napari-npe2";
|
2022-09-09 14:08:57 +00:00
|
|
|
version = "0.6.1";
|
2022-04-15 01:41:22 +00:00
|
|
|
|
|
|
|
format = "pyproject";
|
|
|
|
|
2022-09-09 14:08:57 +00:00
|
|
|
disabled = pythonOlder "3.8";
|
|
|
|
|
2022-04-15 01:41:22 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "napari";
|
|
|
|
repo = "npe2";
|
2022-08-12 12:06:08 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
2022-09-09 14:08:57 +00:00
|
|
|
hash = "sha256-1wGMd4box+ulHcEL4zoArJ3ez95s7GcbXa9bWfLbSCw=";
|
2022-04-15 01:41:22 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
SETUPTOOLS_SCM_PRETEND_VERSION = version;
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
# npe2 *can* build without it,
|
|
|
|
# but then setuptools refuses to acknowledge it when building napari
|
|
|
|
setuptools-scm
|
|
|
|
];
|
2022-09-09 14:08:57 +00:00
|
|
|
|
2022-04-15 01:41:22 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
appdirs
|
2022-09-09 14:08:57 +00:00
|
|
|
build
|
2022-04-15 01:41:22 +00:00
|
|
|
magicgui
|
2022-09-09 14:08:57 +00:00
|
|
|
pydantic
|
|
|
|
pytomlpp
|
|
|
|
pyyaml
|
|
|
|
rich
|
2022-04-15 01:41:22 +00:00
|
|
|
typer
|
|
|
|
];
|
|
|
|
|
2022-09-09 14:08:57 +00:00
|
|
|
pythonImportsCheck = [
|
|
|
|
"npe2"
|
|
|
|
];
|
|
|
|
|
2022-04-15 01:41:22 +00:00
|
|
|
passthru.tests = { inherit napari; };
|
|
|
|
|
|
|
|
meta = with lib; {
|
2022-09-09 14:08:57 +00:00
|
|
|
description = "Plugin system for napari (the image visualizer)";
|
2022-04-15 01:41:22 +00:00
|
|
|
homepage = "https://github.com/napari/npe2";
|
|
|
|
license = licenses.bsd3;
|
|
|
|
maintainers = with maintainers; [ SomeoneSerge ];
|
|
|
|
};
|
|
|
|
}
|