You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: CHANGELOG.md
+1
Original file line number
Diff line number
Diff line change
@@ -12,6 +12,7 @@
12
12
13
13
1. Slow uniqueness check (> 2hrs for 100k samples) made 400x faster by switching from `findAll` to a `subMap` for isolating the required unique fields.
14
14
2.`patternProperties` now has greater support, with no warnings about invalid parameters which actually match a pattern
15
+
3. Added a new configuration option: `validation.maxErrValSize` which sets the maximum length that a value in an error message can be. The default is set to 150 characters.
Configure the maximum characters of a value that may be shown in an error message. It takes a whole number above or equal to `1`. A value will be truncated when it goes over the maximum amount of characters.
101
+
102
+
Setting this option to `-1` will allow any amount of characters for values.
103
+
104
+
See the below example where the limit is to 20 characters:
105
+
106
+
```
107
+
* --test (abcdefghij...qrstuvwxyz): Value is [string] but should be [integer]
108
+
```
109
+
110
+
```groovy
111
+
validation.maxErrValSize = 100 // default: 150
112
+
```
113
+
98
114
## help
99
115
100
116
The `validation.help` config scope can be used to configure the creation of the help message.
log.warn("`validation.maxErrValSize` needs to be a value above 0 or equal to -1, defaulting to ${maxErrValSize}")
41
+
}
42
+
}
35
43
if(config.containsKey("showHiddenParams")) {
36
44
log.warn("configuration option `validation.showHiddenParams` is deprecated, please use `validation.help.showHidden` or the `--showHidden` parameter instead")
include { validateParameters } from 'plugin/nf-schema'
1419
+
1420
+
validateParameters(parameters_schema: '$schema')
1421
+
"""
1422
+
1423
+
when:
1424
+
def config = ["validation": [
1425
+
"maxErrValSize": 20
1426
+
]]
1427
+
def result =newMockScriptRunner(config).setScript(SCRIPT).execute()
1428
+
def stdout = capture
1429
+
.toString()
1430
+
.readLines()
1431
+
.findResults {it.contains('WARN nextflow.validation.SchemaValidator') || it.startsWith('* --') ? it :null }
1432
+
1433
+
then:
1434
+
def error = thrown(SchemaValidationException)
1435
+
error.message.contains("* --input (src/testRe..._extension): \"src/testResources/wrong_samplesheet_with_a_super_long_name.and_a_weird_extension\" does not match regular expression [^\\S+\\.(csv|tsv|yaml|json)\$]")
0 commit comments