python-discovery 1.6.6__py3-none-any.whl → 1.6.7__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.
@@ -389,8 +389,9 @@ def _uv_sort_key(install: _UvInstall) -> tuple[int, ...]:
389
389
  version = key.version
390
390
  return (
391
391
  impl_order.index(key.implementation) if key.implementation in impl_order else len(impl_order),
392
- # uv's minor version links point at a concrete install that moves on upgrade, so report the target instead
393
- int(install.path.is_symlink()),
392
+ # uv's minor version links point at a concrete install that moves on upgrade, so report the target instead;
393
+ # spot them by the name they resolve to, as on Windows they are junctions, which is_symlink() does not report
394
+ int(install.path.resolve().name != install.path.name),
394
395
  -version.major,
395
396
  -version.minor,
396
397
  -version.micro,
@@ -2,6 +2,7 @@
2
2
 
3
3
  from __future__ import annotations
4
4
 
5
+ import copy
5
6
  import json
6
7
  import logging
7
8
  import os
@@ -475,7 +476,10 @@ class PythonInfo: # ruff:ignore[too-many-public-methods]
475
476
  resolved = cls.from_exe(target.system_executable, cache)
476
477
  if resolved is not None:
477
478
  target = resolved
478
- target.executable = start_executable
479
+ if target.executable != start_executable:
480
+ # the cache hands every lookup of this base the same object, so point a copy at the start executable
481
+ target = copy.copy(target)
482
+ target.executable = start_executable
479
483
  return target
480
484
 
481
485
  _cache_exe_discovery: ClassVar[dict[tuple[str, bool], PythonInfo]] = {}
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.5
2
2
  Name: python-discovery
3
- Version: 1.6.6
3
+ Version: 1.6.7
4
4
  Import-Name: python_discovery
5
5
  Summary: Python interpreter discovery
6
6
  Project-URL: Changelog, https://github.com/tox-dev/python-discovery/blob/main/docs/changelog.rst
@@ -2,8 +2,8 @@ python_discovery/__init__.py,sha256=Hi4j3pMvC8Fo8KoNL-wOHsPSCUHwY4c0qvv5sjnFzME,
2
2
  python_discovery/_cache.py,sha256=svmG2GzUQzd2xTjAbm2eX1CKxxGAglfv4kxaPuxwPIA,5147
3
3
  python_discovery/_cached_py_info.py,sha256=15P5_TODxkZCkNfD2Uk5dtPxGf0Nea_aWm2N7uY9zbY,12059
4
4
  python_discovery/_compat.py,sha256=iqxGuhK9rPaiui80G1H1KrweoMJ16gyLYEmUrSXrp5c,709
5
- python_discovery/_discovery.py,sha256=E5b-Sb6jLq_5hVOK0LZwKwvUxMNVsH9UPmf0dCpzZnA,22580
6
- python_discovery/_py_info.py,sha256=SDBYXdoL3aXTfLOgHXrElXK_Og5cJOeJPK7j3rNvTu8,26747
5
+ python_discovery/_discovery.py,sha256=mV1dp7fkyAhXAKjlykRGCQcszQkNQ3UJ-VrDCB0LOSI,22722
6
+ python_discovery/_py_info.py,sha256=fAhFj5swYdGvhJpAXR6b6O1yT2MSbRXTDMrdu15e6q8,26965
7
7
  python_discovery/_py_info_collect.py,sha256=3PNlySbxNSHDjBw8KJ_olVpOXww1qhGdY28YoLfF0Z8,16160
8
8
  python_discovery/_py_spec.py,sha256=uN6PftKwk8cJnnbav5kXpbnQQYQ56LZ828KLp04YGKU,11499
9
9
  python_discovery/_specifier.py,sha256=9sMnJs7FTfIIduTCKKTA7Lk7onARqwkG_zzFIqgj0xs,10364
@@ -11,7 +11,7 @@ python_discovery/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
11
11
  python_discovery/_windows/__init__.py,sha256=qthcyGh36b3WkeSbZ4ECRRYLbCOCaQu5X_DRZ98tXfk,315
12
12
  python_discovery/_windows/_pep514.py,sha256=Vhxe-3hETFIXQrekLqOHmzG5eq5moeR8b0dCS80zbBg,8026
13
13
  python_discovery/_windows/_propose.py,sha256=EE-N-BiNgrFU9mQ34SkoF5gRaNjtspghssQxT9uRQi0,1756
14
- python_discovery-1.6.6.dist-info/METADATA,sha256=ALuIM6ZR6RkPYhHcBUyz9t1OiidUMOiOU1eXi0_R284,3937
15
- python_discovery-1.6.6.dist-info/WHEEL,sha256=W3fkpkm7-wf9vBI5Z-7s0eWkeM-spu78I8Neb98DeEg,87
16
- python_discovery-1.6.6.dist-info/licenses/LICENSE,sha256=kOJeH68qSq6o2V7o5_VziwUqGswMnFgGgQH5Mahr1Yg,1023
17
- python_discovery-1.6.6.dist-info/RECORD,,
14
+ python_discovery-1.6.7.dist-info/METADATA,sha256=lnUw1wj_IpXgeaROo05hjAbznwmCY_9DaEOjRkjSYVw,3937
15
+ python_discovery-1.6.7.dist-info/WHEEL,sha256=W3fkpkm7-wf9vBI5Z-7s0eWkeM-spu78I8Neb98DeEg,87
16
+ python_discovery-1.6.7.dist-info/licenses/LICENSE,sha256=kOJeH68qSq6o2V7o5_VziwUqGswMnFgGgQH5Mahr1Yg,1023
17
+ python_discovery-1.6.7.dist-info/RECORD,,