Unable to run the n4s imaging workflow. Inputs are apparently of the wrong type

I am attempting literally the first step of the imaging workflow, described here: Part 2: Run nf-core/molkart - training.nextflow.io

I have cloned the pipeline and edited the nextflow.config to enable docker. I then attempted to run the command I have been provided.

nextflow run ./molkart \
  --input 'data/samplesheet.csv' \
  --mindagap_tilesize 90 \
  --mindagap_boxsize 7 \
  --mindagap_loopnum 100 \
  --clahe_pyramid_tile 368 \
  --segmentation_method "cellpose,mesmer,stardist" \
  --outdir results

The instructions suggest that this should work now, but I receive the following error:

ERROR ~ Validation of pipeline parameters failed!

-- Check ‘.nextflow.log’ file for details
The following invalid input values have been detected:

  • --mindagap_loopnum (100): Value is [string] but should be [integer]
  • --clahe_pyramid_tile (368): Value is [string] but should be [integer]
  • --mindagap_tilesize (90): Value is [string] but should be [integer]
  • --mindagap_boxsize (7): Value is [string] but should be [integer]

I have looked into the module and (sub)workflow dirs and I cannot even find the processes that are using these parameters. I do not know how to force nextflow to interpret them as integers.

Oh that’s a documentation fail, sorry. That tutorial is also using the v1 syntax, like the nf-core tutorial. You need to run export NXF_SYNTAX_PARSER=v1 to set the training environment correctly.

This is because nf-core pipelines aren’t yet updated to use V2 syntax (typed params and workflow outputs).

See Nextflow versions - training.nextflow.io for more context info.