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

conda-pack is not reproducible #345

Closed
2 tasks done
pavelzw opened this issue Jun 25, 2024 · 1 comment · Fixed by #349
Closed
2 tasks done

conda-pack is not reproducible #345

pavelzw opened this issue Jun 25, 2024 · 1 comment · Fixed by #349
Labels
type::bug describes erroneous operation, use severity::* to classify the type

Comments

@pavelzw
Copy link

pavelzw commented Jun 25, 2024

Checklist

  • I added a descriptive title
  • I searched open reports and couldn't find a duplicate

What happened?

When running conda-pack multiple times, I would expect that the tar.gz file is reproducible and will be the same (as long as you don't touch the environment by running something in it (then, .pyc files might get generated)).

But when running conda-pack multiple times, I observed that the packed environment always has a different SHA.
Here a small reproducer:

❯ pixi init
✔ Initialized project in /private/var/folders/rz/q1r4tv0n6ll38q18fbk419mc0000gn/T/tmp.5Rw82ZWAWg/.
❯ pixi add python
✔ Added python
❯ conda-pack -p .pixi/envs/default
Collecting packages...
Packing environment at '/private/var/folders/rz/q1r4tv0n6ll38q18fbk419mc0000gn/T/tmp.5Rw82ZWAWg/.pixi/envs/default' to 'default.tar.gz'
[########################################] | 100% Completed |  1.6s
❯ sha256sum default.tar.gz
560180e8bde3a5281c4d669fb7cd7cae431d7052a1648957c111e7dd1ed9b908  default.tar.gz
❯ rm default.tar.gz
❯ conda-pack -p .pixi/envs/default
Collecting packages...
Packing environment at '/private/var/folders/rz/q1r4tv0n6ll38q18fbk419mc0000gn/T/tmp.5Rw82ZWAWg/.pixi/envs/default' to 'default.tar.gz'
[########################################] | 100% Completed |  1.7s
❯ sha256sum default.tar.gz
1da9aee4bcf832680faadb9ed3ae9a1bf1794e33cf01312274df0a4c0b6680c6  default.tar.gz

I am using conda-pack installed via pixi global install conda-pack, i.e., in an isolated environment, version 0.7.1.

Conda Info

No response

Conda Config

No response

Conda list

No response

Additional Context

No response

@pavelzw pavelzw added the type::bug describes erroneous operation, use severity::* to classify the type label Jun 25, 2024
@xhochy
Copy link
Collaborator

xhochy commented Jul 11, 2024

This is only a small timestamp diff:

% diffoscope default-orig.tar.gz default.tar.gz
--- default-orig.tar.gz
+++ default.tar.gz
├── filetype from file(1)
│ @@ -1 +1 @@
│ -gzip compressed data, last modified: Thu Jul 11 11:53:40 2024
│ +gzip compressed data, last modified: Thu Jul 11 11:53:57 2024
│   --- default-orig.tar
├── +++ default.tar
│ ├── file list
│ │ @@ -6358,8 +6358,8 @@
│ │  -rw-r--r--   0 uwe        (501) staff       (20)   194285 2024-07-11 11:53:14.893165 conda-meta/tzdata-2024a-h0c530f3_0.json
│ │  -rw-r--r--   0 uwe        (501) staff       (20)       47 2024-07-11 11:53:15.820711 conda-meta/history
│ │  -rw-r--r--   0 uwe        (501) staff       (20)      120 2024-07-11 11:53:14.697827 conda-meta/pixi
│ │  -rw-r--r--   0 uwe        (501) staff       (20)       54 2024-07-11 11:53:15.820499 conda-meta/pixi_env_prefix
│ │  -rw-rw-r--   0 uwe        (501) staff       (20)     2364 2024-06-25 14:01:31.000000 bin/activate
│ │  -rw-rw-r--   0 uwe        (501) staff       (20)      878 2024-06-25 14:01:31.000000 bin/deactivate
│ │  -rw-rw-r--   0 uwe        (501) staff       (20)     1830 2024-06-25 14:01:31.000000 bin/activate.fish
│ │ --rwx--x--x   0 uwe        (501) staff       (20)    67224 2024-07-11 11:53:42.524505 bin/conda-unpack
│ │ +-rwx--x--x   0 uwe        (501) staff       (20)    67224 2024-07-11 11:54:00.139150 bin/conda-unpack

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type::bug describes erroneous operation, use severity::* to classify the type
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

2 participants