1{
2 lib,
3 app-model,
4 appdirs,
5 buildPythonPackage,
6 cachey,
7 certifi,
8 dask,
9 docstring-parser,
10 fetchFromGitHub,
11 imageio,
12 jsonschema,
13 magicgui,
14 mkDerivationWith,
15 napari-console,
16 napari-npe2,
17 napari-svg,
18 numpydoc,
19 pandas,
20 pillow,
21 pint,
22 psutil,
23 pydantic,
24 pyopengl,
25 pythonOlder,
26 pyyaml,
27 scikit-image,
28 scipy,
29 setuptools,
30 setuptools-scm,
31 superqt,
32 tifffile,
33 toolz,
34 tqdm,
35 typing-extensions,
36 vispy,
37 wrapQtAppsHook,
38 wrapt,
39}:
40
41mkDerivationWith buildPythonPackage rec {
42 pname = "napari";
43 version = "0.4.19.post1";
44 pyproject = true;
45
46 disabled = pythonOlder "3.9";
47
48 src = fetchFromGitHub {
49 owner = "napari";
50 repo = "napari";
51 rev = "refs/tags/v${version}";
52 hash = "sha256-qw5WdFPySNkmm+dNu+hqsmr+csBpHnSl9bMpb4nKEqI=";
53 };
54
55 postPatch = ''
56 substituteInPlace setup.cfg \
57 --replace-fail "scikit-image[data]>=0.19.1" "scikit-image"
58 '';
59
60 build-system = [
61 setuptools
62 setuptools-scm
63 ];
64
65 nativeBuildInputs = [ wrapQtAppsHook ];
66
67 propagatedBuildInputs = [
68 app-model
69 appdirs
70 cachey
71 certifi
72 dask
73 docstring-parser
74 imageio
75 jsonschema
76 magicgui
77 napari-console
78 napari-npe2
79 napari-svg
80 numpydoc
81 pandas
82 pillow
83 pint
84 psutil
85 pydantic
86 pyopengl
87 pyyaml
88 scikit-image
89 scipy
90 superqt
91 tifffile
92 toolz
93 tqdm
94 typing-extensions
95 vispy
96 wrapt
97 ] ++ dask.optional-dependencies.array;
98
99 dontUseSetuptoolsCheck = true;
100
101 postFixup = ''
102 wrapQtApp $out/bin/napari
103 '';
104
105 meta = with lib; {
106 description = "A fast, interactive, multi-dimensional image viewer";
107 homepage = "https://github.com/napari/napari";
108 changelog = "https://github.com/napari/napari/releases/tag/v${version}";
109 license = licenses.bsd3;
110 maintainers = with maintainers; [ SomeoneSerge ];
111 };
112}