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

Q: Programatically detect if 'conda-unpack' has already been executed? #216

Open
HenrikBengtsson opened this issue Apr 13, 2022 · 3 comments
Labels
source::community catch-all for issues filed by community members stale::recovered [bot] recovered after being marked as stale type::support neither a bug nor feature, is really just a user having questions or difficulty somewhere

Comments

@HenrikBengtsson
Copy link

On https://conda.github.io/conda-pack/ it says:

Once an environment is unpacked and conda-unpack has been executed, it cannot be relocated. Re-applying conda-pack is unlikely to work.

Is there a way to programmatically detect whether or not conda-unpack has already been executed?

@travishathaway travishathaway added source::community catch-all for issues filed by community members type::support neither a bug nor feature, is really just a user having questions or difficulty somewhere labels May 4, 2022
@github-actions
Copy link

Hi there, thank you for your contribution!

This issue has been automatically marked as stale because it has not had recent activity. It will be closed automatically if no further activity occurs.

If you would like this issue to remain open please:

  1. Verify that you can still reproduce the issue at hand
  2. Comment that the issue is still reproducible and include:
    - What OS and version you reproduced the issue on
    - What steps you followed to reproduce the issue

NOTE: If this issue was closed prematurely, please leave a comment.

Thanks!

@github-actions github-actions bot added the stale [bot] marked as stale due to inactivity label May 26, 2022
@HenrikBengtsson
Copy link
Author

ping

@github-actions github-actions bot added stale::recovered [bot] recovered after being marked as stale and removed stale [bot] marked as stale due to inactivity labels May 27, 2022
@djhoese
Copy link

djhoese commented Jun 11, 2022

I'm interested in this functionality as well. What I've been doing is building a tarball with conda-pack and having all bash script utilities I place in it run conda-unpack and write a <prefix>/.installed file that contains the absolute prefix path. Then any future executions I check if the .installed path doesn't match the current prefix I rerun conda-unpack. However, as mentioned in the documentation, this doesn't actually update the files that were updated in the initial execution.

I wonder if conda-pack could bundle a "package data" file that serves the same purpose as my .installed file. Theoretically this should give it all the information needed to know if it should run again. I think you could even use conda post-link scripts to create the initial version of this file with the conda environment's path: https://docs.conda.io/projects/conda-build/en/latest/resources/link-scripts.html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
source::community catch-all for issues filed by community members stale::recovered [bot] recovered after being marked as stale type::support neither a bug nor feature, is really just a user having questions or difficulty somewhere
Projects
Status: No status
Development

No branches or pull requests

3 participants