Repository navigation
Conversation
2dd9669 to
bee1284
Compare
bee1284 to
5463a13
Compare
Merging this PR will not alter performance
Comparing Footnotes
|
0e9e00e to
976a7f8
Compare
976a7f8 to
7b99c0e
Compare
| // Avoid downloading a pinned interpreter when its version range cannot satisfy the | ||
| // project's Python requirement. | ||
| self.validate_request()?; |
There was a problem hiding this comment.
[P2] Update the remaining snapshots affected by early validation
This changes the isolated-run error output too, but run_isolated_incompatible_python and run_groups_requires_python_errors still expect patch-qualified versions (3.9.[X] and 3.12.[X]). This call now rejects the requests before discovery, producing 3.9 and 3.12. Frozen-sync tests such as sync_lockfile_incompatible_python also retain the old interpreter announcement and patch-qualified error. These assertions no longer match the implementation; update the remaining affected snapshots.
| && let Some(version) = python_request.as_pep440_version() | ||
| { | ||
| validate_project_requires_python_version( | ||
| &version, |
There was a problem hiding this comment.
[P2] Preserve request ranges when identifying conflicting requirements
Converting a partial pin into a concrete version makes the reused helper identify incorrect conflicts. For example, with pin 3.12, project requirement >=3.12.5, and a selected group requiring >=3.13, the helper checks declarations against 3.12.0 and blames both requirements. The pin overlaps the project's requirement; only the group excludes it entirely. Keep the PythonRequest for the early diagnostic and filter contributing declarations with intersects_specifiers, reserving concrete-version diagnostics for discovered interpreters.
| // Avoid downloading a pinned interpreter when its version range cannot satisfy the | ||
| // project's Python requirement. | ||
| project_python.validate_request()?; | ||
|
|
There was a problem hiding this comment.
Oh my gosh validation not on construction!? How was this not capture dby code quality review!?
If
.python-versioncontains3.12but the project requires Python>=3.14, uv can download Python 3.12 before rejecting it. Check the pin before downloading.