-
Notifications
You must be signed in to change notification settings - Fork 638
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
Singularity 4 OCI : fix for working directory #4484
Conversation
Signed-off-by: Paolo Di Tommaso <[email protected]>
Signed-off-by: Paolo Di Tommaso <[email protected]>
Signed-off-by: Paolo Di Tommaso <[email protected]>
Signed-off-by: Paolo Di Tommaso <[email protected]>
Signed-off-by: Paolo Di Tommaso <[email protected]>
Signed-off-by: Paolo Di Tommaso <[email protected]>
Signed-off-by: Paolo Di Tommaso <[email protected]>
Signed-off-by: Dr Marco Claudio De La Pierre <[email protected]>
Signed-off-by: Paolo Di Tommaso <[email protected]>
Signed-off-by: Paolo Di Tommaso <[email protected]>
Signed-off-by: Paolo Di Tommaso <[email protected]>
Signed-off-by: Paolo Di Tommaso <[email protected]>
Signed-off-by: Paolo Di Tommaso <[email protected]>
Signed-off-by: Dr Marco Claudio De La Pierre <[email protected]>
Not sure to understand what this solves? In my tests doesn't look it is needed |
Practical example: try and run the pipeline Root cause, the conditional to nextflow/modules/nextflow/src/main/groovy/nextflow/executor/BashWrapperBuilder.groovy Lines 481 to 489 in 4b4e3df
Here Why does this happen in OCI mode? Because in this mode the work dir for the container is not the host PWD any more, similar to Docker. To compensate for this behavioural change, devs have introduced the This is what I have implemented in this PR. |
Interesting. so this is essentially the same as If so, I do not understand why most of the pipeline works. Also, instead of introducing a OCI specific flag, it may be preferable to keep the Third (unrelated this PR changes), not understanding why in the condition |
These 4 CI errors are all of the same kind:
They come out of the execution of multiqc in the test, which fails with:
@pditommaso thoughts? |
exactly
Singularity always changes dir to the host current dir by default, and so Why There is a problem with
whereas when
The problem is, when That's why in the case of In all of this, I myself have no understanding of how those conditionals were born, hence I went for the most conservative change, that would not break previous runs while being able to execute the OCI mode correctly.
as above, I myself have no idea of the origin of it. |
Oh I forgot,
|
Let's go for this. It's more self-documenting what's needed for |
Indeed. However I think the overall idea was that this bash is only needed to evaluate the container env. But, later the Maybe this can be more consistent
|
While implementing the change, I realised why the conditional has
and, as above, for both commands to execute within the containers, the bash wrapping is required! I have paraphrased your suggestion to make this reasoning visible from the code itself: [edit]: nope this is wrong, it changes the logic! reverted to your syntax
|
…D changed to NXF_TASK_WORKDIR Signed-off-by: Dr Marco Claudio De La Pierre <[email protected]>
I have also found the cause of the failing CI tests.... the rnaseq-nf container https://github.com/nextflow-io/rnaseq-nf/edit/master/docker/Dockerfile unfortunately when installing with micromamba, there are some issues with the installation with |
Yeah, it seems multiqc, but @ewels was mentioning version 1.17 should solve |
…ated flags Signed-off-by: Dr Marco Claudio De La Pierre <[email protected]>
OK @pditommaso , last commit, to include all substitutions of PWD into NXF_TASK_WORKDIR for container related flags. Done cum grano salis .
|
This one is ready for review. Two sets of changes:
|
Signed-off-by: Paolo Di Tommaso <[email protected]>
Signed-off-by: Paolo Di Tommaso <[email protected]>
✅ Deploy Preview for nextflow-docs-staging canceled.
|
Signed-off-by: Paolo Di Tommaso <[email protected]>
Fix for OCI behaviour for current directory, including unit tests
Tested with
rnaseq-nf
andblast-example
, both in OCI and standard modes