moat-lib-path 0.3.6__tar.gz → 0.3.7__tar.gz
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.
- {moat_lib_path-0.3.6/src/moat_lib_path.egg-info → moat_lib_path-0.3.7}/PKG-INFO +1 -1
- {moat_lib_path-0.3.6 → moat_lib_path-0.3.7}/debian/changelog +6 -0
- {moat_lib_path-0.3.6 → moat_lib_path-0.3.7}/pyproject.toml +1 -1
- {moat_lib_path-0.3.6 → moat_lib_path-0.3.7}/src/moat/lib/path/_impl.py +10 -4
- {moat_lib_path-0.3.6 → moat_lib_path-0.3.7/src/moat_lib_path.egg-info}/PKG-INFO +1 -1
- {moat_lib_path-0.3.6 → moat_lib_path-0.3.7}/LICENSE.txt +0 -0
- {moat_lib_path-0.3.6 → moat_lib_path-0.3.7}/Makefile +0 -0
- {moat_lib_path-0.3.6 → moat_lib_path-0.3.7}/README.md +0 -0
- {moat_lib_path-0.3.6 → moat_lib_path-0.3.7}/debian/.gitignore +0 -0
- {moat_lib_path-0.3.6 → moat_lib_path-0.3.7}/debian/control +0 -0
- {moat_lib_path-0.3.6 → moat_lib_path-0.3.7}/debian/rules +0 -0
- {moat_lib_path-0.3.6 → moat_lib_path-0.3.7}/setup.cfg +0 -0
- {moat_lib_path-0.3.6 → moat_lib_path-0.3.7}/src/moat/lib/path/__init__.py +0 -0
- {moat_lib_path-0.3.6 → moat_lib_path-0.3.7}/src/moat_lib_path.egg-info/SOURCES.txt +0 -0
- {moat_lib_path-0.3.6 → moat_lib_path-0.3.7}/src/moat_lib_path.egg-info/dependency_links.txt +0 -0
- {moat_lib_path-0.3.6 → moat_lib_path-0.3.7}/src/moat_lib_path.egg-info/requires.txt +0 -0
- {moat_lib_path-0.3.6 → moat_lib_path-0.3.7}/src/moat_lib_path.egg-info/top_level.txt +0 -0
|
@@ -22,7 +22,7 @@ name = "moat-lib-path"
|
|
|
22
22
|
maintainers = [{email = "matthias@urlichs.de",name = "Matthias Urlichs"}]
|
|
23
23
|
description='Hierarchical path representation and manipulation for MoaT'
|
|
24
24
|
readme = "README.md"
|
|
25
|
-
version = "0.3.
|
|
25
|
+
version = "0.3.7"
|
|
26
26
|
|
|
27
27
|
[project.urls]
|
|
28
28
|
homepage = "https://m-o-a-t.org"
|
|
@@ -196,14 +196,20 @@ class Path(Sequence[PathElem]):
|
|
|
196
196
|
if mark:
|
|
197
197
|
warnings.warn("Marking a path is deprecated")
|
|
198
198
|
|
|
199
|
-
if
|
|
199
|
+
if not a:
|
|
200
|
+
pass
|
|
201
|
+
elif decoded and isinstance(a[0], RootPath) and prefix is None:
|
|
202
|
+
prefix = a[0]
|
|
203
|
+
a = a[1:]
|
|
204
|
+
elif isinstance(a[0], Path):
|
|
205
|
+
if len(a) > 1:
|
|
206
|
+
raise ValueError("Can't build a path this way")
|
|
207
|
+
a = a[0].as_tuple()
|
|
208
|
+
elif len(a) != 1 and _warn:
|
|
200
209
|
warnings.warn(
|
|
201
210
|
"Call 'Path.build(args)', not 'Path(*args)'", DeprecationWarning, stacklevel=2
|
|
202
211
|
)
|
|
203
212
|
|
|
204
|
-
if decoded and a and isinstance(a[0], RootPath) and prefix is None:
|
|
205
|
-
prefix = a[0]
|
|
206
|
-
a = a[1:]
|
|
207
213
|
for x in a:
|
|
208
214
|
if not isinstance(x, PathElemI): # pyright:ignore[reportArgumentType]
|
|
209
215
|
raise TypeError(f"{x!r} cannot be in a path")
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|