ducktools-pythonfinder 0.10.5__tar.gz → 0.10.6__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.
- {ducktools_pythonfinder-0.10.5/src/ducktools_pythonfinder.egg-info → ducktools_pythonfinder-0.10.6}/PKG-INFO +1 -1
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/pyproject.toml +2 -0
- ducktools_pythonfinder-0.10.6/src/ducktools/pythonfinder/_version.py +2 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/src/ducktools/pythonfinder/linux/__init__.py +8 -5
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/src/ducktools/pythonfinder/shared.py +7 -2
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6/src/ducktools_pythonfinder.egg-info}/PKG-INFO +1 -1
- ducktools_pythonfinder-0.10.6/uv.lock +522 -0
- ducktools_pythonfinder-0.10.5/src/ducktools/pythonfinder/_version.py +0 -2
- ducktools_pythonfinder-0.10.5/uv.lock +0 -376
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/.gitignore +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/LICENSE +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/MANIFEST.in +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/README.md +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/scripts/build_zipapp.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/scripts/detail_this_python.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/scripts/list_python_venvs.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/scripts/print_python_versions.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/setup.cfg +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/src/ducktools/pythonfinder/__init__.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/src/ducktools/pythonfinder/__main__.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/src/ducktools/pythonfinder/darwin/__init__.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/src/ducktools/pythonfinder/details_script.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/src/ducktools/pythonfinder/linux/pyenv_search.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/src/ducktools/pythonfinder/package_list_script.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/src/ducktools/pythonfinder/py.typed +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/src/ducktools/pythonfinder/pythonorg_search.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/src/ducktools/pythonfinder/venv.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/src/ducktools/pythonfinder/win32/__init__.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/src/ducktools/pythonfinder/win32/pyenv_search.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/src/ducktools/pythonfinder/win32/registry_search.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/src/ducktools_pythonfinder.egg-info/SOURCES.txt +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/src/ducktools_pythonfinder.egg-info/dependency_links.txt +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/src/ducktools_pythonfinder.egg-info/entry_points.txt +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/src/ducktools_pythonfinder.egg-info/requires.txt +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/src/ducktools_pythonfinder.egg-info/top_level.txt +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/tests/conftest.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/tests/sources/python_versions.txt +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/tests/sources/release.json +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/tests/sources/release_file.json +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/tests/test_cache.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/tests/test_details_script.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/tests/test_foldersearch.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/tests/test_orgsearch.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/tests/test_pyenv.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/tests/test_shared.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/tests/test_uv_finder.py +0 -0
- {ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/tests/test_venv_finder.py +0 -0
|
@@ -80,12 +80,15 @@ def get_path_pythons(
|
|
|
80
80
|
if not os.path.exists(fld):
|
|
81
81
|
continue
|
|
82
82
|
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
83
|
+
# Do the search like this to get subfolders
|
|
84
|
+
for path, manager in known_paths.items():
|
|
85
|
+
if os.path.commonpath((path, fld)) == path:
|
|
86
|
+
managed_by = manager
|
|
87
|
+
break
|
|
88
|
+
else:
|
|
89
|
+
managed_by = None
|
|
88
90
|
|
|
91
|
+
for install in get_folder_pythons(fld, finder=finder, managed_by=managed_by):
|
|
89
92
|
name = os.path.basename(install.executable)
|
|
90
93
|
if name in exe_names:
|
|
91
94
|
install.shadowed = True
|
{ducktools_pythonfinder-0.10.5 → ducktools_pythonfinder-0.10.6}/src/ducktools/pythonfinder/shared.py
RENAMED
|
@@ -291,16 +291,21 @@ class DetailFinder(Prefab):
|
|
|
291
291
|
exe_path = os.path.abspath(exe_path)
|
|
292
292
|
mtime = os.stat(exe_path).st_mtime
|
|
293
293
|
|
|
294
|
+
# If the mtime of the file has been set to 0
|
|
295
|
+
# it is not possible to reliably cache install details
|
|
296
|
+
cacheable_install = (mtime != 0)
|
|
297
|
+
|
|
294
298
|
install = None
|
|
295
299
|
if cached_details := self.raw_cache.get(exe_path):
|
|
296
|
-
if cached_details["mtime"] == mtime:
|
|
300
|
+
if cacheable_install and cached_details["mtime"] == mtime:
|
|
297
301
|
install = PythonInstall.from_json(**cached_details["install"])
|
|
298
302
|
else:
|
|
299
303
|
self.raw_cache.pop(exe_path)
|
|
304
|
+
self._dirty_cache = True
|
|
300
305
|
|
|
301
306
|
if install is None:
|
|
302
307
|
install = self.query_install(exe_path, managed_by, metadata)
|
|
303
|
-
if install:
|
|
308
|
+
if install and cacheable_install:
|
|
304
309
|
self.raw_cache[exe_path] = {
|
|
305
310
|
"mtime": mtime,
|
|
306
311
|
"install": as_dict(install)
|