-
Notifications
You must be signed in to change notification settings - Fork 7
Convert to typed params #141
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
itrujnara
wants to merge
9
commits into
nf-core:dev
Choose a base branch
from
itrujnara:typed_params
base: dev
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
b3bfa8e
Update nf-core subworkflows
itrujnara 2314e0a
Start migration to typed params
itrujnara 8cb6ceb
Remove unnecessary params from nextflow.config
itrujnara f080587
Update changelog
itrujnara 7366c29
Bump Nextflow version
itrujnara 6feb9c0
Remove obsolete skip_downstream parameter
itrujnara 9b46b58
Add skip_samplesheets in fasta test
itrujnara aceb30a
Fix description in fasta test
itrujnara 2740365
Update snapshots for fasta test
itrujnara File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -17,10 +17,94 @@ nextflow.enable.moduleBinaries = true | |
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
| */ | ||
|
|
||
| include { REPORTHO } from './workflows/reportho' | ||
| include { REPORTHO } from './workflows/reportho' | ||
| include { PIPELINE_INITIALISATION } from './subworkflows/local/utils_nfcore_reportho_pipeline/main' | ||
| include { PIPELINE_COMPLETION } from './subworkflows/local/utils_nfcore_reportho_pipeline/main' | ||
|
|
||
| /* | ||
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
| PARAMETER DECLARATIONS | ||
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
| */ | ||
|
|
||
| params { | ||
| // Input options | ||
| input: Path = null | ||
| output_intermediates: Boolean = false | ||
|
|
||
| // MultiQC options | ||
| multiqc_config: Path? = null | ||
| multiqc_title: String? = null | ||
| multiqc_logo: Path? = null | ||
| max_multiqc_email_size: String = "25.MB" | ||
| multiqc_methods_description: String? = null | ||
|
|
||
|
|
||
| // Ortholog options | ||
| use_all: Boolean = false | ||
| offline_run: Boolean = false | ||
| local_databases: Boolean = false | ||
|
|
||
| // Ortholog fetching options | ||
| skip_oma: Boolean = false | ||
| oma_path: Path? = null | ||
| oma_uniprot_path: Path? = null | ||
| oma_ensembl_path: Path? = null | ||
| oma_refseq_path: Path? = null | ||
| skip_panther: Boolean = false | ||
| panther_path: Path? = null | ||
| skip_orthoinspector: Boolean = false | ||
| orthoinspector_path: Path? = null | ||
| orthoinspector_version: String = 'Eukaryota2023' | ||
| skip_eggnog: Boolean = false | ||
| eggnog_path: Path? = null | ||
| eggnog_idmap_path: Path? = null | ||
|
|
||
| // ID merging options | ||
| skip_merge: Boolean = false | ||
| min_identity: Integer = 90 | ||
| min_coverage: Integer = 80 | ||
|
|
||
| // Ortholog scoring options | ||
| use_centroid: Boolean = false | ||
| min_score: Integer = 2 | ||
|
|
||
| // Process skipping options | ||
| skip_orthoplots: Boolean = false | ||
| skip_report: Boolean = false | ||
| skip_multiqc: Boolean = false | ||
| skip_samplesheets: Boolean = false | ||
|
|
||
| // Infrastructure options | ||
| array_size: Integer = 10 | ||
|
|
||
| // Boilerplate options | ||
| outdir: Path = null | ||
| publish_dir_mode: String = 'copy' | ||
| email: String? = null | ||
| email_on_fail: String? = null | ||
| plaintext_email: Boolean = false | ||
| monochrome_logs: Boolean = false | ||
| help: Boolean = false | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. help can be |
||
| help_full: Boolean = false | ||
| show_hidden: Boolean = false | ||
| version: Boolean = false | ||
| pipelines_testdata_base_path: String = 'https://raw.githubusercontent.com/nf-core/test-datasets/' | ||
| trace_report_suffix: String = new java.util.Date().format('yyyy-MM-dd_HH-mm-ss') | ||
|
|
||
| // Config options | ||
| config_profile_name: String? = null | ||
| config_profile_description: String? = null | ||
|
|
||
| custom_config_version: String = 'master' | ||
| custom_config_base: String = "https://raw.githubusercontent.com/nf-core/configs/${params.custom_config_version}" | ||
| config_profile_contact: String? = null | ||
| config_profile_url: String? = null | ||
|
|
||
| // Schema validation default options | ||
| validate_params: Boolean = true | ||
| } | ||
|
|
||
| /* | ||
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
| NAMED WORKFLOWS FOR PIPELINE | ||
|
|
@@ -31,10 +115,9 @@ include { PIPELINE_COMPLETION } from './subworkflows/local/utils_nfcore_repo | |
| // WORKFLOW: Run main analysis pipeline depending on type of input | ||
| // | ||
| workflow NFCORE_REPORTHO { | ||
|
|
||
| take: | ||
| samplesheet_query // channel: samplesheet read in from --input with query | ||
| samplesheet_fasta // channel: samplesheet read in from --input with fasta | ||
| samplesheet_query // channel: samplesheet read in from --input with query | ||
| samplesheet_fasta // channel: samplesheet read in from --input with fasta | ||
| offline_run | ||
| use_all | ||
| use_centroid | ||
|
|
@@ -53,7 +136,6 @@ workflow NFCORE_REPORTHO { | |
| eggnog_idmap_path | ||
| min_score | ||
| skip_merge | ||
| skip_downstream | ||
| skip_orthoplots | ||
| skip_samplesheets | ||
| skip_report | ||
|
|
@@ -69,7 +151,7 @@ workflow NFCORE_REPORTHO { | |
| // | ||
| // WORKFLOW: Run pipeline | ||
| // | ||
| REPORTHO ( | ||
| REPORTHO( | ||
| samplesheet_query, | ||
| samplesheet_fasta, | ||
| offline_run, | ||
|
|
@@ -90,7 +172,6 @@ workflow NFCORE_REPORTHO { | |
| eggnog_idmap_path, | ||
| min_score, | ||
| skip_merge, | ||
| skip_downstream, | ||
| skip_orthoplots, | ||
| skip_samplesheets, | ||
| skip_report, | ||
|
|
@@ -112,35 +193,29 @@ workflow NFCORE_REPORTHO { | |
| */ | ||
|
|
||
| workflow { | ||
|
|
||
| main: | ||
| effective_local_databases = params.local_databases | ||
| effective_skip_downstream = params.containsKey('skip_downstream') ? params['skip_downstream'] : false | ||
|
|
||
| if (params.offline_run) { | ||
| if (!effective_local_databases) { | ||
| effective_local_databases = true | ||
| log.warn("Offline mode enabled, setting 'local_databases' to 'true'") | ||
| } | ||
| if (!effective_skip_downstream) { | ||
| effective_skip_downstream = true | ||
| log.warn("Offline mode enabled, setting 'skip_downstream' to 'true'") | ||
| } | ||
| if (params.use_all) { | ||
| log.warn("Offline run set with 'use_all', only local databases will be used") | ||
| } | ||
| } else if (params.use_all && effective_local_databases) { | ||
| } | ||
| else if (params.use_all && effective_local_databases) { | ||
| log.warn("Local databases set with 'use_all', only local databases will be used") | ||
| } | ||
|
|
||
| if (!params.skip_samplesheets && (params.offline_run || (params.skip_merge && effective_skip_downstream))) { | ||
| if (!params.skip_samplesheets && (params.offline_run || params.skip_merge)) { | ||
| log.error("Samplesheet generation for nf-core/multiplesequencealign requires fetched sequences. Set '--skip_samplesheets' to true or disable offline/no-fetch settings.") | ||
| } | ||
|
|
||
| // | ||
| // SUBWORKFLOW: Run initialisation tasks | ||
| // | ||
| PIPELINE_INITIALISATION ( | ||
| PIPELINE_INITIALISATION( | ||
| params.version, | ||
| params.validate_params, | ||
| params.monochrome_logs, | ||
|
|
@@ -149,13 +224,13 @@ workflow { | |
| params.input, | ||
| params.help, | ||
| params.help_full, | ||
| params.show_hidden | ||
| params.show_hidden, | ||
| ) | ||
|
|
||
| // | ||
| // WORKFLOW: Run main workflow | ||
| // | ||
| NFCORE_REPORTHO ( | ||
| NFCORE_REPORTHO( | ||
| PIPELINE_INITIALISATION.out.samplesheet_query, | ||
| PIPELINE_INITIALISATION.out.samplesheet_fasta, | ||
| params.offline_run, | ||
|
|
@@ -176,7 +251,6 @@ workflow { | |
| params.eggnog_idmap_path, | ||
| params.min_score, | ||
| params.skip_merge, | ||
| effective_skip_downstream, | ||
| params.skip_orthoplots, | ||
| params.skip_samplesheets, | ||
| params.skip_report, | ||
|
|
@@ -185,24 +259,18 @@ workflow { | |
| params.multiqc_config, | ||
| params.multiqc_logo, | ||
| params.multiqc_methods_description, | ||
| params.outdir | ||
| params.outdir, | ||
| ) | ||
| // | ||
| // SUBWORKFLOW: Run completion tasks | ||
| // | ||
| PIPELINE_COMPLETION ( | ||
| PIPELINE_COMPLETION( | ||
| params.email, | ||
| params.email_on_fail, | ||
| params.plaintext_email, | ||
| params.max_multiqc_email_size, | ||
| params.outdir, | ||
| params.monochrome_logs, | ||
| NFCORE_REPORTHO.out | ||
| NFCORE_REPORTHO.out, | ||
| ) | ||
| } | ||
|
|
||
| /* | ||
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
| THE END | ||
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
| */ | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't these be Float instead?