Releases: nextflow-io/nf-schema
Releases · nextflow-io/nf-schema
Version 2.4.2
Version 2.4.1
Bug fixes
- Allow
GString
values for all configuration options that allowString
values.
Version 2.4.0
New features
- 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. - Added a new function:
validate()
that can be used to validate any data structure using a JSON schema.
Bug fixes
- Move the unpinned version check to an observer. This makes sure the warning is always shown and not only when importing a function.
- Added a missing inherited method to the observer to fix issues with workflow output publishing
- Fixed unexpected failures with samplesheet schemas using
anyOf
,allOf
andoneOf
- Fixed an error with help messages when the
type
keyword was missing - Fix compilation errors in Java 21
Improvements
- Slow uniqueness check (> 2hrs for 100k samples) made 400x faster by switching from
findAll
to asubMap
for isolating the required unique fields. patternProperties
now has greater support, with no warnings about invalid parameters which actually match a pattern- Added better error handling and debug messages to the configuration parser.
Changes
- Refactored the whole codebase to make future development easier
- Bumped the minimal Nextflow version to
24.10.0
Version 2.3.0 - Hakodate
Bug fixes
- The help message will now also be printed out when no functions of the plugin get included in the pipeline.
- JSON and YAML files that are not a list of values should now also be validated correctly. (Mind that samplesheets always have to be a list of values to work with
samplesheetToList
)
Version 2.2.1
Bug fixes
- Fixed a bug in
paramsSummaryMap()
related to the processing of workflow config files. - Fixed a bug where
validation.defaultIgnoreParams
andvalidation.ignoreParams
would not actually ignore the parameter validation.
Version 2.2.0 - Kitakata
New features
- Added a new configuration option
validation.failUnrecognisedHeaders
. This is the analogue tofailUnrecognisedParams
, but for samplesheet headers. The default isfalse
which means that unrecognized headers throw a warning instead of an error. - Added a new configuration option
validation.summary.hideParams
. This option takes a list of parameter names to hide from the parameters summary created byparamsSummaryMap()
andparamsSummaryLog()
Bug fixes
- Fixed a bug in
samplesheetToList
that caused output mixing when the function was used more than once in channel operators. - Added a missing depencency for email format validation.
- All path formats (with exception to
file-path-pattern
) will now give a proper error message when afile-path-pattern
has been used.
Improvements
- Improved the
exists
keyword documentation with a warning about an edge case. - Updated the error messages. Custom error messages provided in the JSON schema will now be appended to the original error messages instead of overwriting them.
Version 2.1.2
Bug fixes
- The directory
nf_test_output
is now an ignored parameter during validation to support use of bothnf_test
andnf_schema
. uniqueEntries
will now skip unique checks when all values in the requested array properties are empty. This had to be implemented to allow optional values to work with theuniqueEntries
check. Partially filled in array properties will still fail (and that's how it's meant to be). Be sure to useoneOf
to properly configure all possible combinations in case this causes some issues.- Improved the error messages produced by
uniqueEntries
.
Documentation
- Fix some faults in the docs
Version 2.1.1
Bug fixes
- The help parameters are now no longer unexpected parameters when validating parameters.
- Fixed a typo in the docs
- Added a URL to the help message migration docs to the
paramsHelp()
deprecation message - The old
validation.showHiddenParams
config option works again to ensure backwards compatibility. Usingvalidation.help.showHidden
is still preffered and the old option will emit a deprecation message. - Resolved an issue where the UniqueEntriesEvaluator did not correctly detect non-unique combinations.
Version 2.1.0 - Tantanmen
Breaking changes
- The minimum supported Nextflow version is now
23.10.0
instead of22.10.0
New features
- The plugin now fully supports nested parameters!
- Added a config option
validation.parametersSchema
which can be used to set the parameters JSON schema in a config file. The default isnextflow_schema.json
- The parameter summary log will now automatically show nested parameters.
- Added two new configuration options:
validation.summary.beforeText
andvalidation.summary.afterText
to automatically add some text before and after the output of theparamsSummaryLog()
function. The colors from these texts will be automatically filtered out ifvalidation.monochromeLogs
is set totrue
.
Help message changes
- The use of the
paramsHelp()
function has now been deprecated in favor of a new built-in help message functionality.paramsHelp()
has been updated to use the reworked help message creator. If you still want to useparamsHelp()
for some reason in your pipeline, please add thehideWarning:true
option to it to make sure the deprecation warning will not be shown. - Added new configuration values to support the new help message functionality:
validation.help.enabled
: Enables the checker for the help message parameters. The plugin will automatically show the help message when one of these parameters have been given and exit the pipeline. Default =false
validation.help.shortParameter
: The parameter to use for the compact help message. This help message will only contain top level parameters. Default =help
validation.help.fullParameter
: The parameter to use for the expanded help message. This help message will show all parameters no matter how deeply nested they are. Default =helpFull
validation.help.showHiddenParameter
: The parameter to use to also show all parameters with thehidden: true
keyword in the schema. Default =showHidden
validation.help.showHidden
: Set this totrue
to show hidden parameters by default. This configuration option is overwritten by the value supplied to the parameter invalidation.help.showHiddenParameter
. Default =false
validation.help.beforeText
: Some custom text to add before the help message. The colors from this text will be automatically filtered out ifvalidation.monochromeLogs
is set totrue
.validation.help.afterText
: Some custom text to add after the help message. The colors from this text will be automatically filtered out ifvalidation.monochromeLogs
is set totrue
.validation.help.command
: An example command to add to the top of the help message. The colors from this text will be automatically filtered out ifvalidation.monochromeLogs
is set totrue
.
- Added support for nested parameters to the help message. A detailed help message using
--help <parameter>
will now also contain all nested parameters. The parameter supplied to--help
can be a nested parameter too (e.g.--help top_parameter.nested_parameter.deeper_parameter
) - The help message now won't show empty parameter groups.
- The help message will now automatically contain the three parameters used to get help messages.
JSON schema fixes
- The
defs
keyword is now deprecated in favor of the$defs
keyword. This to follow the JSON schema guidelines. We will continue supportingdefs
for backwards compatibility.
Version 2.0.1
Vulnerability fix
- Updated the org.json package to version
20240303
.