Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: issue 717 #732

Merged
merged 4 commits into from
Jun 7, 2024
Merged

fix: issue 717 #732

merged 4 commits into from
Jun 7, 2024

Conversation

baszalmstra
Copy link
Collaborator

@baszalmstra baszalmstra commented Jun 7, 2024

Fixes #717
Fixes prefix-dev/pixi#1469

This fixes parsing of ray[default,data] >=2.9.0,<3.0.0 to fail with InvalidPackageName instead of InvalidBracket.

@baszalmstra
Copy link
Collaborator Author

I also modified the solver to return that the dependencies are unavailable if it contains invalid matchspecs. If no other solution is found this will result in an error like:

Cannot solve the request because of: The following packages are incompatible
└─ issue_717 * cannot be installed because there are no viable options:
   └─ issue_717 2.1 is excluded because the constrains 'ray[default,data] >=2.9.0,<3.0.0' failed to parse: 'ray[default,data]' is not a valid package name. Package names can only contain 0-9, a-z, A-Z, -, _, or .

@wolfv
Copy link
Contributor

wolfv commented Jun 7, 2024

the error message is beautiful, for sure, but I am wondering if we shouldn't just ignore that particular constraint?

@baszalmstra
Copy link
Collaborator Author

For constraints it doesnt really matter. Conda simply swallows this matchspec and then constrains any package called "ray[default,data]" which will never exist so it will not constrain anything. In that case I would be fine to just ignore it. However for requirements I think we should keep this way because most likely the spec is there for a reason.

But in either way I prefer to be explicit.

@wolfv wolfv merged commit 6f258e9 into conda:main Jun 7, 2024
14 checks passed
This was referenced Jun 9, 2024
@baszalmstra baszalmstra mentioned this pull request Jun 17, 2024
@baszalmstra baszalmstra mentioned this pull request Jul 8, 2024
baszalmstra added a commit that referenced this pull request Jul 8, 2024
## 🤖 New release
* `rattler`: 0.26.4 -> 0.26.5
* `rattler_cache`: 0.1.0 -> 0.1.1
* `rattler_conda_types`: 0.25.2 -> 0.26.0
* `rattler_macros`: 0.19.3 -> 0.19.4
* `rattler_package_streaming`: 0.21.3 -> 0.21.4
* `rattler_networking`: 0.20.8 -> 0.20.9
* `rattler_shell`: 0.20.9 -> 0.21.0
* `rattler_lock`: 0.22.12 -> 0.22.13
* `rattler_repodata_gateway`: 0.20.5 -> 0.21.0
* `rattler_solve`: 0.24.2 -> 0.25.0
* `rattler_libsolv_c`: 0.19.3 -> 0.19.4
* `rattler_virtual_packages`: 0.19.15 -> 0.19.16
* `rattler_index`: 0.19.17 -> 0.19.18

<details><summary><i><b>Changelog</b></i></summary><p>

## `rattler`
<blockquote>

##
[0.26.5](rattler-v0.26.4...rattler-v0.26.5)
- 2024-07-08

### Added
- add direct url repodata building
([#725](#725))

### Fixed
- errors should not contain trailing punctuation
([#763](#763))
- run clippy on all targets
([#762](#762))
</blockquote>

## `rattler_cache`
<blockquote>

##
[0.1.1](rattler_cache-v0.1.0...rattler_cache-v0.1.1)
- 2024-07-08

### Added
- add direct url repodata building
([#725](#725))

### Fixed
- run clippy on all targets
([#762](#762))
</blockquote>

## `rattler_conda_types`
<blockquote>

##
[0.26.0](rattler_conda_types-v0.25.2...rattler_conda_types-v0.26.0)
- 2024-07-08

### Added
- add support for zos-z
([#753](#753))
- return pybytes for sha256 and md5 everywhere and use md5 hash for
legacy bz2 md5 ([#752](#752))
- add direct url repodata building
([#725](#725))
- add shards_base_url and write shards atomically
([#747](#747))

### Fixed
- allow version following package in strict mode
([#770](#770))
- Fix doctests and start testing them again
([#767](#767))
- skip over implicit `0` components when copying
([#760](#760))
- allow empty json repodata
([#745](#745))
- lenient and strict parsing of equality signs
([#738](#738))
- This fixes parsing of `ray[default,data] >=2.9.0,<3.0.0`
([#732](#732))
</blockquote>

## `rattler_macros`
<blockquote>

##
[0.19.4](rattler_macros-v0.19.3...rattler_macros-v0.19.4)
- 2024-07-08

### Other
- update README.md
</blockquote>

## `rattler_package_streaming`
<blockquote>

##
[0.21.4](rattler_package_streaming-v0.21.3...rattler_package_streaming-v0.21.4)
- 2024-07-08

### Fixed
- run clippy on all targets
([#762](#762))
</blockquote>

## `rattler_networking`
<blockquote>

##
[0.20.9](rattler_networking-v0.20.8...rattler_networking-v0.20.9)
- 2024-07-08

### Fixed
- errors should not contain trailing punctuation
([#763](#763))
</blockquote>

## `rattler_shell`
<blockquote>

##
[0.21.0](rattler_shell-v0.20.9...rattler_shell-v0.21.0)
- 2024-07-08

### Added
- add direct url repodata building
([#725](#725))
- allow passing custom environment to run_activation
([#743](#743))
</blockquote>

## `rattler_lock`
<blockquote>

##
[0.22.13](rattler_lock-v0.22.12...rattler_lock-v0.22.13)
- 2024-07-08

### Added
- Only save md5 in lock file if no sha256 is present
([#764](#764))
- return pybytes for sha256 and md5 everywhere and use md5 hash for
legacy bz2 md5 ([#752](#752))
- add direct url repodata building
([#725](#725))

### Fixed
- lock file stability issues with PyPI types
([#761](#761))
- errors should not contain trailing punctuation
([#763](#763))

### Other
- revert only save md5 in lock file if no sha256 is present
([#766](#766))
</blockquote>

## `rattler_repodata_gateway`
<blockquote>

##
[0.21.0](rattler_repodata_gateway-v0.20.5...rattler_repodata_gateway-v0.21.0)
- 2024-07-08

### Added
- improve error message when parsing file name
([#757](#757))
- add direct url repodata building
([#725](#725))
- add shards_base_url and write shards atomically
([#747](#747))

### Fixed
- direct_url query for windows
([#768](#768))
- Fix GatewayQuery.query to filter records based on provided specs
([#756](#756))
- run clippy on all targets
([#762](#762))
- allow empty json repodata
([#745](#745))

### Other
- document gateway features
([#737](#737))
</blockquote>

## `rattler_solve`
<blockquote>

##
[0.25.0](rattler_solve-v0.24.2...rattler_solve-v0.25.0)
- 2024-07-08

### Added
- add direct url repodata building
([#725](#725))
- add tool to generate resolvo snapshots
([#741](#741))

### Fixed
- run clippy on all targets
([#762](#762))
- This fixes parsing of `ray[default,data] >=2.9.0,<3.0.0`
([#732](#732))

### Other
- bump resolvo to 0.6.0
([#733](#733))
- Document all features on docs.rs
([#734](#734))
</blockquote>

## `rattler_libsolv_c`
<blockquote>

##
[0.19.4](rattler_libsolv_c-v0.19.3...rattler_libsolv_c-v0.19.4)
- 2024-07-08

### Other
- update README.md
</blockquote>

## `rattler_virtual_packages`
<blockquote>

##
[0.19.16](rattler_virtual_packages-v0.19.15...rattler_virtual_packages-v0.19.16)
- 2024-07-08

### Added
- add support for zos-z
([#753](#753))

### Fixed
- run clippy on all targets
([#762](#762))
</blockquote>

## `rattler_index`
<blockquote>

##
[0.19.18](rattler_index-v0.19.17...rattler_index-v0.19.18)
- 2024-07-08

### Other
- updated the following local packages: rattler_conda_types,
rattler_package_streaming
</blockquote>


</p></details>

---
This PR was generated with
[release-plz](https://github.com/MarcoIeni/release-plz/).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

InvalidBracket for matchspec thread panic in rattler solve
2 participants