-
Notifications
You must be signed in to change notification settings - Fork 628
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
Workflow output definition (second preview) #5185
Conversation
Signed-off-by: Ben Sherman <[email protected]>
✅ Deploy Preview for nextflow-docs-staging ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
Signed-off-by: Ben Sherman <[email protected]>
Signed-off-by: Ben Sherman <[email protected]>
Signed-off-by: Ben Sherman <[email protected]>
Signed-off-by: Ben Sherman <[email protected]>
Signed-off-by: Ben Sherman <[email protected]>
Signed-off-by: Ben Sherman <[email protected]>
Signed-off-by: Ben Sherman <[email protected]>
Signed-off-by: Ben Sherman <[email protected]>
Signed-off-by: Ben Sherman <[email protected]>
Signed-off-by: Ben Sherman <[email protected]>
Second preview is ready for review, POCs have also been updated: |
Signed-off-by: Ben Sherman <[email protected]>
Signed-off-by: Ben Sherman <[email protected]>
Signed-off-by: Ben Sherman <[email protected]>
I just tried the dynamic publishing with some dummy code and it worked perfectly! I'm looking forward to implementing this in my pipelines 🥳 |
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.
Added small language suggestion.
Co-authored-by: Christopher Hakkaart <[email protected]> Signed-off-by: Paolo Di Tommaso <[email protected]>
Signed-off-by: Ben Sherman <[email protected]>
modules/nextflow/src/main/groovy/nextflow/processor/PublishDir.groovy
Outdated
Show resolved
Hide resolved
Signed-off-by: Ben Sherman <[email protected]>
Signed-off-by: Paolo Di Tommaso <[email protected]>
|
||
`header` | ||
: When `true`, the keys of the first record are used as the column names (default: `false`). Can also be a list of column names. | ||
- The process `publish:` section has been removed. Channels should be published only in workflows, ideally the entry workflow. |
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.
I'm really not sure about this, I see the need for modules but it will make the writing of workflows much more verbose. Could not both approach co-exist?
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.
It's too confusing. If a process publishes some outputs by default and you don't want to publish them, then you have to explicitly disable them. And one of the goals of workflow outputs was to have all published outputs in one place, instead of being scattered across the pipeline
My initial feeling was to only allow publishing in the entry workflow, but that would also create a lot of boilerplate to pass all the channels up from the subworkflows. So a happy middle ground for now is to allow publishing from any workflow, but not processes
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.
Also, the original motivation for process publishing is to provide some sensible publishing defaults for a module. I think this is better handled by providing an entry workflow with the module:
process ASPERA_CLI {
input:
// ...
output:
tuple val(meta), path("*fastq.gz"), emit: fastq
tuple val(meta), path("*md5") , emit: md5
script:
// ...
}
workflow {
main:
ASPERA_CLI ( params.input, params.args )
publish:
ASPERA_CLI.out.fastq >> 'fastq'
ASPERA_CLI.out.md5 >> 'md5'
}
This gives an example of how to use the module, both params and publishing, but they are opt-in. The user can incorporate these publishing rules into their pipeline explicitly, if they want to.
@bentsherman can you please have a look at the conflicts |
Signed-off-by: Ben Sherman <[email protected]>
Close #5103
TODO:
language improvements:
runtime improvements:
new features (might be handled separately):