Download: Trim explicit registries#2403
Conversation
dcddd08 to
d194033
Compare
Codecov Report
@@ Coverage Diff @@
## dev #2403 +/- ##
==========================================
- Coverage 71.23% 71.07% -0.17%
==========================================
Files 87 87
Lines 9415 9431 +16
==========================================
- Hits 6707 6703 -4
- Misses 2708 2728 +20
|
|
Also, can we mix and match registries? [edit] Oh I see, by running twice. |
|
What do you mean by mix and match registries? An absolute URI is not automatically tried (unless that registry was anyway specified with e.g. |
|
I would personally prefer option 1 because this is consistent with the docker API, but then again I don't use Singularity. The code itself looks fine. |
|
@mirpedrol @mashehu - do you have a preference for either of the two? |
|
Option 1 looks more intuitive to me, modules with absolute URIs will usually be from a registry different from |
…he registries to test.
…lute URIs instead of trimming explicit registries.
db04dd6 to
976ddf4
Compare
|
So, I have now implemented the requested changes to Additionally, I have also added the |
|
Nice work (again!) |
Co-authored-by: Júlia Mir Pedrol <mirp.julia@gmail.com>
Issue
Some pipelines respectively modules use full-length URIs such as
quay.io/qiime2/core:2022.11when referencing the Docker container image.Such URIs were not properly accounted for when the new
-l/--container-libraryfeature for tools 2.9 was devised. This prevented the user from successfully pulling the images, because the registry was duplicated in the final URI as is exemplified withnf-core download ampliseq -r '2.6.1' -s 'singularity' -t:Approach
In general, three possible solutions to this problem exist:
-l/--container-libraryarguments for full length URIs.-l/--container-libraryarguments while ignoring any module-specified registry.-l/--container-libraryprovided ones.All in all, option 2 was chosen.
If changes were required after pipeline publication, for example due to the migration to another registry, option 1 would have prevented any. Option 3 would have posed the challenge of interfering with the items to loop over during the loop execution itself, with merely questionable benefits for the UX. Although it would have allowed for more instant successful downloads than any other approach, silently adding another container registry would also have been dangerous, as it would have enabled URI hijacking for other modules in a pipeline.
Therefore, option 2 was ultimately implemented. It eliminates a possible registry automatically to avoid duplications and fixes most download issues, since far the most explicit registries in nf-core modules are
quay.ioanddocker.io. An INFO message with the module-specified registry is printed to the screen, so that a user can retry the download with said registry as explicit argument.PR checklist
CHANGELOG.mdis updateddocsis updated