-
Notifications
You must be signed in to change notification settings - Fork 398
Description
It would be great to have a new lockfile format.
The current conda lockfile format (explicit env format) has quite a bunch of shortcomings: it's a weird ad-hoc format and only supports MD5 sums (and not even by default, I think & SHA256 is much better).
The command to export an explicit environment in conda is conda list --explicit [--md5]
Micromamba already improves on this by changing the command to micromamba env export --explicit [--no-md5]
(ie. it uses the env
subcommand and defaults to add --md5
hashes).
# This file may be used to create an environment using:
# $ conda create --name <env> --file <this file>
# platform: osx-arm64
@EXPLICIT
https://conda.anaconda.org/conda-forge/osx-arm64/argp-standalone-1.3-h3422bc3_0.tar.bz2#b744f29f1ef63fcedcb63b45d7ceed4a
https://conda.anaconda.org/conda-forge/osx-arm64/git-lfs-2.13.3-hce30654_0.tar.bz2#d0a6dda324b5d970c296dca838965193
...
I am thinking it would be nice to replace this with a proper YAML based format.
I am proposing something like:
metadata:
spec: explicit-1.0
description: ... # optional
name: myenv
# channels: ?
explicit-packages:
linux-64:
- name: xyz
version: 0.15.0
resolved: https://conda.anaconda.org/conda-forge/linux-64/xyz-0.15.0-had123.tar.bz2
sha256: 123123123123123sjadalkjdlkajsk
signature: ... ? # we need to also have certain metadata to validate signatures, though
- name: pip
version: 1.15.0
resolved: https://conda.anaconda.org/conda-forge/noarch/pip-1.15.0-had123.tar.bz2
sha256: 123123123123123sjadalkjdlkajsk
osx-64:
- name: xyz
version: 0.15.0
resolved: https://conda.anaconda.org/conda-forge/osx-64/xyz-0.15.0-had123.tar.bz2
sha256: 123123123123123sjadalkjdlkajsk
- name: abc
version: 0.16.0
resolved: https://conda.anaconda.org/conda-forge/osx-64/abc-0.16.0-had123.tar.bz2
sha256: 123jk1lk23j1kl2j3kj12k3jlj1lk2
The explicit packages would contain a list per (supported) subdir. The list would be the full env resolution (including noarch pacakges) and in the correct order for installation (as current lockfiles today).