-
Notifications
You must be signed in to change notification settings - Fork 371
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
Inconsistencies with globs in MatchSpec
parsing
#3601
Comments
Is |
If you ask me, I understanding as "any version that has at least two components". So I checked and
|
Hmm I see. In EDIT: Maybe this is just a missing part that we need to implement in mamba 2... |
This seems like a substantial backwards incompatibility that should be added to the list of breaking changes introduced in mamba 2. Should I submit a PR? |
My use case is nightly feedstock builds (xref: TileDB-Inc/conda-forge-nightly-controller#151 (comment)). We build the latest version of our C++ library and upload it as a conda binary with the version string |
Yes a PR is most welcome, thank you! |
Actually I am a little confused. I was going to write that the breaking change was that you could no longer use globs in version restrictions because the version parsing was no longer handled as a regex. However, looking at the documentation for From my experiments (code below), I found that:
import libmambapy
libmambapy.version.version_info
## ('2', '0', '4')
import libmambapy.specs as specs
specs.VersionSpec.parse("0.0.*")
specs.VersionSpec.parse("0.*.0")
specs.VersionSpec.parse("*.0.0")
## Traceback (most recent call last):
## File "<stdin>", line 1, in <module>
## libmambapy.bindings.specs.ParseError: Found invalid version predicate in "*.0.0"
# Trailing glob works as expected
specs.VersionSpec.parse("0.0.*").contains(specs.Version.parse("0.0.1"))
## True
specs.VersionSpec.parse("0.0.*").contains(specs.Version.parse("1.0.0"))
## False
# Internal glob accepted but does not work
specs.VersionSpec.parse("0.*.0").contains(specs.Version.parse("0.1.0"))
## False
specs.VersionSpec.parse("0.*.0").contains(specs.Version.parse("1.0.0"))
## False |
Troubleshooting docs
Anaconda default channels
How did you install Mamba?
Other (please describe)
Search tried in issue tracker
matchspec glob
Latest version of Mamba
Tried in Conda?
I do not have this problem with Conda, just with Mamba
Describe your issue
I have detected some parsing / roundtrip issues with libmamba
MatchSpec
objects:This should be valid (although it's a redundant version glob):
Also, when passing this spec to the solver, the error message is lossy. Note how the trailing
*
is lost in the build string:mamba info / micromamba info
Logs
No response
environment.yml
No response
~/.condarc
No response
The text was updated successfully, but these errors were encountered: