Build branch main with version main (a948c26)
Build pipeline: viash-hub.htrnaseq.main-qpqxt
Source commit: a948c26193
Source message: Bump viash to 0.9.4 (#51)
This commit is contained in:
@@ -200,8 +200,8 @@ build_info:
|
||||
engine: "docker|native"
|
||||
output: "target/nextflow/stats/combine_star_logs"
|
||||
executable: "target/nextflow/stats/combine_star_logs/main.nf"
|
||||
viash_version: "0.9.2"
|
||||
git_commit: "cb58990a33f6ea6e46e474f2095b10218cf08912"
|
||||
viash_version: "0.9.4"
|
||||
git_commit: "a948c261931dbb784fc9ce6f7d5d93f52008a99f"
|
||||
git_remote: "https://github.com/viash-hub/htrnaseq"
|
||||
package_config:
|
||||
name: "htrnaseq"
|
||||
@@ -211,7 +211,7 @@ package_config:
|
||||
test_resources:
|
||||
- path: "gs://viash-hub-test-data/htrnaseq/v1/"
|
||||
dest: "resources_test"
|
||||
viash_version: "0.9.2"
|
||||
viash_version: "0.9.4"
|
||||
source: "src"
|
||||
target: "target"
|
||||
config_mods:
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// combine_star_logs main
|
||||
//
|
||||
// This wrapper script is auto-generated by viash 0.9.2 and is thus a derivative
|
||||
// This wrapper script is auto-generated by viash 0.9.4 and is thus a derivative
|
||||
// work thereof. This software comes with ABSOLUTELY NO WARRANTY from Data
|
||||
// Intuitive.
|
||||
//
|
||||
@@ -85,64 +85,56 @@ def _checkArgumentType(String stage, Map par, Object value, String errorIdentifi
|
||||
foundClass = "List[${e.foundClass}]"
|
||||
}
|
||||
} else if (par.type == "string") {
|
||||
// cast to string if need be
|
||||
// cast to string if need be. only cast if the value is a GString
|
||||
if (value instanceof GString) {
|
||||
value = value.toString()
|
||||
value = value as String
|
||||
}
|
||||
expectedClass = value instanceof String ? null : "String"
|
||||
} else if (par.type == "integer") {
|
||||
// cast to integer if need be
|
||||
if (value instanceof String) {
|
||||
if (value !instanceof Integer) {
|
||||
try {
|
||||
value = value.toInteger()
|
||||
value = value as Integer
|
||||
} catch (NumberFormatException e) {
|
||||
// do nothing
|
||||
expectedClass = "Integer"
|
||||
}
|
||||
}
|
||||
if (value instanceof java.math.BigInteger) {
|
||||
value = value.intValue()
|
||||
}
|
||||
expectedClass = value instanceof Integer ? null : "Integer"
|
||||
} else if (par.type == "long") {
|
||||
// cast to long if need be
|
||||
if (value instanceof String) {
|
||||
if (value !instanceof Long) {
|
||||
try {
|
||||
value = value.toLong()
|
||||
value = value as Long
|
||||
} catch (NumberFormatException e) {
|
||||
// do nothing
|
||||
expectedClass = "Long"
|
||||
}
|
||||
}
|
||||
if (value instanceof Integer) {
|
||||
value = value.toLong()
|
||||
}
|
||||
expectedClass = value instanceof Long ? null : "Long"
|
||||
} else if (par.type == "double") {
|
||||
// cast to double if need be
|
||||
if (value instanceof String) {
|
||||
if (value !instanceof Double) {
|
||||
try {
|
||||
value = value.toDouble()
|
||||
value = value as Double
|
||||
} catch (NumberFormatException e) {
|
||||
// do nothing
|
||||
expectedClass = "Double"
|
||||
}
|
||||
}
|
||||
if (value instanceof java.math.BigDecimal) {
|
||||
value = value.doubleValue()
|
||||
} else if (par.type == "float") {
|
||||
// cast to float if need be
|
||||
if (value !instanceof Float) {
|
||||
try {
|
||||
value = value as Float
|
||||
} catch (NumberFormatException e) {
|
||||
expectedClass = "Float"
|
||||
}
|
||||
}
|
||||
if (value instanceof Float) {
|
||||
value = value.toDouble()
|
||||
}
|
||||
expectedClass = value instanceof Double ? null : "Double"
|
||||
} else if (par.type == "boolean" | par.type == "boolean_true" | par.type == "boolean_false") {
|
||||
// cast to boolean if need be
|
||||
if (value instanceof String) {
|
||||
def valueLower = value.toLowerCase()
|
||||
if (valueLower == "true") {
|
||||
value = true
|
||||
} else if (valueLower == "false") {
|
||||
value = false
|
||||
if (value !instanceof Boolean) {
|
||||
try {
|
||||
value = value as Boolean
|
||||
} catch (Exception e) {
|
||||
expectedClass = "Boolean"
|
||||
}
|
||||
}
|
||||
expectedClass = value instanceof Boolean ? null : "Boolean"
|
||||
} else if (par.type == "file" && (par.direction == "input" || stage == "output")) {
|
||||
// cast to path if need be
|
||||
if (value instanceof String) {
|
||||
@@ -154,10 +146,13 @@ def _checkArgumentType(String stage, Map par, Object value, String errorIdentifi
|
||||
expectedClass = value instanceof Path ? null : "Path"
|
||||
} else if (par.type == "file" && stage == "input" && par.direction == "output") {
|
||||
// cast to string if need be
|
||||
if (value instanceof GString) {
|
||||
value = value.toString()
|
||||
if (value !instanceof String) {
|
||||
try {
|
||||
value = value as String
|
||||
} catch (Exception e) {
|
||||
expectedClass = "String"
|
||||
}
|
||||
}
|
||||
expectedClass = value instanceof String ? null : "String"
|
||||
} else {
|
||||
// didn't find a match for par.type
|
||||
expectedClass = par.type
|
||||
@@ -3294,8 +3289,8 @@ meta = [
|
||||
"runner" : "nextflow",
|
||||
"engine" : "docker|native",
|
||||
"output" : "target/nextflow/stats/combine_star_logs",
|
||||
"viash_version" : "0.9.2",
|
||||
"git_commit" : "cb58990a33f6ea6e46e474f2095b10218cf08912",
|
||||
"viash_version" : "0.9.4",
|
||||
"git_commit" : "a948c261931dbb784fc9ce6f7d5d93f52008a99f",
|
||||
"git_remote" : "https://github.com/viash-hub/htrnaseq"
|
||||
},
|
||||
"package_config" : {
|
||||
@@ -3310,7 +3305,7 @@ meta = [
|
||||
}
|
||||
]
|
||||
},
|
||||
"viash_version" : "0.9.2",
|
||||
"viash_version" : "0.9.4",
|
||||
"source" : "src",
|
||||
"target" : "target",
|
||||
"config_mods" : [
|
||||
@@ -3344,7 +3339,7 @@ meta = [
|
||||
// inner workflow hook
|
||||
def innerWorkflowFactory(args) {
|
||||
def rawScript = '''set -e
|
||||
tempscript=".viash_script.sh"
|
||||
tempscript=".viash_script.py"
|
||||
cat > "$tempscript" << VIASHMAIN
|
||||
import logging
|
||||
import pandas as pd
|
||||
@@ -3926,7 +3921,7 @@ def _vdsl3ProcessFactory(Map workflowArgs, Map meta, String rawScript) {
|
||||
// create process from temp file
|
||||
def binding = new nextflow.script.ScriptBinding([:])
|
||||
def session = nextflow.Nextflow.getSession()
|
||||
def parser = new nextflow.script.ScriptParser(session)
|
||||
def parser = _getScriptLoader(session)
|
||||
.setModule(true)
|
||||
.setBinding(binding)
|
||||
def moduleScript = parser.runScript(tempFile)
|
||||
@@ -3940,6 +3935,27 @@ def _vdsl3ProcessFactory(Map workflowArgs, Map meta, String rawScript) {
|
||||
return scriptMeta.getProcess(procKey)
|
||||
}
|
||||
|
||||
// use Reflection to get a ScriptParser / ScriptLoader
|
||||
// <25.02.0-edge: new nextflow.script.ScriptParser(session)
|
||||
// >=25.02.0-edge: nextflow.script.ScriptLoaderFactory.create(session)
|
||||
def _getScriptLoader(nextflow.Session session) {
|
||||
// try using the old method
|
||||
try {
|
||||
Class<?> scriptParserClass = Class.forName('nextflow.script.ScriptParser')
|
||||
return scriptParserClass.getDeclaredConstructor(nextflow.Session).newInstance(session)
|
||||
} catch (ClassNotFoundException e) {
|
||||
// else try with the new method
|
||||
try {
|
||||
Class<?> scriptLoaderFactoryClass = Class.forName('nextflow.script.ScriptLoaderFactory')
|
||||
def createMethod = scriptLoaderFactoryClass.getDeclaredMethod('create', nextflow.Session)
|
||||
return createMethod.invoke(null, session) // null because create is static
|
||||
} catch (ClassNotFoundException | NoSuchMethodException | IllegalAccessException | java.lang.reflect.InvocationTargetException e2) {
|
||||
// Handle the case where neither class is found
|
||||
throw new Exception("Neither nextflow.script.ScriptParser nor nextflow.script.ScriptLoaderFactory could be found. Is this a compatible Nextflow version?", e2)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// defaults
|
||||
meta["defaults"] = [
|
||||
// key to be used to trace the process and determine output names
|
||||
|
||||
@@ -184,8 +184,8 @@ build_info:
|
||||
engine: "docker|native"
|
||||
output: "target/nextflow/stats/generate_pool_statistics"
|
||||
executable: "target/nextflow/stats/generate_pool_statistics/main.nf"
|
||||
viash_version: "0.9.2"
|
||||
git_commit: "cb58990a33f6ea6e46e474f2095b10218cf08912"
|
||||
viash_version: "0.9.4"
|
||||
git_commit: "a948c261931dbb784fc9ce6f7d5d93f52008a99f"
|
||||
git_remote: "https://github.com/viash-hub/htrnaseq"
|
||||
package_config:
|
||||
name: "htrnaseq"
|
||||
@@ -195,7 +195,7 @@ package_config:
|
||||
test_resources:
|
||||
- path: "gs://viash-hub-test-data/htrnaseq/v1/"
|
||||
dest: "resources_test"
|
||||
viash_version: "0.9.2"
|
||||
viash_version: "0.9.4"
|
||||
source: "src"
|
||||
target: "target"
|
||||
config_mods:
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// generate_pool_statistics main
|
||||
//
|
||||
// This wrapper script is auto-generated by viash 0.9.2 and is thus a derivative
|
||||
// This wrapper script is auto-generated by viash 0.9.4 and is thus a derivative
|
||||
// work thereof. This software comes with ABSOLUTELY NO WARRANTY from Data
|
||||
// Intuitive.
|
||||
//
|
||||
@@ -86,64 +86,56 @@ def _checkArgumentType(String stage, Map par, Object value, String errorIdentifi
|
||||
foundClass = "List[${e.foundClass}]"
|
||||
}
|
||||
} else if (par.type == "string") {
|
||||
// cast to string if need be
|
||||
// cast to string if need be. only cast if the value is a GString
|
||||
if (value instanceof GString) {
|
||||
value = value.toString()
|
||||
value = value as String
|
||||
}
|
||||
expectedClass = value instanceof String ? null : "String"
|
||||
} else if (par.type == "integer") {
|
||||
// cast to integer if need be
|
||||
if (value instanceof String) {
|
||||
if (value !instanceof Integer) {
|
||||
try {
|
||||
value = value.toInteger()
|
||||
value = value as Integer
|
||||
} catch (NumberFormatException e) {
|
||||
// do nothing
|
||||
expectedClass = "Integer"
|
||||
}
|
||||
}
|
||||
if (value instanceof java.math.BigInteger) {
|
||||
value = value.intValue()
|
||||
}
|
||||
expectedClass = value instanceof Integer ? null : "Integer"
|
||||
} else if (par.type == "long") {
|
||||
// cast to long if need be
|
||||
if (value instanceof String) {
|
||||
if (value !instanceof Long) {
|
||||
try {
|
||||
value = value.toLong()
|
||||
value = value as Long
|
||||
} catch (NumberFormatException e) {
|
||||
// do nothing
|
||||
expectedClass = "Long"
|
||||
}
|
||||
}
|
||||
if (value instanceof Integer) {
|
||||
value = value.toLong()
|
||||
}
|
||||
expectedClass = value instanceof Long ? null : "Long"
|
||||
} else if (par.type == "double") {
|
||||
// cast to double if need be
|
||||
if (value instanceof String) {
|
||||
if (value !instanceof Double) {
|
||||
try {
|
||||
value = value.toDouble()
|
||||
value = value as Double
|
||||
} catch (NumberFormatException e) {
|
||||
// do nothing
|
||||
expectedClass = "Double"
|
||||
}
|
||||
}
|
||||
if (value instanceof java.math.BigDecimal) {
|
||||
value = value.doubleValue()
|
||||
} else if (par.type == "float") {
|
||||
// cast to float if need be
|
||||
if (value !instanceof Float) {
|
||||
try {
|
||||
value = value as Float
|
||||
} catch (NumberFormatException e) {
|
||||
expectedClass = "Float"
|
||||
}
|
||||
}
|
||||
if (value instanceof Float) {
|
||||
value = value.toDouble()
|
||||
}
|
||||
expectedClass = value instanceof Double ? null : "Double"
|
||||
} else if (par.type == "boolean" | par.type == "boolean_true" | par.type == "boolean_false") {
|
||||
// cast to boolean if need be
|
||||
if (value instanceof String) {
|
||||
def valueLower = value.toLowerCase()
|
||||
if (valueLower == "true") {
|
||||
value = true
|
||||
} else if (valueLower == "false") {
|
||||
value = false
|
||||
if (value !instanceof Boolean) {
|
||||
try {
|
||||
value = value as Boolean
|
||||
} catch (Exception e) {
|
||||
expectedClass = "Boolean"
|
||||
}
|
||||
}
|
||||
expectedClass = value instanceof Boolean ? null : "Boolean"
|
||||
} else if (par.type == "file" && (par.direction == "input" || stage == "output")) {
|
||||
// cast to path if need be
|
||||
if (value instanceof String) {
|
||||
@@ -155,10 +147,13 @@ def _checkArgumentType(String stage, Map par, Object value, String errorIdentifi
|
||||
expectedClass = value instanceof Path ? null : "Path"
|
||||
} else if (par.type == "file" && stage == "input" && par.direction == "output") {
|
||||
// cast to string if need be
|
||||
if (value instanceof GString) {
|
||||
value = value.toString()
|
||||
if (value !instanceof String) {
|
||||
try {
|
||||
value = value as String
|
||||
} catch (Exception e) {
|
||||
expectedClass = "String"
|
||||
}
|
||||
}
|
||||
expectedClass = value instanceof String ? null : "String"
|
||||
} else {
|
||||
// didn't find a match for par.type
|
||||
expectedClass = par.type
|
||||
@@ -3278,8 +3273,8 @@ meta = [
|
||||
"runner" : "nextflow",
|
||||
"engine" : "docker|native",
|
||||
"output" : "target/nextflow/stats/generate_pool_statistics",
|
||||
"viash_version" : "0.9.2",
|
||||
"git_commit" : "cb58990a33f6ea6e46e474f2095b10218cf08912",
|
||||
"viash_version" : "0.9.4",
|
||||
"git_commit" : "a948c261931dbb784fc9ce6f7d5d93f52008a99f",
|
||||
"git_remote" : "https://github.com/viash-hub/htrnaseq"
|
||||
},
|
||||
"package_config" : {
|
||||
@@ -3294,7 +3289,7 @@ meta = [
|
||||
}
|
||||
]
|
||||
},
|
||||
"viash_version" : "0.9.2",
|
||||
"viash_version" : "0.9.4",
|
||||
"source" : "src",
|
||||
"target" : "target",
|
||||
"config_mods" : [
|
||||
@@ -3328,7 +3323,7 @@ meta = [
|
||||
// inner workflow hook
|
||||
def innerWorkflowFactory(args) {
|
||||
def rawScript = '''set -e
|
||||
tempscript=".viash_script.sh"
|
||||
tempscript=".viash_script.py"
|
||||
cat > "$tempscript" << VIASHMAIN
|
||||
import pandas as pd
|
||||
from pathlib import Path
|
||||
@@ -3781,7 +3776,7 @@ def _vdsl3ProcessFactory(Map workflowArgs, Map meta, String rawScript) {
|
||||
// create process from temp file
|
||||
def binding = new nextflow.script.ScriptBinding([:])
|
||||
def session = nextflow.Nextflow.getSession()
|
||||
def parser = new nextflow.script.ScriptParser(session)
|
||||
def parser = _getScriptLoader(session)
|
||||
.setModule(true)
|
||||
.setBinding(binding)
|
||||
def moduleScript = parser.runScript(tempFile)
|
||||
@@ -3795,6 +3790,27 @@ def _vdsl3ProcessFactory(Map workflowArgs, Map meta, String rawScript) {
|
||||
return scriptMeta.getProcess(procKey)
|
||||
}
|
||||
|
||||
// use Reflection to get a ScriptParser / ScriptLoader
|
||||
// <25.02.0-edge: new nextflow.script.ScriptParser(session)
|
||||
// >=25.02.0-edge: nextflow.script.ScriptLoaderFactory.create(session)
|
||||
def _getScriptLoader(nextflow.Session session) {
|
||||
// try using the old method
|
||||
try {
|
||||
Class<?> scriptParserClass = Class.forName('nextflow.script.ScriptParser')
|
||||
return scriptParserClass.getDeclaredConstructor(nextflow.Session).newInstance(session)
|
||||
} catch (ClassNotFoundException e) {
|
||||
// else try with the new method
|
||||
try {
|
||||
Class<?> scriptLoaderFactoryClass = Class.forName('nextflow.script.ScriptLoaderFactory')
|
||||
def createMethod = scriptLoaderFactoryClass.getDeclaredMethod('create', nextflow.Session)
|
||||
return createMethod.invoke(null, session) // null because create is static
|
||||
} catch (ClassNotFoundException | NoSuchMethodException | IllegalAccessException | java.lang.reflect.InvocationTargetException e2) {
|
||||
// Handle the case where neither class is found
|
||||
throw new Exception("Neither nextflow.script.ScriptParser nor nextflow.script.ScriptLoaderFactory could be found. Is this a compatible Nextflow version?", e2)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// defaults
|
||||
meta["defaults"] = [
|
||||
// key to be used to trace the process and determine output names
|
||||
|
||||
@@ -266,8 +266,8 @@ build_info:
|
||||
engine: "docker|native"
|
||||
output: "target/nextflow/stats/generate_well_statistics"
|
||||
executable: "target/nextflow/stats/generate_well_statistics/main.nf"
|
||||
viash_version: "0.9.2"
|
||||
git_commit: "cb58990a33f6ea6e46e474f2095b10218cf08912"
|
||||
viash_version: "0.9.4"
|
||||
git_commit: "a948c261931dbb784fc9ce6f7d5d93f52008a99f"
|
||||
git_remote: "https://github.com/viash-hub/htrnaseq"
|
||||
package_config:
|
||||
name: "htrnaseq"
|
||||
@@ -277,7 +277,7 @@ package_config:
|
||||
test_resources:
|
||||
- path: "gs://viash-hub-test-data/htrnaseq/v1/"
|
||||
dest: "resources_test"
|
||||
viash_version: "0.9.2"
|
||||
viash_version: "0.9.4"
|
||||
source: "src"
|
||||
target: "target"
|
||||
config_mods:
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// generate_well_statistics main
|
||||
//
|
||||
// This wrapper script is auto-generated by viash 0.9.2 and is thus a derivative
|
||||
// This wrapper script is auto-generated by viash 0.9.4 and is thus a derivative
|
||||
// work thereof. This software comes with ABSOLUTELY NO WARRANTY from Data
|
||||
// Intuitive.
|
||||
//
|
||||
@@ -86,64 +86,56 @@ def _checkArgumentType(String stage, Map par, Object value, String errorIdentifi
|
||||
foundClass = "List[${e.foundClass}]"
|
||||
}
|
||||
} else if (par.type == "string") {
|
||||
// cast to string if need be
|
||||
// cast to string if need be. only cast if the value is a GString
|
||||
if (value instanceof GString) {
|
||||
value = value.toString()
|
||||
value = value as String
|
||||
}
|
||||
expectedClass = value instanceof String ? null : "String"
|
||||
} else if (par.type == "integer") {
|
||||
// cast to integer if need be
|
||||
if (value instanceof String) {
|
||||
if (value !instanceof Integer) {
|
||||
try {
|
||||
value = value.toInteger()
|
||||
value = value as Integer
|
||||
} catch (NumberFormatException e) {
|
||||
// do nothing
|
||||
expectedClass = "Integer"
|
||||
}
|
||||
}
|
||||
if (value instanceof java.math.BigInteger) {
|
||||
value = value.intValue()
|
||||
}
|
||||
expectedClass = value instanceof Integer ? null : "Integer"
|
||||
} else if (par.type == "long") {
|
||||
// cast to long if need be
|
||||
if (value instanceof String) {
|
||||
if (value !instanceof Long) {
|
||||
try {
|
||||
value = value.toLong()
|
||||
value = value as Long
|
||||
} catch (NumberFormatException e) {
|
||||
// do nothing
|
||||
expectedClass = "Long"
|
||||
}
|
||||
}
|
||||
if (value instanceof Integer) {
|
||||
value = value.toLong()
|
||||
}
|
||||
expectedClass = value instanceof Long ? null : "Long"
|
||||
} else if (par.type == "double") {
|
||||
// cast to double if need be
|
||||
if (value instanceof String) {
|
||||
if (value !instanceof Double) {
|
||||
try {
|
||||
value = value.toDouble()
|
||||
value = value as Double
|
||||
} catch (NumberFormatException e) {
|
||||
// do nothing
|
||||
expectedClass = "Double"
|
||||
}
|
||||
}
|
||||
if (value instanceof java.math.BigDecimal) {
|
||||
value = value.doubleValue()
|
||||
} else if (par.type == "float") {
|
||||
// cast to float if need be
|
||||
if (value !instanceof Float) {
|
||||
try {
|
||||
value = value as Float
|
||||
} catch (NumberFormatException e) {
|
||||
expectedClass = "Float"
|
||||
}
|
||||
}
|
||||
if (value instanceof Float) {
|
||||
value = value.toDouble()
|
||||
}
|
||||
expectedClass = value instanceof Double ? null : "Double"
|
||||
} else if (par.type == "boolean" | par.type == "boolean_true" | par.type == "boolean_false") {
|
||||
// cast to boolean if need be
|
||||
if (value instanceof String) {
|
||||
def valueLower = value.toLowerCase()
|
||||
if (valueLower == "true") {
|
||||
value = true
|
||||
} else if (valueLower == "false") {
|
||||
value = false
|
||||
if (value !instanceof Boolean) {
|
||||
try {
|
||||
value = value as Boolean
|
||||
} catch (Exception e) {
|
||||
expectedClass = "Boolean"
|
||||
}
|
||||
}
|
||||
expectedClass = value instanceof Boolean ? null : "Boolean"
|
||||
} else if (par.type == "file" && (par.direction == "input" || stage == "output")) {
|
||||
// cast to path if need be
|
||||
if (value instanceof String) {
|
||||
@@ -155,10 +147,13 @@ def _checkArgumentType(String stage, Map par, Object value, String errorIdentifi
|
||||
expectedClass = value instanceof Path ? null : "Path"
|
||||
} else if (par.type == "file" && stage == "input" && par.direction == "output") {
|
||||
// cast to string if need be
|
||||
if (value instanceof GString) {
|
||||
value = value.toString()
|
||||
if (value !instanceof String) {
|
||||
try {
|
||||
value = value as String
|
||||
} catch (Exception e) {
|
||||
expectedClass = "String"
|
||||
}
|
||||
}
|
||||
expectedClass = value instanceof String ? null : "String"
|
||||
} else {
|
||||
// didn't find a match for par.type
|
||||
expectedClass = par.type
|
||||
@@ -3373,8 +3368,8 @@ meta = [
|
||||
"runner" : "nextflow",
|
||||
"engine" : "docker|native",
|
||||
"output" : "target/nextflow/stats/generate_well_statistics",
|
||||
"viash_version" : "0.9.2",
|
||||
"git_commit" : "cb58990a33f6ea6e46e474f2095b10218cf08912",
|
||||
"viash_version" : "0.9.4",
|
||||
"git_commit" : "a948c261931dbb784fc9ce6f7d5d93f52008a99f",
|
||||
"git_remote" : "https://github.com/viash-hub/htrnaseq"
|
||||
},
|
||||
"package_config" : {
|
||||
@@ -3389,7 +3384,7 @@ meta = [
|
||||
}
|
||||
]
|
||||
},
|
||||
"viash_version" : "0.9.2",
|
||||
"viash_version" : "0.9.4",
|
||||
"source" : "src",
|
||||
"target" : "target",
|
||||
"config_mods" : [
|
||||
@@ -3423,7 +3418,7 @@ meta = [
|
||||
// inner workflow hook
|
||||
def innerWorkflowFactory(args) {
|
||||
def rawScript = '''set -e
|
||||
tempscript=".viash_script.sh"
|
||||
tempscript=".viash_script.py"
|
||||
cat > "$tempscript" << VIASHMAIN
|
||||
import pysam
|
||||
import pandas as pd
|
||||
@@ -3867,7 +3862,7 @@ def _vdsl3ProcessFactory(Map workflowArgs, Map meta, String rawScript) {
|
||||
// create process from temp file
|
||||
def binding = new nextflow.script.ScriptBinding([:])
|
||||
def session = nextflow.Nextflow.getSession()
|
||||
def parser = new nextflow.script.ScriptParser(session)
|
||||
def parser = _getScriptLoader(session)
|
||||
.setModule(true)
|
||||
.setBinding(binding)
|
||||
def moduleScript = parser.runScript(tempFile)
|
||||
@@ -3881,6 +3876,27 @@ def _vdsl3ProcessFactory(Map workflowArgs, Map meta, String rawScript) {
|
||||
return scriptMeta.getProcess(procKey)
|
||||
}
|
||||
|
||||
// use Reflection to get a ScriptParser / ScriptLoader
|
||||
// <25.02.0-edge: new nextflow.script.ScriptParser(session)
|
||||
// >=25.02.0-edge: nextflow.script.ScriptLoaderFactory.create(session)
|
||||
def _getScriptLoader(nextflow.Session session) {
|
||||
// try using the old method
|
||||
try {
|
||||
Class<?> scriptParserClass = Class.forName('nextflow.script.ScriptParser')
|
||||
return scriptParserClass.getDeclaredConstructor(nextflow.Session).newInstance(session)
|
||||
} catch (ClassNotFoundException e) {
|
||||
// else try with the new method
|
||||
try {
|
||||
Class<?> scriptLoaderFactoryClass = Class.forName('nextflow.script.ScriptLoaderFactory')
|
||||
def createMethod = scriptLoaderFactoryClass.getDeclaredMethod('create', nextflow.Session)
|
||||
return createMethod.invoke(null, session) // null because create is static
|
||||
} catch (ClassNotFoundException | NoSuchMethodException | IllegalAccessException | java.lang.reflect.InvocationTargetException e2) {
|
||||
// Handle the case where neither class is found
|
||||
throw new Exception("Neither nextflow.script.ScriptParser nor nextflow.script.ScriptLoaderFactory could be found. Is this a compatible Nextflow version?", e2)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// defaults
|
||||
meta["defaults"] = [
|
||||
// key to be used to trace the process and determine output names
|
||||
|
||||
Reference in New Issue
Block a user