Skip to content

Conversation

@bentsherman
Copy link
Member

@bentsherman bentsherman commented Oct 13, 2025

This PR adds a few things to nf-lang to help enable type checking in the language server.

The full type checker will eventually be incorporated into nf-lang, but for now it will reside in the language server while we continue to develop it. This way I can release improvements to the type checker without requiring a Nextflow patch release

No unit tests because these changes are covered by language server unit tests for now.

Summary of changes:

  • Save method overloads in VariableScopeVisitor when a method call matches multiple possible methods (used by type checker to select method or provide appropriate error message)

  • Add @NamedParams annotation to standard library functions (used by type checker to validate named params)

  • Fix resolution of output types for processes and workflows

  • Resolve params block during name checking (was previously done only by language server)

  • Minor bug fixes

@netlify
Copy link

netlify bot commented Oct 13, 2025

Deploy Preview for nextflow-docs-staging ready!

Name Link
🔨 Latest commit ce42bf1
🔍 Latest deploy log https://app.netlify.com/projects/nextflow-docs-staging/deploys/68f7e3be0bfc320008efacf0
😎 Deploy Preview https://deploy-preview-6482--nextflow-docs-staging.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@bentsherman bentsherman added this to the 25.10 milestone Oct 13, 2025
@bentsherman bentsherman requested a review from jorgee October 17, 2025 22:06
@bentsherman bentsherman marked this pull request as ready for review October 17, 2025 22:06
@bentsherman bentsherman requested a review from a team as a code owner October 17, 2025 22:06
Copy link
Contributor

@jorgee jorgee left a comment

Choose a reason for hiding this comment

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

I have tried to understand changes. Not familiar with the resolve part, so I couldn't understand why you changed a resolveOrFail by just resolve. The rest looks fine to me.

@bentsherman bentsherman requested a review from jorgee October 20, 2025 19:42
@bentsherman bentsherman requested a review from a team as a code owner October 21, 2025 17:41
Signed-off-by: Ben Sherman <[email protected]>
@bentsherman bentsherman merged commit 3e9a2c0 into master Oct 21, 2025
24 checks passed
@bentsherman bentsherman deleted the type-checking-utils branch October 21, 2025 20:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants