napari-plugin-manager 0.1.3__py3-none-any.whl → 0.1.5rc0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- napari_plugin_manager/_tests/test_base_installer_process.py +23 -0
- napari_plugin_manager/_tests/test_installer_process.py +70 -40
- napari_plugin_manager/_tests/test_npe2api.py +18 -10
- napari_plugin_manager/_tests/test_qt_plugin_dialog.py +209 -90
- napari_plugin_manager/_version.py +9 -4
- napari_plugin_manager/base_qt_package_installer.py +689 -0
- napari_plugin_manager/base_qt_plugin_dialog.py +1868 -0
- napari_plugin_manager/npe2api.py +1 -3
- napari_plugin_manager/qt_package_installer.py +31 -607
- napari_plugin_manager/qt_plugin_dialog.py +129 -1401
- napari_plugin_manager/qt_warning_dialog.py +19 -0
- napari_plugin_manager/utils.py +1 -2
- {napari_plugin_manager-0.1.3.dist-info → napari_plugin_manager-0.1.5rc0.dist-info}/METADATA +46 -11
- napari_plugin_manager-0.1.5rc0.dist-info/RECORD +23 -0
- {napari_plugin_manager-0.1.3.dist-info → napari_plugin_manager-0.1.5rc0.dist-info}/WHEEL +1 -1
- napari_plugin_manager-0.1.3.dist-info/RECORD +0 -19
- {napari_plugin_manager-0.1.3.dist-info → napari_plugin_manager-0.1.5rc0.dist-info/licenses}/LICENSE +0 -0
- {napari_plugin_manager-0.1.3.dist-info → napari_plugin_manager-0.1.5rc0.dist-info}/top_level.txt +0 -0
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
from qtpy.QtWidgets import QDialog, QLabel, QPushButton, QVBoxLayout, QWidget
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
class RestartWarningDialog(QDialog):
|
|
5
|
+
def __init__(self, parent: QWidget) -> None:
|
|
6
|
+
super().__init__(parent)
|
|
7
|
+
self.setWindowTitle('Restart napari')
|
|
8
|
+
okay_btn = QPushButton('Okay')
|
|
9
|
+
self.restart_warning_text = """
|
|
10
|
+
Plugins have been installed or uninstalled. If you notice any
|
|
11
|
+
issues with plugin functionality, you may need to restart napari.
|
|
12
|
+
"""
|
|
13
|
+
|
|
14
|
+
okay_btn.clicked.connect(self.accept)
|
|
15
|
+
|
|
16
|
+
layout = QVBoxLayout()
|
|
17
|
+
layout.addWidget(QLabel(self.restart_warning_text))
|
|
18
|
+
layout.addWidget(okay_btn)
|
|
19
|
+
self.setLayout(layout)
|
napari_plugin_manager/utils.py
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import re
|
|
2
2
|
import sys
|
|
3
3
|
from pathlib import Path
|
|
4
|
-
from typing import Optional
|
|
5
4
|
|
|
6
5
|
|
|
7
|
-
def is_conda_package(pkg: str, prefix:
|
|
6
|
+
def is_conda_package(pkg: str, prefix: str | None = None) -> bool:
|
|
8
7
|
"""Determines if plugin was installed through conda.
|
|
9
8
|
|
|
10
9
|
Returns
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
2
|
Name: napari-plugin-manager
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.5rc0
|
|
4
4
|
Summary: Install plugins for napari, in napari.
|
|
5
5
|
Author-email: napari team <napari-steering-council@googlegroups.com>
|
|
6
6
|
License: BSD 3-Clause License
|
|
@@ -43,9 +43,10 @@ Classifier: License :: OSI Approved :: BSD License
|
|
|
43
43
|
Classifier: Programming Language :: C
|
|
44
44
|
Classifier: Programming Language :: Python
|
|
45
45
|
Classifier: Programming Language :: Python :: 3 :: Only
|
|
46
|
-
Classifier: Programming Language :: Python :: 3.9
|
|
47
46
|
Classifier: Programming Language :: Python :: 3.10
|
|
48
47
|
Classifier: Programming Language :: Python :: 3.11
|
|
48
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
49
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
49
50
|
Classifier: Topic :: Scientific/Engineering
|
|
50
51
|
Classifier: Topic :: Scientific/Engineering :: Visualization
|
|
51
52
|
Classifier: Topic :: Scientific/Engineering :: Information Analysis
|
|
@@ -55,16 +56,23 @@ Classifier: Operating System :: Microsoft :: Windows
|
|
|
55
56
|
Classifier: Operating System :: POSIX
|
|
56
57
|
Classifier: Operating System :: Unix
|
|
57
58
|
Classifier: Operating System :: MacOS
|
|
58
|
-
Requires-Python: >=3.
|
|
59
|
+
Requires-Python: >=3.10
|
|
59
60
|
Description-Content-Type: text/markdown
|
|
60
61
|
License-File: LICENSE
|
|
61
62
|
Requires-Dist: npe2
|
|
62
63
|
Requires-Dist: qtpy
|
|
63
64
|
Requires-Dist: superqt
|
|
64
65
|
Requires-Dist: pip
|
|
66
|
+
Requires-Dist: packaging
|
|
65
67
|
Provides-Extra: dev
|
|
66
|
-
Requires-Dist:
|
|
68
|
+
Requires-Dist: PyQt6; extra == "dev"
|
|
67
69
|
Requires-Dist: pre-commit; extra == "dev"
|
|
70
|
+
Provides-Extra: testing
|
|
71
|
+
Requires-Dist: coverage; extra == "testing"
|
|
72
|
+
Requires-Dist: flaky; extra == "testing"
|
|
73
|
+
Requires-Dist: pytest; extra == "testing"
|
|
74
|
+
Requires-Dist: pytest-qt; extra == "testing"
|
|
75
|
+
Requires-Dist: virtualenv; extra == "testing"
|
|
68
76
|
Provides-Extra: docs
|
|
69
77
|
Requires-Dist: sphinx>6; extra == "docs"
|
|
70
78
|
Requires-Dist: sphinx-autobuild; extra == "docs"
|
|
@@ -73,12 +81,7 @@ Requires-Dist: sphinx-copybutton; extra == "docs"
|
|
|
73
81
|
Requires-Dist: sphinx-favicon; extra == "docs"
|
|
74
82
|
Requires-Dist: myst-nb; extra == "docs"
|
|
75
83
|
Requires-Dist: napari-sphinx-theme>=0.3.0; extra == "docs"
|
|
76
|
-
|
|
77
|
-
Requires-Dist: flaky; extra == "testing"
|
|
78
|
-
Requires-Dist: pytest; extra == "testing"
|
|
79
|
-
Requires-Dist: pytest-cov; extra == "testing"
|
|
80
|
-
Requires-Dist: pytest-qt; extra == "testing"
|
|
81
|
-
Requires-Dist: virtualenv; extra == "testing"
|
|
84
|
+
Dynamic: license-file
|
|
82
85
|
|
|
83
86
|
# napari-plugin-manager
|
|
84
87
|
|
|
@@ -186,6 +189,20 @@ a restart to be properly configured.
|
|
|
186
189
|
|
|
187
190
|

|
|
188
191
|
|
|
192
|
+
### Installing a plugin via direct entry
|
|
193
|
+
|
|
194
|
+
You can also install a napari plugin or any other package via the direct entry option. The following steps
|
|
195
|
+
correspond to the options and buttons located at the **bottom of the dialog**.
|
|
196
|
+
|
|
197
|
+
1. You can type either the name of the package, a url to the resource or drag and drop a compressed file
|
|
198
|
+
of a previously downloaded package.
|
|
199
|
+
2. Select the tool (`conda` or `pip`) by clicking on the arrow dorpdown of the `Install` button.
|
|
200
|
+
3. Start the installation process by clicking on the `Install` button.
|
|
201
|
+
|
|
202
|
+
You can cancel the process at any time by clicking the `Cancel all` button.
|
|
203
|
+
|
|
204
|
+

|
|
205
|
+
|
|
189
206
|
### Uninstalling a plugin
|
|
190
207
|
|
|
191
208
|
To uninstall a plugin:
|
|
@@ -215,6 +232,24 @@ You can cancel the process at any time by clicking the `Cancel` button of each p
|
|
|
215
232
|
|
|
216
233
|

|
|
217
234
|
|
|
235
|
+
### Export/Import plugins
|
|
236
|
+
|
|
237
|
+
You can export the list of install plugins by clicking on the `Export` button located on the top right
|
|
238
|
+
corner of the UI. This will prompt a dialog to select the location and name of the text file where
|
|
239
|
+
the installed plugin list will be saved.
|
|
240
|
+
|
|
241
|
+
The file is plain text and plugins are listed in the [requirements.txt](https://pip.pypa.io/en/stable/reference/requirements-file-format/) format:
|
|
242
|
+
```
|
|
243
|
+
plugin_name==0.1.2
|
|
244
|
+
```
|
|
245
|
+
|
|
246
|
+
This file can be shared and then imported by clicking on the `Import` button located on the top right
|
|
247
|
+
corner of the UI. This will prompt a dialog to select the location of the text file to import.
|
|
248
|
+
|
|
249
|
+
After selecting the file, the plugin manager will attempt to install all the listed plugins using the auto-detected default installer.
|
|
250
|
+
|
|
251
|
+

|
|
252
|
+
|
|
218
253
|
### Batch actions
|
|
219
254
|
|
|
220
255
|
You don't need wait for one action to finish before you can start another one. You can add more
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
napari_plugin_manager/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
2
|
+
napari_plugin_manager/_version.py,sha256=7xL2mpNMN7CvV7puiJsYbI94hf0zjK2m6GYP2m4vqJ8,514
|
|
3
|
+
napari_plugin_manager/base_qt_package_installer.py,sha256=Tp2dt5BBT-5CsXXlQPIPxuXSDMvUgKy2kSgw2Y2G9Dk,21825
|
|
4
|
+
napari_plugin_manager/base_qt_plugin_dialog.py,sha256=gkrEkVf_WGJHjZFORMoCiw-gxCwFuTZ04Q0PGFK8gLk,65978
|
|
5
|
+
napari_plugin_manager/npe2api.py,sha256=bXmhwFkwKw_1DfnGLhWhEGaEAA3oYPFaw4eR4SX2Nyg,4075
|
|
6
|
+
napari_plugin_manager/qt_package_installer.py,sha256=j-pacW6wHVq3iJaZXsj6D-_VH25Fz-55r7clcd_CQvE,2804
|
|
7
|
+
napari_plugin_manager/qt_plugin_dialog.py,sha256=Ig4TtjCh9Z2Dx_QpiOsfLlgolPJHmJ5_7VuTU2DE0Ag,9607
|
|
8
|
+
napari_plugin_manager/qt_warning_dialog.py,sha256=ue4CeMptlBBkBctPg7qCayamrkm75iLqASSFUvwo_Bc,669
|
|
9
|
+
napari_plugin_manager/qt_widgets.py,sha256=O8t5CbN8r_16cQzshyjvhTEYdUcj7OX0-bfYIiN2uSs,356
|
|
10
|
+
napari_plugin_manager/styles.qss,sha256=9ODPba2IorJybWObWoEO9VGq4AO0IYlAa8brN14tgZU,7379
|
|
11
|
+
napari_plugin_manager/utils.py,sha256=V0QmCQNP2OwszoQ2n9Gnau9jH81rLKwfskL4ebex7EE,722
|
|
12
|
+
napari_plugin_manager/_tests/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
13
|
+
napari_plugin_manager/_tests/conftest.py,sha256=OvzenfBP2oIS6x8ksr9FhPXdsLV3Q_3Kzr6PRJe45Uc,1885
|
|
14
|
+
napari_plugin_manager/_tests/test_base_installer_process.py,sha256=Cv-nBnUeNAX6pYUE1zs38I9vGtCE-ahBN4q-xcBH-pw,561
|
|
15
|
+
napari_plugin_manager/_tests/test_installer_process.py,sha256=qPSDcYWPQ08gzM38av2tcE9XCtruHv-Mo6duQ0sZp-8,11614
|
|
16
|
+
napari_plugin_manager/_tests/test_npe2api.py,sha256=GRXucH7kWHt6thgueppHHWaToTvQG1PXH6UECFeVxcM,1225
|
|
17
|
+
napari_plugin_manager/_tests/test_qt_plugin_dialog.py,sha256=YW7q1fkt0O6VmemUVPQokKMWdCSfy5owrZRy1XeiA8U,21551
|
|
18
|
+
napari_plugin_manager/_tests/test_utils.py,sha256=7EilxmDkRjU6UO2AnaqyYovdAs18D0ZA5GCVGN62-3M,720
|
|
19
|
+
napari_plugin_manager-0.1.5rc0.dist-info/licenses/LICENSE,sha256=8dAlKbOqTMYe9L-gL_kEx5Xr1Sd0AbaWQDUkpiOp3vI,1506
|
|
20
|
+
napari_plugin_manager-0.1.5rc0.dist-info/METADATA,sha256=FiXaa9ci_ZySoyTz1kXNXqgHBNBJPiy9I3tdVmSm1NE,13813
|
|
21
|
+
napari_plugin_manager-0.1.5rc0.dist-info/WHEEL,sha256=CmyFI0kx5cdEMTLiONQRbGQwjIoR1aIYB7eCAQ4KPJ0,91
|
|
22
|
+
napari_plugin_manager-0.1.5rc0.dist-info/top_level.txt,sha256=pmCqLetuumhY1CKSuTZ5eQsitzazrSvc7V_mkugEPTY,22
|
|
23
|
+
napari_plugin_manager-0.1.5rc0.dist-info/RECORD,,
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
napari_plugin_manager/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
2
|
-
napari_plugin_manager/_version.py,sha256=L5DCMp1QAlSqy-8bW7d51bLubTxNjZGYc5fMQkb752U,411
|
|
3
|
-
napari_plugin_manager/npe2api.py,sha256=lpanAxjpvEfGkHwTwVXmTSXWlMrjBxHOJ-p_-LbTW2o,4093
|
|
4
|
-
napari_plugin_manager/qt_package_installer.py,sha256=WPZZY3BQxH1OHm2-TBLf0-brzqV7Wh_Gnwk9hwFPmtQ,21454
|
|
5
|
-
napari_plugin_manager/qt_plugin_dialog.py,sha256=w0XV8hap-FsjZ75ZX6gfqREIf0T803sV1pAkAy5IqK8,57011
|
|
6
|
-
napari_plugin_manager/qt_widgets.py,sha256=O8t5CbN8r_16cQzshyjvhTEYdUcj7OX0-bfYIiN2uSs,356
|
|
7
|
-
napari_plugin_manager/styles.qss,sha256=9ODPba2IorJybWObWoEO9VGq4AO0IYlAa8brN14tgZU,7379
|
|
8
|
-
napari_plugin_manager/utils.py,sha256=wG_lGPaMmbfyH-q7oTWDYSI2iAKiZ3cqxyjlRlbvFJo,753
|
|
9
|
-
napari_plugin_manager/_tests/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
10
|
-
napari_plugin_manager/_tests/conftest.py,sha256=OvzenfBP2oIS6x8ksr9FhPXdsLV3Q_3Kzr6PRJe45Uc,1885
|
|
11
|
-
napari_plugin_manager/_tests/test_installer_process.py,sha256=fgO8OwYcCAz-OlGT_1G_eb4B69DPbnQdzjCrwTIeCpE,10523
|
|
12
|
-
napari_plugin_manager/_tests/test_npe2api.py,sha256=_YPo4jaA9cZ9OeeXn8HMJzijQ7OoWXnSiEN81NEzvhI,1031
|
|
13
|
-
napari_plugin_manager/_tests/test_qt_plugin_dialog.py,sha256=vNSDc7ouNPjhtrfEuhGoHQwlxEDwissuqLxu8SR1rv0,17722
|
|
14
|
-
napari_plugin_manager/_tests/test_utils.py,sha256=7EilxmDkRjU6UO2AnaqyYovdAs18D0ZA5GCVGN62-3M,720
|
|
15
|
-
napari_plugin_manager-0.1.3.dist-info/LICENSE,sha256=8dAlKbOqTMYe9L-gL_kEx5Xr1Sd0AbaWQDUkpiOp3vI,1506
|
|
16
|
-
napari_plugin_manager-0.1.3.dist-info/METADATA,sha256=uRgMXcB0CJIWR6-CdvHkqX7Yt9syC_Xp9p2tNXsbAv0,11967
|
|
17
|
-
napari_plugin_manager-0.1.3.dist-info/WHEEL,sha256=GV9aMThwP_4oNCtvEC2ec3qUYutgWeAzklro_0m4WJQ,91
|
|
18
|
-
napari_plugin_manager-0.1.3.dist-info/top_level.txt,sha256=pmCqLetuumhY1CKSuTZ5eQsitzazrSvc7V_mkugEPTY,22
|
|
19
|
-
napari_plugin_manager-0.1.3.dist-info/RECORD,,
|
{napari_plugin_manager-0.1.3.dist-info → napari_plugin_manager-0.1.5rc0.dist-info/licenses}/LICENSE
RENAMED
|
File without changes
|
{napari_plugin_manager-0.1.3.dist-info → napari_plugin_manager-0.1.5rc0.dist-info}/top_level.txt
RENAMED
|
File without changes
|