common-workflow-language / common-workflow-language/cwltool

Apptainer images without entrypoint not working

Open
#2,236 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
376
Forks
255
Avg merge
2d 7h
Merged PRs (30d)
12

Description

This PR https://github.com/common-workflow-language/cwltool/pull/2065 seems to be breaking Apptainer/Singularity images that don't have a runscript. I had been using cwltool version 3.1.20240112164112 for quite awhile and recently upgraded and am now seeing failures on workflows that use Apptainer images that do not provide runscripts. The main difference I see is that where previously cwltool was using `singularity exec` it is now using `singularity run`, which makes me suspect that PR. The specific error I am receiving is

```
/bin/zip: /bin/zip: cannot execute binary file
```
where the workflow step in question is simply creating a zip of several input files. From what I'm reading about Apptainer/Singularity it sounds like this error could be due to multiple different things (architecture mismatch, corrupted image, etc.), but the only one I'm seeing that makes sense to me is the lack of a runscript. My zip image does not have a runscript and the corresponding CWL file defines the baseCommand like so:

```
baseCommand: ["zip"]
```

I do not encounter this error on 3.1.20240112164112 when using the exact same image and the exact same CWL file. I only encounter it after upgrading to a version released after that PR.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.