Question: cwltool issue using SoftwareRequirement
0
gravatar for sf21
9 months ago by
sf2110
New York
sf2110 wrote:

I am having trouble executing the cwl script when supplying "SoftwareRequirement" hints. Tried the below code using both modules (--beta-dependency-resolvers-configuration) and conda (--beta-conda-dependencies). The script works when i provide the complete path to the tool in baseCommand. I am not sure what i am doing wrong. Any feedback is appreciated. thanks!

Tried with cwl version: 1.0.20180809224403

Partial stack trace. The rest was just output from conda. I can update if you think its relevant.

openjdk-8.0.12 100% |##############################################################| Time: 0:00:01  59.85 MB/s
rtg-tools-3.8. 100% |##############################################################| Time: 0:00:00  15.25 MB/s
Extracting packages ...
[      COMPLETE      ]|#################################################################################| 100%
Linking packages ...
[      COMPLETE      ]|#################################################################################| 100%
#
# To activate this environment, use:
# > source activate __rtg-tools@3.8.2
#
# To deactivate this environment, use:
# > source deactivate __rtg-tools@3.8.2
#

Exception while running job
Traceback (most recent call last):
  File "/nethome/usevani/miniconda2/lib/python2.7/site-packages/cwltool/job.py", line 278, in _execute
    name=self.name
  File "/nethome/usevani/miniconda2/lib/python2.7/site-packages/cwltool/job.py", line 575, in _job_popen
    mode="wb") as job_file:
ValueError: binary mode doesn't take an encoding argument
[job rtg.cwl] completed permanentFail
{}
Final process status is permanentFail

CWL script.

cwlVersion: v1.0
class: CommandLineTool
baseCommand: rtg

requirements:
  EnvVarRequirement:
    envDef:
      TOIL_GRIDENGINE_PE: smp

hints:
  SoftwareRequirement:
    packages:
    - package: 'rtg'
      version:
      - '3.8.2'
      specs:
      - https://anaconda.org/bioconda/rtg-tools

arguments:
- valueFrom: vcfeval
  position: 2
- valueFrom: 20G
  position: 1
  prefix: RTG_MEM=
  separate: false
- valueFrom: "$(runtime.outdir)/out"
  prefix: -o
  position: 3
- valueFrom: $(runtime.cores)
  prefix: -T
  position: 4

inputs:
  rtg_reference:
    type: Directory
    inputBinding:
      position: 5
      prefix: -t
  gold_standard:
    type: File
    inputBinding:
      position: 6
      prefix: -b
    secondaryFiles:
    - .tbi
    doc: Genome-In-A-Bottle gold start VCF.
  input:
    type: File
    inputBinding:
      position: 7
      prefix: -c
    secondaryFiles:
    - .tbi
    doc: input compressed and index VCF
  all_records:
    type: boolean
    inputBinding:
      position: 8
      prefix: --all-records
  sample_names:
    type: string
    inputBinding:
      prefix: --sample=
      separate: false
      position: 9
  evaluation_regions:
    type: File
    inputBinding:
      prefix: --evaluation-regions=
      separate: false
      position: 10

outputs:
  output:
    type: Directory
    outputBinding:
      glob: "$(runtime.outdir)/out"
tool cwl cwltool • 478 views
ADD COMMENTlink modified 9 months ago • written 9 months ago by sf2110
0
gravatar for Michael R. Crusoe
9 months ago by
Common Workflow Language project
Michael R. Crusoe1.6k wrote:

Hello h.mon,

When I've had this issue in the past I've fixed it by running cwltool inside a Python 2.7 virtualenv. But this is a bug, so I've opened an issue at https://github.com/common-workflow-language/cwltool/issues/954 to track it.

Thanks!

ADD COMMENTlink written 9 months ago by Michael R. Crusoe1.6k
0
gravatar for sf21
9 months ago by
sf2110
New York
sf2110 wrote:

Thanks for replying and opening a ticket. This is working in cwltool version 1.0.20181012180214 and Python version 3.5.5. In Python 2.7, i am able to run using conda (--beta-conda-dependencies) but not using modules (--beta-dependency-resolvers-configuration).

ADD COMMENTlink written 9 months ago by sf2110
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 540 users visited in the last hour