fix(python): support library lookup on Python 3.8

This commit is contained in:
2026-09-01 20:31:18 +03:00
parent e9c5ec90b8
commit 076c51c083

View File

@@ -67,7 +67,9 @@ def _library_candidates() -> Iterable[Path | str]:
# One-release fallback for already packaged SETCore binaries.
"setcore.dll", "libsetcore.so", "libsetcore.dylib",
)
for parent in (here.parent, *here.parents[:5]):
# Python 3.8 (used by the Windows 7 build) does not support slicing
# Path.parents directly. Convert the sequence before taking the slice.
for parent in (here.parent, *tuple(here.parents)[:5]):
for name in names:
yield parent / "native" / name
yield parent / name