versions.yml-generating code produce malformed files without the nf-module failing #6696
Open
2 tasks done
Labels
bug
Something isn't working
Have you checked the docs?
Description of the bug
As described here, the
versions.yml
-generating code in the modules may produce malformed files without the module failing. The problem has only been observed with singularity.Due to "instability" of the underlying system (HPC), it may happen that the call to a "tool" in a module-script finishes correctly while the subsequent call to
<tool> --version
in theversions.yml
-generating code fails. That will result in an invalidversions.yml
-file (it contains an error message) but the execution of the module hasn't failed. (That is basically due to the fact that a BASH-command likeecho $(foo 2>&1) > versions.yml
gives an exit code 0 regardless of the fact that the callfoo
may give a non-zero exit code.)In such cases, it will not help re-running the pipeline with
-resume
, since the module execution didn't fail, it wouldn't be re-run and a newversions.yml
-file wont be produced. (A user, who understands the problem, can fix theversions.yml
-file manually, but that is not ideal.)Locally, we've overcame the problem by (1) hardcoding the version-numbers in the
versions.yml
-generating code or (2) moving theversions.yml
-generating code to the top of the script-section in the modules. (But those "solutions" are of course not ideal.)The issue has been discussed here: https://nfcore.slack.com/archives/CE5LG7WMB/p1727099518643229
It was proposed that the
versions.yml
-generating code could perhaps be changed to something likebut that doesn't work for all tools as illustrated here.
If it is decided to change the
versions.yml
-generating code, then I guess a module template somewhere has to be changed as well.Command used and terminal output
No response
Relevant files
No response
System information
No response
The text was updated successfully, but these errors were encountered: