Build branch main with version main (32dc807)

Build pipeline: viash-hub.playground.main-n876l

Source commit: 32dc80723a

Source message: Emtpy commit
This commit is contained in:
CI
2025-02-26 15:29:31 +00:00
parent fbf20cbd8a
commit c0bd36f2eb
5 changed files with 73 additions and 46 deletions

View File

@@ -7,7 +7,7 @@ links:
issue_tracker: https://github.com/viash-hub/playground/issues issue_tracker: https://github.com/viash-hub/playground/issues
repository: https://github.com/viash-hub/playground repository: https://github.com/viash-hub/playground
viash_version: 0.9.0-RC6 viash_version: 0.9.0
config_mods: | config_mods: |
.requirements.commands := ['ps'] .requirements.commands := ['ps']

View File

@@ -1,5 +1,6 @@
name: mapping_and_qc name: mapping_and_qc
description: Run STAR and QC description: Run STAR and QC
argument_groups: argument_groups:
- name: Input arguments - name: Input arguments
arguments: arguments:
@@ -27,7 +28,6 @@ resources:
path: main.nf path: main.nf
entrypoint: run_wf entrypoint: run_wf
dependencies: dependencies:
- name: cutadapt - name: cutadapt
repository: bb repository: bb
@@ -45,6 +45,7 @@ repositories:
type: vsh type: vsh
repo: vsh/biobox repo: vsh/biobox
tag: main tag: main
runners: runners:
- type: nextflow - type: nextflow

View File

@@ -161,8 +161,8 @@ build_info:
engine: "native|native" engine: "native|native"
output: "target/nextflow/mapping_and_qc" output: "target/nextflow/mapping_and_qc"
executable: "target/nextflow/mapping_and_qc/main.nf" executable: "target/nextflow/mapping_and_qc/main.nf"
viash_version: "0.9.0-RC6" viash_version: "0.9.0"
git_commit: "d87d344d4e46dc6f938e57a009607946ed31447c" git_commit: "32dc80723acb5d5861c7acd7c6c07ef4cd1a6ee7"
git_remote: "https://github.com/viash-hub/playground" git_remote: "https://github.com/viash-hub/playground"
dependencies: dependencies:
- "target/dependencies/vsh/vsh/biobox/main/nextflow/cutadapt" - "target/dependencies/vsh/vsh/biobox/main/nextflow/cutadapt"
@@ -176,7 +176,7 @@ package_config:
description: "A collection of bioinformatics pipelines to illustrate the use of\ description: "A collection of bioinformatics pipelines to illustrate the use of\
\ biobox (and biotools).\n" \ biobox (and biotools).\n"
info: null info: null
viash_version: "0.9.0-RC6" viash_version: "0.9.0"
source: "src" source: "src"
target: "target" target: "target"
config_mods: config_mods:

View File

@@ -1,8 +1,8 @@
// mapping_and_qc main // mapping_and_qc main
// //
// This wrapper script is auto-generated by viash 0.9.0-RC6 and is thus a // This wrapper script is auto-generated by viash 0.9.0 and is thus a derivative
// derivative work thereof. This software comes with ABSOLUTELY NO WARRANTY from // work thereof. This software comes with ABSOLUTELY NO WARRANTY from Data
// Data Intuitive. // Intuitive.
// //
// The component may contain files which fall under a different license. The // The component may contain files which fall under a different license. The
// authors of this component should specify the license in the header of such // authors of this component should specify the license in the header of such
@@ -760,8 +760,11 @@ def runEach(Map args) {
def fromState_ = args.fromState def fromState_ = args.fromState
def toState_ = args.toState def toState_ = args.toState
def filter_ = args.filter def filter_ = args.filter
def runIf_ = args.runIf
def id_ = args.id def id_ = args.id
assert !runIf_ || runIf_ instanceof Closure: "runEach: must pass a Closure to runIf."
workflow runEachWf { workflow runEachWf {
take: input_ch take: input_ch
main: main:
@@ -783,7 +786,20 @@ def runEach(Map args) {
[new_id] + tup.drop(1) [new_id] + tup.drop(1)
} }
: filter_ch : filter_ch
def data_ch = id_ch | map{tup -> def chPassthrough = null
def chRun = null
if (runIf_) {
def idRunIfBranch = id_ch.branch{ tup ->
run: runIf_(tup[0], tup[1], comp_)
passthrough: true
}
chPassthrough = idRunIfBranch.passthrough
chRun = idRunIfBranch.run
} else {
chRun = id_ch
chPassthrough = Channel.empty()
}
def data_ch = chRun | map{tup ->
def new_data = tup[1] def new_data = tup[1]
if (fromState_ instanceof Map) { if (fromState_ instanceof Map) {
new_data = fromState_.collectEntries{ key0, key1 -> new_data = fromState_.collectEntries{ key0, key1 ->
@@ -822,7 +838,10 @@ def runEach(Map args) {
} }
: out_ch : out_ch
post_ch def return_ch = post_ch
| concat(chPassthrough)
return_ch
} }
// mix all results // mix all results
@@ -1598,8 +1617,8 @@ def findStates(Map params, Map config) {
// construct renameMap // construct renameMap
if (args.rename_keys) { if (args.rename_keys) {
def renameMap = args.rename_keys.collectEntries{renameString -> def renameMap = args.rename_keys.collectEntries{renameString ->
def split = renameString.split(";") def split = renameString.split(":")
assert split.size() == 2: "Argument 'rename_keys' should be of the form 'newKey:oldKey,newKey:oldKey'" assert split.size() == 2: "Argument 'rename_keys' should be of the form 'newKey:oldKey', or 'newKey:oldKey;newKey:oldKey' in case of multiple values"
split split
} }
@@ -1709,7 +1728,9 @@ def publishStates(Map args) {
def yamlFilename = yamlTemplate_ def yamlFilename = yamlTemplate_
.replaceAll('\\$id', id_) .replaceAll('\\$id', id_)
.replaceAll('\\$\\{id\\}', id_)
.replaceAll('\\$key', key_) .replaceAll('\\$key', key_)
.replaceAll('\\$\\{key\\}', key_)
// TODO: do the pathnames in state_ match up with the outputFilenames_? // TODO: do the pathnames in state_ match up with the outputFilenames_?
@@ -1780,7 +1801,9 @@ def publishStatesByConfig(Map args) {
def yamlTemplate = params.containsKey("output_state") ? params.output_state : '$id.$key.state.yaml' def yamlTemplate = params.containsKey("output_state") ? params.output_state : '$id.$key.state.yaml'
def yamlFilename = yamlTemplate def yamlFilename = yamlTemplate
.replaceAll('\\$id', id_) .replaceAll('\\$id', id_)
.replaceAll('\\$\\{id\\}', id_)
.replaceAll('\\$key', key_) .replaceAll('\\$key', key_)
.replaceAll('\\$\\{key\\}', key_)
def yamlDir = java.nio.file.Paths.get(yamlFilename).getParent() def yamlDir = java.nio.file.Paths.get(yamlFilename).getParent()
// the processed state is a list of [key, value, inputPath, outputFilename] tuples, where // the processed state is a list of [key, value, inputPath, outputFilename] tuples, where
@@ -1822,7 +1845,9 @@ def publishStatesByConfig(Map args) {
// instantiate the template // instantiate the template
def filename = filenameTemplate def filename = filenameTemplate
.replaceAll('\\$id', id_) .replaceAll('\\$id', id_)
.replaceAll('\\$\\{id\\}', id_)
.replaceAll('\\$key', key_) .replaceAll('\\$key', key_)
.replaceAll('\\$\\{key\\}', key_)
if (par.multiple) { if (par.multiple) {
// if the parameter is multiple: true, the filename // if the parameter is multiple: true, the filename
// should contain a wildcard '*' that is replaced with // should contain a wildcard '*' that is replaced with
@@ -2626,30 +2651,31 @@ def workflowFactory(Map args, Map defaultWfArgs, Map meta) {
tuple tuple
} }
def chModifiedFiltered = workflowArgs.filter ?
chModified | filter{workflowArgs.filter(it)} :
chModified
def chRun = null def chRun = null
def chPassthrough = null def chPassthrough = null
if (workflowArgs.runIf) { if (workflowArgs.runIf) {
def runIfBranch = chModifiedFiltered.branch{ tup -> def runIfBranch = chModified.branch{ tup ->
run: workflowArgs.runIf(tup[0], tup[1]) run: workflowArgs.runIf(tup[0], tup[1])
passthrough: true passthrough: true
} }
chRun = runIfBranch.run chRun = runIfBranch.run
chPassthrough = runIfBranch.passthrough chPassthrough = runIfBranch.passthrough
} else { } else {
chRun = chModifiedFiltered chRun = chModified
chPassthrough = Channel.empty() chPassthrough = Channel.empty()
} }
def chRunFiltered = workflowArgs.filter ?
chRun | filter{workflowArgs.filter(it)} :
chRun
def chArgs = workflowArgs.fromState ? def chArgs = workflowArgs.fromState ?
chRun | map{ chRunFiltered | map{
def new_data = workflowArgs.fromState(it.take(2)) def new_data = workflowArgs.fromState(it.take(2))
[it[0], new_data] [it[0], new_data]
} : } :
chRun | map {tup -> tup.take(2)} chRunFiltered | map {tup -> tup.take(2)}
// fill in defaults // fill in defaults
def chArgsWithDefaults = chArgs def chArgsWithDefaults = chArgs
@@ -2720,7 +2746,7 @@ def workflowFactory(Map args, Map defaultWfArgs, Map meta) {
// | view{"chInitialOutput: ${it.take(3)}"} // | view{"chInitialOutput: ${it.take(3)}"}
// join the output [prev_id, new_id, output] with the previous state [prev_id, state, ...] // join the output [prev_id, new_id, output] with the previous state [prev_id, state, ...]
def chNewState = safeJoin(chInitialOutput, chModifiedFiltered, key_) def chNewState = safeJoin(chInitialOutput, chRunFiltered, key_)
// input tuple format: [join_id, id, output, prev_state, ...] // input tuple format: [join_id, id, output, prev_state, ...]
// output tuple format: [join_id, id, new_state, ...] // output tuple format: [join_id, id, new_state, ...]
| map{ tup -> | map{ tup ->
@@ -2988,15 +3014,15 @@ meta = [
"runner" : "nextflow", "runner" : "nextflow",
"engine" : "native|native", "engine" : "native|native",
"output" : "target/nextflow/mapping_and_qc", "output" : "target/nextflow/mapping_and_qc",
"viash_version" : "0.9.0-RC6", "viash_version" : "0.9.0",
"git_commit" : "d87d344d4e46dc6f938e57a009607946ed31447c", "git_commit" : "32dc80723acb5d5861c7acd7c6c07ef4cd1a6ee7",
"git_remote" : "https://github.com/viash-hub/playground" "git_remote" : "https://github.com/viash-hub/playground"
}, },
"package_config" : { "package_config" : {
"name" : "playground", "name" : "playground",
"version" : "main", "version" : "main",
"description" : "A collection of bioinformatics pipelines to illustrate the use of biobox (and biotools).\n", "description" : "A collection of bioinformatics pipelines to illustrate the use of biobox (and biotools).\n",
"viash_version" : "0.9.0-RC6", "viash_version" : "0.9.0",
"source" : "src", "source" : "src",
"target" : "target", "target" : "target",
"config_mods" : [ "config_mods" : [

View File

@@ -15,18 +15,18 @@ if [ ! -f "$TEST_DATA_DIR/SRR1570800_1.fastq" ] || [ ! -f "$TEST_DATA_DIR/SRR157
docker run -t --rm -v $PWD:/output:rw -w /output/test_data ncbi/sra-tools fasterq-dump -e 2 -p SRR1570800 docker run -t --rm -v $PWD:/output:rw -w /output/test_data ncbi/sra-tools fasterq-dump -e 2 -p SRR1570800
fi fi
head -n 10000 "$TEST_DATA_DIR/SRR1569895_1.fastq" > "$TEST_DATA_DIR/SRR1569895_1_subsample.fastq" head -n 10000 "$TEST_DATA_DIR/SRR1569895_1.fastq" >"$TEST_DATA_DIR/SRR1569895_1_subsample.fastq"
head -n 10000 "$TEST_DATA_DIR/SRR1569895_2.fastq" > "$TEST_DATA_DIR/SRR1569895_2_subsample.fastq" head -n 10000 "$TEST_DATA_DIR/SRR1569895_2.fastq" >"$TEST_DATA_DIR/SRR1569895_2_subsample.fastq"
head -n 10000 "$TEST_DATA_DIR/SRR1570800_1.fastq" > "$TEST_DATA_DIR/SRR1570800_1_subsample.fastq" head -n 10000 "$TEST_DATA_DIR/SRR1570800_1.fastq" >"$TEST_DATA_DIR/SRR1570800_1_subsample.fastq"
head -n 10000 "$TEST_DATA_DIR/SRR1570800_2.fastq" > "$TEST_DATA_DIR/SRR1570800_2_subsample.fastq" head -n 10000 "$TEST_DATA_DIR/SRR1570800_2.fastq" >"$TEST_DATA_DIR/SRR1570800_2_subsample.fastq"
export NXF_SCM_FILE="$TEST_DATA_DIR/scm.config" export NXF_SCM_FILE="$TEST_DATA_DIR/scm.config"
cat > $NXF_SCM_FILE << EOF cat >$NXF_SCM_FILE <<EOF
providers { providers {
vsh { vsh {
platform = 'gitlab' platform = 'gitlab'
server = 'https://viash-hub.com/' server = 'https://packages.viash-hub.com/'
} }
} }
EOF EOF
@@ -44,8 +44,8 @@ if [ ! -d "$TEST_DATA_DIR/S288C_reference_genome_Current_Release" ]; then
--publish_dir "$TEST_DATA_DIR" --publish_dir "$TEST_DATA_DIR"
fi fi
gunzip -c "$TEST_DATA_DIR/S288C_reference_genome_Current_Release/S288C_reference_sequence_R64-5-1_20240529.fsa.gz" > "$TEST_DATA_DIR/S288C_reference_genome_Current_Release/S288C_reference_sequence_R64-5-1_20240529.fsa" gunzip -c "$TEST_DATA_DIR/S288C_reference_genome_Current_Release/S288C_reference_sequence_R64-5-1_20240529.fsa.gz" >"$TEST_DATA_DIR/S288C_reference_genome_Current_Release/S288C_reference_sequence_R64-5-1_20240529.fsa"
gunzip -c "$TEST_DATA_DIR/S288C_reference_genome_Current_Release/saccharomyces_cerevisiae_R64-5-1_20240529.gff.gz" > "$TEST_DATA_DIR/S288C_reference_genome_Current_Release/saccharomyces_cerevisiae_R64-5-1_20240529.gff" gunzip -c "$TEST_DATA_DIR/S288C_reference_genome_Current_Release/saccharomyces_cerevisiae_R64-5-1_20240529.gff.gz" >"$TEST_DATA_DIR/S288C_reference_genome_Current_Release/saccharomyces_cerevisiae_R64-5-1_20240529.gff"
sed -i -e 's/^.*chromosome=\(.*\)\]$/>chr\1/' "$TEST_DATA_DIR/S288C_reference_genome_Current_Release/S288C_reference_sequence_R64-5-1_20240529.fsa" sed -i -e 's/^.*chromosome=\(.*\)\]$/>chr\1/' "$TEST_DATA_DIR/S288C_reference_genome_Current_Release/S288C_reference_sequence_R64-5-1_20240529.fsa"
if [ ! -d "$TEST_DATA_DIR/S288C_reference_genome_Current_Release_STAR" ]; then if [ ! -d "$TEST_DATA_DIR/S288C_reference_genome_Current_Release_STAR" ]; then
@@ -61,7 +61,7 @@ if [ ! -d "$TEST_DATA_DIR/S288C_reference_genome_Current_Release_STAR" ]; then
fi fi
PARAMS_FILE=params_file.yaml PARAMS_FILE=params_file.yaml
cat > $PARAMS_FILE << EOF cat >$PARAMS_FILE <<EOF
param_list: param_list:
- id: SRR1569895 - id: SRR1569895
input_r1: $TEST_DATA_DIR/SRR1569895_1_subsample.fastq input_r1: $TEST_DATA_DIR/SRR1569895_1_subsample.fastq