mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-23 07:23:20 +00:00
napari: fix after the transition to pyproject.toml
This commit is contained in:
parent
764c88feac
commit
e9e76773ef
@ -9,20 +9,29 @@
|
||||
, pyside2
|
||||
, psygnal
|
||||
, docstring-parser
|
||||
, napari # a reverse-dependency, for tests
|
||||
}: buildPythonPackage rec {
|
||||
pname = "magicgui";
|
||||
version = "0.3.7";
|
||||
|
||||
format = "pyproject";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "napari";
|
||||
repo = "magicgui";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-LYXNNr5lS3ibQk2NIopZkB8kzC7j3yY8moGMk0Gr+hU=";
|
||||
};
|
||||
|
||||
SETUPTOOLS_SCM_PRETEND_VERSION = version;
|
||||
|
||||
nativeBuildInputs = [ setuptools-scm ];
|
||||
propagatedBuildInputs = [ typing-extensions qtpy pyside2 psygnal docstring-parser ];
|
||||
checkInputs = [ pytestCheckHook pytest-mypy-plugins ];
|
||||
|
||||
doCheck = false; # Reports "Fatal Python error"
|
||||
SETUPTOOLS_SCM_PRETEND_VERSION = version;
|
||||
|
||||
passthru.tests = { inherit napari; };
|
||||
|
||||
meta = with lib; {
|
||||
description = "Build GUIs from python functions, using magic. (napari/magicgui)";
|
||||
|
54
pkgs/development/python-modules/napari-npe2/default.nix
Normal file
54
pkgs/development/python-modules/napari-npe2/default.nix
Normal file
@ -0,0 +1,54 @@
|
||||
{ lib
|
||||
, buildPythonPackage
|
||||
, fetchFromGitHub
|
||||
, appdirs
|
||||
, pyyaml
|
||||
, pytomlpp
|
||||
, pydantic
|
||||
, magicgui
|
||||
, typer
|
||||
, setuptools-scm
|
||||
, napari # reverse dependency, for tests
|
||||
}:
|
||||
|
||||
let
|
||||
pname = "napari-npe2";
|
||||
version = "0.3.0";
|
||||
in
|
||||
buildPythonPackage {
|
||||
inherit pname version;
|
||||
|
||||
format = "pyproject";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "napari";
|
||||
repo = "npe2";
|
||||
rev = "v${version}";
|
||||
hash = "sha256-IyDUeztWQ8JWXDo//76iHzAlWWaZP6/0lwCh0eZAZsM=";
|
||||
};
|
||||
|
||||
SETUPTOOLS_SCM_PRETEND_VERSION = version;
|
||||
|
||||
nativeBuildInputs = [
|
||||
# npe2 *can* build without it,
|
||||
# but then setuptools refuses to acknowledge it when building napari
|
||||
setuptools-scm
|
||||
];
|
||||
propagatedBuildInputs = [
|
||||
appdirs
|
||||
pyyaml
|
||||
pytomlpp
|
||||
pydantic
|
||||
magicgui
|
||||
typer
|
||||
];
|
||||
|
||||
passthru.tests = { inherit napari; };
|
||||
|
||||
meta = with lib; {
|
||||
description = "Yet another plugin system for napari (the image visualizer)";
|
||||
homepage = "https://github.com/napari/npe2";
|
||||
license = licenses.bsd3;
|
||||
maintainers = with maintainers; [ SomeoneSerge ];
|
||||
};
|
||||
}
|
@ -6,7 +6,7 @@
|
||||
, superqt
|
||||
, typing-extensions
|
||||
, tifffile
|
||||
, napari-plugin-engine
|
||||
, napari-npe2
|
||||
, pint
|
||||
, pyyaml
|
||||
, numpydoc
|
||||
@ -29,15 +29,24 @@
|
||||
}: mkDerivationWith buildPythonPackage rec {
|
||||
pname = "napari";
|
||||
version = "0.4.14";
|
||||
|
||||
format = "pyproject";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "napari";
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-uDDj5dzsT4tRVV0Y+CYegiCpLM77XFaXEXEZXTnX808=";
|
||||
};
|
||||
nativeBuildInputs = [ setuptools-scm wrapQtAppsHook ];
|
||||
|
||||
SETUPTOOLS_SCM_PRETEND_VERSION = version;
|
||||
|
||||
nativeBuildInputs = [
|
||||
setuptools-scm
|
||||
wrapQtAppsHook
|
||||
];
|
||||
propagatedBuildInputs = [
|
||||
napari-plugin-engine
|
||||
napari-npe2
|
||||
cachey
|
||||
napari-svg
|
||||
napari-console
|
||||
@ -60,7 +69,7 @@
|
||||
jsonschema
|
||||
scipy
|
||||
];
|
||||
SETUPTOOLS_SCM_PRETEND_VERSION = version;
|
||||
|
||||
dontUseSetuptoolsCheck = true;
|
||||
postFixup = ''
|
||||
wrapQtApp $out/bin/napari
|
||||
|
@ -5429,6 +5429,8 @@ in {
|
||||
|
||||
napari-console = callPackage ../development/python-modules/napari-console { };
|
||||
|
||||
napari-npe2 = callPackage ../development/python-modules/napari-npe2 { };
|
||||
|
||||
napari-plugin-engine = callPackage ../development/python-modules/napari-plugin-engine { };
|
||||
|
||||
napari-svg = callPackage ../development/python-modules/napari-svg { };
|
||||
|
Loading…
Reference in New Issue
Block a user