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

Drop md5 and sha256 fields from MatchSpec (they are ignored anyway) #429

Merged
merged 2 commits into from
Jan 26, 2024

Conversation

jaimergp
Copy link
Contributor

@jaimergp jaimergp commented Jan 26, 2024

Description

Closes #427

libmamba does not die if md5 fields are passed in the MatchSpec, but it's not used for anything either (see issue upstream). For example, a4c000a412e65c1844c92c1558257909 corresponds to linux-aarch64/zlib-1.2.12-h4e544f5_0.tar.bz2, but we get zlib 1.3 (latest) anyway.

$ conda create -dnx "zlib[md5=a4c000a412e65c1844c92c1558257909]"
Channels:
 - conda-forge
Platform: linux-aarch64
Collecting package metadata (repodata.json): done
Solving environment: done

## Package Plan ##

  environment location: /home/test_user/.conda/envs/x

  added / updated specs:
    - zlib[md5=a4c000a412e65c1844c92c1558257909]


The following packages will be downloaded:

    package                    |            build
    ---------------------------|-----------------
    _openmp_mutex-4.5          |            2_gnu          23 KB  conda-forge
    libzlib-1.3                |       h31becfc_0          66 KB  conda-forge
    zlib-1.3                   |       h31becfc_0          94 KB  conda-forge
    ------------------------------------------------------------
                                           Total:         184 KB

The following NEW packages will be INSTALLED:

  _openmp_mutex      conda-forge/linux-aarch64::_openmp_mutex-4.5-2_gnu 
  libgcc-ng          conda-forge/linux-aarch64::libgcc-ng-13.2.0-hf8544c7_3 
  libgomp            conda-forge/linux-aarch64::libgomp-13.2.0-hf8544c7_3 
  libzlib            conda-forge/linux-aarch64::libzlib-1.3-h31becfc_0 
  zlib               conda-forge/linux-aarch64::zlib-1.3-h31becfc_0 



DryRunExit: Dry run. Exiting.

Checklist - did you ...

  • Add a file to the news directory (using the template) for the next release's release notes?
  • Add / update necessary tests?
  • Add / update outdated documentation?

@conda-bot conda-bot added the cla-signed [bot] added once the contributor has signed the CLA label Jan 26, 2024
@jaimergp
Copy link
Contributor Author

@jezdez, I think this would be a good candidate for 24.1 too.

@jaimergp jaimergp marked this pull request as ready for review January 26, 2024 12:05
@jaimergp jaimergp requested a review from jezdez January 26, 2024 12:05
@jaisw7
Copy link

jaisw7 commented Jan 26, 2024

The issue also appears during install:

conda install glib=2.56.2 -c conda-forge
Channels:
 - conda-forge
 - ucb-bar
Platform: linux-64
Collecting package metadata (repodata.json): done
Solving environment: failed

InvalidMatchSpec: Invalid spec 'conda-forge/linux-64::_libgcc_mutex==0.1=conda_forge[md5=d7c89558ba9fa0495403155b64376d81]': Libmamba only supports a subset of the MatchSpec interface for now. You can only use ('name', 'version', 'build', 'channel', 'subdir'), but you tried to use ('md5',).

I believe a downgrade should solve the issue. Any suitable working version?

@jezdez
Copy link
Member

jezdez commented Jan 26, 2024

@jezdez, I think this would be a good candidate for 24.1 too.

Sounds good to me.

@jezdez jezdez changed the title drop md5 and sha256 fields from MatchSpec (they are ignored anyway) Drop md5 and sha256 fields from MatchSpec (they are ignored anyway) Jan 26, 2024
@jaimergp
Copy link
Contributor Author

Any suitable working version?

The next release will have the fix!

@jaimergp jaimergp merged commit 5fc862c into main Jan 26, 2024
71 checks passed
@AntoinePrv
Copy link

Hello, md5 and sha256 are now implemented in mamba-org/mamba#3233 ( libmamba>2.0.0alpha3 new release coming soon).

More generally, we have been able to plug a callback into libsolv for resolving matchspecs ourselves (it's only used when needed so far as we are not yet sure of the performance implications). This comes with our own implementation of the MatchSpec (with new doc).
They will surely need some polishing, but are in a much better state to receive contribution: they are independent from the whole mamba heavy-lifting and properly unit-tested in C++.
They are also available in Python under libmambapy.specs.MatchSpec if you wish to give them a try.

@jaimergp jaimergp deleted the drop-md5-sha256 branch July 22, 2024 17:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla-signed [bot] added once the contributor has signed the CLA
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

Can't add additional packages to enviornment created from lock file
5 participants