Skip to content

Remove support for when: section in typed processes#7216

Open
bentsherman wants to merge 2 commits into
masterfrom
typed-process-when-section
Open

Remove support for when: section in typed processes#7216
bentsherman wants to merge 2 commits into
masterfrom
typed-process-when-section

Conversation

@bentsherman

Copy link
Copy Markdown
Member

This PR removes support for when: in typed processes.

While it was preserved during the preview period to ease migration, the stable version of typed processes should not support it

Aside from being an anti-pattern, when: can actually break semantic guarantees of dataflow logic. If a process is called with a dataflow value and returns a dataflow value, and I use when: to disable that process via config, it will return an "empty" dataflow value which is invalid

Rather than deprecating it across the board, it will remain allowed in legacy processes and removed in typed processes. Migrating to static typing is the best point at which to also migrate away from when: because records and type checking makes it easier to do

Signed-off-by: Ben Sherman <bentshermann@gmail.com>
@bentsherman bentsherman added this to the 26.10 milestone Jun 10, 2026
@bentsherman bentsherman requested a review from jorgee June 10, 2026 15:35
@bentsherman bentsherman requested a review from a team as a code owner June 10, 2026 15:35
@bentsherman bentsherman requested a review from a team as a code owner June 10, 2026 15:35
@netlify

netlify Bot commented Jun 10, 2026

Copy link
Copy Markdown

Deploy Preview for nextflow-docs-staging canceled.

Name Link
🔨 Latest commit f84be59
🔍 Latest deploy log https://app.netlify.com/projects/nextflow-docs-staging/deploys/6a2add551961a90008639937

Signed-off-by: Ben Sherman <bentshermann@gmail.com>
@bentsherman bentsherman requested a review from jorgee June 11, 2026 16:07

@pditommaso pditommaso left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not totally convinced about removing this. I was even considering that this could implement a similar pattern as until/recursion

@bentsherman

Copy link
Copy Markdown
Member Author

when: is not compatible with static typing. I don't see how recursion is relevant here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants