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

Check singularity image already cached #101

Merged
merged 1 commit into from
May 17, 2023
Merged

Conversation

manabuishii
Copy link
Contributor

If there is already exists singularity image under cache directory , singularity pull causes error.
To avoid error, check whether singularity image is exists or not.

@mr-c
Copy link
Member

mr-c commented Sep 29, 2021

Thanks @manabuishii !

Should there be a command line option added to always download?

@manabuishii
Copy link
Contributor Author

@mr-c Thanks !
Is --force-download good name for command line option ?

@codecov
Copy link

codecov bot commented Sep 29, 2021

Codecov Report

Merging #101 (111d979) into main (eb89df4) will decrease coverage by 15.19%.
The diff coverage is 33.33%.

❗ Current head 111d979 differs from pull request most recent head 59c0cea. Consider uploading reports for the commit 59c0cea to get more accurate results

@@             Coverage Diff             @@
##             main     #101       +/-   ##
===========================================
- Coverage   40.92%   25.74%   -15.19%     
===========================================
  Files          30       16       -14     
  Lines       23519    19627     -3892     
  Branches     6656        0     -6656     
===========================================
- Hits         9625     5052     -4573     
- Misses      11820    14575     +2755     
+ Partials     2074        0     -2074     
Impacted Files Coverage Δ
cwl_utils/image_puller.py 88.23% <33.33%> (+1.13%) ⬆️

... and 34 files with indirect coverage changes

@mr-c
Copy link
Member

mr-c commented Sep 29, 2021

@mr-c Thanks !
Is --force-download good name for command line option ?

Yes!

@stevekm
Copy link

stevekm commented May 12, 2022

isn't a feature like this already implemented here?
https://github.com/common-workflow-language/cwltool/blob/ef7cb301a891adaee8255f4c0a28f1712fc54bd0/cwltool/singularity.py#L190-L191
it uses the CWL_SINGULARITY_CACHE env var, maybe that would be good to use for this update as well?

@jfennick
Copy link
Contributor

I've just been affected by this issue, and I can confirm that the fix works. Can we revisit this PR?

If there is already exists singularity image under cache directory , `singularity pull` causes error.
To avoid error, check whether singularity image is exists or not.

Co-authored-by: Michael R. Crusoe <michael.crusoe@gmail.com>
@mr-c mr-c force-pushed the check_singularity_image branch from 111d979 to 59c0cea Compare May 17, 2023 16:47
@mr-c mr-c enabled auto-merge (rebase) May 17, 2023 16:47
@mr-c mr-c merged commit c7ca466 into main May 17, 2023
@mr-c mr-c deleted the check_singularity_image branch May 17, 2023 16:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants