From e0f289027f44c7bdb41770e30306b33218227cd4 Mon Sep 17 00:00:00 2001 From: Nicolas Vannieuwkerke Date: Tue, 20 Aug 2024 14:38:25 +0200 Subject: [PATCH 1/8] add version name --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e5e3796e..a676b3e9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # nextflow-io/nf-schema: Changelog -# Version 2.1.0 +# Version 2.1.0 - Tantanmen ## Breaking changes From b564aced4d3a54deb9748ef541e8d313dcafe396 Mon Sep 17 00:00:00 2001 From: Nicolas Vannieuwkerke Date: Fri, 23 Aug 2024 10:25:50 +0200 Subject: [PATCH 2/8] bump to 2.1.1 --- CHANGELOG.md | 2 ++ README.md | 2 +- plugins/nf-schema/src/resources/META-INF/MANIFEST.MF | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index a676b3e9..519bbe59 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,7 @@ # nextflow-io/nf-schema: Changelog +# Version 2.1.1 + # Version 2.1.0 - Tantanmen ## Breaking changes diff --git a/README.md b/README.md index dd61974b..c55a34c6 100644 --- a/README.md +++ b/README.md @@ -25,7 +25,7 @@ Declare the plugin in your Nextflow pipeline configuration file: ```groovy title="nextflow.config" plugins { - id 'nf-schema@2.1.0' + id 'nf-schema@2.1.1' } ``` diff --git a/plugins/nf-schema/src/resources/META-INF/MANIFEST.MF b/plugins/nf-schema/src/resources/META-INF/MANIFEST.MF index 028c9086..fff7b0cf 100644 --- a/plugins/nf-schema/src/resources/META-INF/MANIFEST.MF +++ b/plugins/nf-schema/src/resources/META-INF/MANIFEST.MF @@ -1,6 +1,6 @@ Manifest-Version: 1.0 Plugin-Id: nf-schema -Plugin-Version: 2.1.0 +Plugin-Version: 2.1.1 Plugin-Class: nextflow.validation.ValidationPlugin Plugin-Provider: nextflow Plugin-Requires: >=23.10.0 From 0eef1c4b60515e73a5b815ea592309a7553657dc Mon Sep 17 00:00:00 2001 From: Nicolas Vannieuwkerke Date: Fri, 23 Aug 2024 10:39:09 +0200 Subject: [PATCH 3/8] bug fix for unexpected params --- .../src/main/nextflow/validation/SchemaValidator.groovy | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/plugins/nf-schema/src/main/nextflow/validation/SchemaValidator.groovy b/plugins/nf-schema/src/main/nextflow/validation/SchemaValidator.groovy index 2b1ce7d9..01e55c0b 100644 --- a/plugins/nf-schema/src/main/nextflow/validation/SchemaValidator.groovy +++ b/plugins/nf-schema/src/main/nextflow/validation/SchemaValidator.groovy @@ -232,8 +232,8 @@ class SchemaValidator extends PluginExtensionPoint { // Initialise expected params if not present // Map initialiseExpectedParams(Map params) { - if( !params.containsKey("help") ) { - params.help = false + addExpectedParams().each { param -> + params[param] = false } return params } @@ -244,7 +244,9 @@ class SchemaValidator extends PluginExtensionPoint { // List addExpectedParams() { def List expectedParams = [ - "help" + config.help.shortParameter, + config.help.fullParameter, + config.help.showHiddenParameter ] return expectedParams From 2666e96dab03983dd31f4d46b55ddb966ca40519 Mon Sep 17 00:00:00 2001 From: Nicolas Vannieuwkerke Date: Fri, 23 Aug 2024 10:41:37 +0200 Subject: [PATCH 4/8] fix a typo in the docs --- docs/parameters/help_text.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/parameters/help_text.md b/docs/parameters/help_text.md index 893effff..e7c3d20f 100644 --- a/docs/parameters/help_text.md +++ b/docs/parameters/help_text.md @@ -5,7 +5,7 @@ Add the following configuration to your configuration files to enable the creati ```groovy title="nextflow.config" validation { help { - enabled: true + enabled = true } } ``` From 483fc9105e16372695d2919db9bd099a1067ff99 Mon Sep 17 00:00:00 2001 From: Nicolas Vannieuwkerke Date: Fri, 23 Aug 2024 10:42:57 +0200 Subject: [PATCH 5/8] update changelog --- CHANGELOG.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 519bbe59..84a4a8bc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,11 @@ # Version 2.1.1 +## Bug fixes + +1. The help parameters are now no longer unexpected parameters when validating parameters. +2. Fixed a typo in the docs + # Version 2.1.0 - Tantanmen ## Breaking changes From 9f91202b84b593c11103f51af9a413c1decde363 Mon Sep 17 00:00:00 2001 From: Nicolas Vannieuwkerke Date: Fri, 23 Aug 2024 17:22:18 +0200 Subject: [PATCH 6/8] add migration url to deprecation message of paramsHelp --- .../src/main/nextflow/validation/SchemaValidator.groovy | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/nf-schema/src/main/nextflow/validation/SchemaValidator.groovy b/plugins/nf-schema/src/main/nextflow/validation/SchemaValidator.groovy index 01e55c0b..68a2a5b8 100644 --- a/plugins/nf-schema/src/main/nextflow/validation/SchemaValidator.groovy +++ b/plugins/nf-schema/src/main/nextflow/validation/SchemaValidator.groovy @@ -369,7 +369,7 @@ class SchemaValidator extends PluginExtensionPoint { // TODO add link to help message migration guide once created if (!options.containsKey("hideWarning") || options.hideWarning == false) { log.warn(""" -Using `paramsHelp()` is not recommended. Check out the help message migration guide: +Using `paramsHelp()` is not recommended. Check out the help message migration guide: https://nextflow-io.github.io/nf-schema/latest/migration_guide/#updating-the-help-message If you intended to use this function, please add the following option to the input of the function: `hideWarning: true` From 255f661b5b6ff184cf56b260b589d156116a7ec5 Mon Sep 17 00:00:00 2001 From: Nicolas Vannieuwkerke Date: Fri, 23 Aug 2024 17:28:10 +0200 Subject: [PATCH 7/8] add migration url to deprecation message of paramsHelp --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 84a4a8bc..4a617c2e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,7 @@ 1. The help parameters are now no longer unexpected parameters when validating parameters. 2. Fixed a typo in the docs +3. Added a URL to the help message migration docs to the `paramsHelp()` deprecation message # Version 2.1.0 - Tantanmen From 1b97b26a0c1f2d1fe26825b4c91ae724f5be20d6 Mon Sep 17 00:00:00 2001 From: Nicolas Vannieuwkerke Date: Fri, 23 Aug 2024 17:33:22 +0200 Subject: [PATCH 8/8] add migration url to deprecation message of paramsHelp --- .../src/main/nextflow/validation/SchemaValidator.groovy | 1 - 1 file changed, 1 deletion(-) diff --git a/plugins/nf-schema/src/main/nextflow/validation/SchemaValidator.groovy b/plugins/nf-schema/src/main/nextflow/validation/SchemaValidator.groovy index 68a2a5b8..61aa1bbc 100644 --- a/plugins/nf-schema/src/main/nextflow/validation/SchemaValidator.groovy +++ b/plugins/nf-schema/src/main/nextflow/validation/SchemaValidator.groovy @@ -366,7 +366,6 @@ class SchemaValidator extends PluginExtensionPoint { Map options = [:], String command ) { - // TODO add link to help message migration guide once created if (!options.containsKey("hideWarning") || options.hideWarning == false) { log.warn(""" Using `paramsHelp()` is not recommended. Check out the help message migration guide: https://nextflow-io.github.io/nf-schema/latest/migration_guide/#updating-the-help-message