nmk-python 1.2.0__py3-none-any.whl → 1.4.0__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.
- nmk_python/build.py +13 -1
- nmk_python/build.yml +19 -1
- nmk_python/templates/build.toml.jinja +5 -0
- nmk_python/templates/python-settings.json.jinja +2 -4
- {nmk_python-1.2.0.dist-info → nmk_python-1.4.0.dist-info}/METADATA +3 -2
- {nmk_python-1.2.0.dist-info → nmk_python-1.4.0.dist-info}/RECORD +9 -9
- {nmk_python-1.2.0.dist-info → nmk_python-1.4.0.dist-info}/WHEEL +1 -1
- {nmk_python-1.2.0.dist-info → nmk_python-1.4.0.dist-info/licenses}/LICENSE +0 -0
- {nmk_python-1.2.0.dist-info → nmk_python-1.4.0.dist-info}/top_level.txt +0 -0
nmk_python/build.py
CHANGED
|
@@ -9,7 +9,7 @@ from pathlib import Path
|
|
|
9
9
|
|
|
10
10
|
from nmk.model.builder import NmkTaskBuilder
|
|
11
11
|
from nmk.model.keys import NmkRootConfig
|
|
12
|
-
from nmk.model.resolver import NmkStrConfigResolver
|
|
12
|
+
from nmk.model.resolver import NmkListConfigResolver, NmkStrConfigResolver
|
|
13
13
|
from nmk.utils import is_windows, run_pip, run_with_logs
|
|
14
14
|
from nmk_base.venvbuilder import VenvUpdateBuilder
|
|
15
15
|
from tomlkit import loads
|
|
@@ -176,3 +176,15 @@ class EditableBuilder(NmkTaskBuilder):
|
|
|
176
176
|
|
|
177
177
|
# Touch stamp file
|
|
178
178
|
self.main_output.touch()
|
|
179
|
+
|
|
180
|
+
|
|
181
|
+
class PythonOptionalDepsResolver(NmkListConfigResolver):
|
|
182
|
+
"""
|
|
183
|
+
Python optional deps resolver
|
|
184
|
+
"""
|
|
185
|
+
|
|
186
|
+
def get_value(self, name: str, groups: dict[str, list[str]]) -> list[str]:
|
|
187
|
+
"""
|
|
188
|
+
Turn dependency options deps dict into a merged list of dependencies
|
|
189
|
+
"""
|
|
190
|
+
return sorted(list(set(dependency for deps in groups.values() for dependency in deps)))
|
nmk_python/build.yml
CHANGED
|
@@ -21,10 +21,25 @@ config:
|
|
|
21
21
|
pythonProjectFileFragments:
|
|
22
22
|
- ${BASEDIR}/templates/build.toml.jinja
|
|
23
23
|
|
|
24
|
-
# Python
|
|
24
|
+
# Python optional deps (named groups of python package optional dependencies)
|
|
25
|
+
pythonPackageOptionalRequirements: {}
|
|
26
|
+
|
|
27
|
+
# Derived list of python dependencies from the dependency groups
|
|
28
|
+
pythonPackageOptionalRequirementsList:
|
|
29
|
+
__resolver__: nmk_python.build.PythonOptionalDepsResolver
|
|
30
|
+
params:
|
|
31
|
+
groups: ${pythonPackageOptionalRequirements}
|
|
32
|
+
pythonProjectFileItems:
|
|
33
|
+
project:
|
|
34
|
+
optional-dependencies: ${pythonPackageOptionalRequirements}
|
|
35
|
+
|
|
36
|
+
# Python package dependencies
|
|
25
37
|
pythonPackageRequirements: []
|
|
38
|
+
|
|
39
|
+
# Also install in venv all dependencies
|
|
26
40
|
venvPkgDeps:
|
|
27
41
|
- ${pythonPackageRequirements}
|
|
42
|
+
- ${pythonPackageOptionalRequirementsList}
|
|
28
43
|
|
|
29
44
|
# Extra (external) resources to be bundled in built python wheel
|
|
30
45
|
pythonExtraResources: {}
|
|
@@ -58,6 +73,9 @@ config:
|
|
|
58
73
|
- --no-deps # skip dependencies to avoid reinstalling everything
|
|
59
74
|
- --no-build-isolation # disable dependencies install when building for "editable" mode
|
|
60
75
|
|
|
76
|
+
# Type checking mode for Pyright; may be off, basic, standard, strict
|
|
77
|
+
pythonTypeCheckingMode: strict
|
|
78
|
+
|
|
61
79
|
tasks:
|
|
62
80
|
|
|
63
81
|
# Python editable install
|
|
@@ -19,10 +19,8 @@
|
|
|
19
19
|
"pyvenv",
|
|
20
20
|
"sdist",
|
|
21
21
|
"venv",
|
|
22
|
-
"pyproject"
|
|
23
|
-
|
|
24
|
-
"python.analysis.extraPaths": [{% for folder in pythonSrcFolders %}{% if loop.index > 1 %},{% endif %}
|
|
25
|
-
"{{folder}}"{% endfor %}
|
|
22
|
+
"pyproject",
|
|
23
|
+
"pyright"
|
|
26
24
|
],
|
|
27
25
|
"python.testing.pytestEnabled": {% if pythonTestSrcFiles | length > 0 %}true{% else %}false{% endif %}
|
|
28
26
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
2
|
Name: nmk-python
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.4.0
|
|
4
4
|
Summary: Python plugin for nmk build system
|
|
5
5
|
Author: The dynod project
|
|
6
6
|
Maintainer: The dynod project
|
|
@@ -26,6 +26,7 @@ Requires-Dist: ruff
|
|
|
26
26
|
Requires-Dist: pytest-xdist
|
|
27
27
|
Requires-Dist: pytest-cov
|
|
28
28
|
Requires-Dist: pytest-multilog
|
|
29
|
+
Dynamic: license-file
|
|
29
30
|
|
|
30
31
|
# nmk-python
|
|
31
32
|
Python plugin for nmk build system
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
nmk_python/__init__.py,sha256=EouCWXbAeObby1vOCx0Vx_WaGC2fEEFDMCen3JZt4TU,446
|
|
2
2
|
nmk_python/badges.yml,sha256=LzElZecCXKxdF-oPkvIwfnbQlOcAM_zUj6MelClmAug,749
|
|
3
|
-
nmk_python/build.py,sha256=
|
|
4
|
-
nmk_python/build.yml,sha256=
|
|
3
|
+
nmk_python/build.py,sha256=K8BowkROfrGwOPk7wKwOo9fsWJrrk8bDqJqliC876WI,6716
|
|
4
|
+
nmk_python/build.yml,sha256=Ghv0jrZw2GaVqUXVyTA-JLRRH1d_m8ip97XWuJjrjhM,4970
|
|
5
5
|
nmk_python/doc.yml,sha256=12amAlYylH7JAHaqBIOoEZ_LrXY_bPNKuHrrwUkIj8w,932
|
|
6
6
|
nmk_python/files.py,sha256=gtPf6ldR5F4oGsAdzFnEIbI9MqqvF3z5JQnyONZmLmk,1863
|
|
7
7
|
nmk_python/files.yml,sha256=-vGjogdulwsfdKVEUa5RARYDKxF3m9RmHKFnIhaT3_k,780
|
|
@@ -14,13 +14,13 @@ nmk_python/tests.yml,sha256=wQusYK1bxSl87zWFQy5lJcrkcAz4pMEZT9Vt6o2K5Vs,1538
|
|
|
14
14
|
nmk_python/version.py,sha256=fLpOWdujYwlJB7XhWaOGCTeg3gQaClk2YHoRkkW64dE,3109
|
|
15
15
|
nmk_python/version.yml,sha256=jU0b6JIBVWl5JZJmRBRiqT_pIRyVdddwnH5U5jV1VJ8,904
|
|
16
16
|
nmk_python/templates/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
17
|
-
nmk_python/templates/build.toml.jinja,sha256=
|
|
17
|
+
nmk_python/templates/build.toml.jinja,sha256=HWeBBVd3QNXEsdwdA2fNOCJJaCmitPBuLZBZRqUrbjo,1032
|
|
18
18
|
nmk_python/templates/pytest.toml.jinja,sha256=zQ3SRWnF23Omxm7zInE54j0l3OyjXSOn5pQ5Pak8Boo,641
|
|
19
|
-
nmk_python/templates/python-settings.json.jinja,sha256
|
|
19
|
+
nmk_python/templates/python-settings.json.jinja,sha256=jYXSy96cX9X9GIHoF7XiZDzd4P2GOlMisAVWW626WF4,749
|
|
20
20
|
nmk_python/templates/python-test-debug-launch.json.jinja,sha256=J_xju2EpHNXvgvqBxlf99p7g-ZMh3xE-_2r7o_57gpU,364
|
|
21
21
|
nmk_python/templates/ruff.toml.jinja,sha256=DTHe1ixK1SBY8d2xBCfkGz89HzjAoMO7Ogs12AY1i4Y,346
|
|
22
|
-
nmk_python-1.
|
|
23
|
-
nmk_python-1.
|
|
24
|
-
nmk_python-1.
|
|
25
|
-
nmk_python-1.
|
|
26
|
-
nmk_python-1.
|
|
22
|
+
nmk_python-1.4.0.dist-info/licenses/LICENSE,sha256=PROo9EW7wP6jmSr_90OluItAsIB411b_CAqEBioMKpI,1074
|
|
23
|
+
nmk_python-1.4.0.dist-info/METADATA,sha256=bJ2WGE9zlZEXwryaILea316DhF-DoqROXc-KI_cU1SE,3145
|
|
24
|
+
nmk_python-1.4.0.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
25
|
+
nmk_python-1.4.0.dist-info/top_level.txt,sha256=MCb5w_hoOZ0kk3Dajxrd9Pz6lZ3pyuS6TQCRA3vddTo,11
|
|
26
|
+
nmk_python-1.4.0.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|