Skip to content

Fix runtime type reflection in nf-lang#7077

Merged
bentsherman merged 1 commit intomasterfrom
fix-runtime-type-reflection
Apr 27, 2026
Merged

Fix runtime type reflection in nf-lang#7077
bentsherman merged 1 commit intomasterfrom
fix-runtime-type-reflection

Conversation

@bentsherman
Copy link
Copy Markdown
Member

@bentsherman bentsherman commented Apr 26, 2026

Spun out from #7025 to make that PR more focused

This PR fixes the runtime type reflection in nf-lang to handle parameterized types correctly, using Type and ParameterizedType in addition to Class.

It improves both the rendering of type names (e.g. in error messages) and the extraction of types in plugin specs (e.g. config option types, function parameter/return types).

This fix is also needed by the language server to accurately type-check plugin definitions.

@bentsherman bentsherman requested a review from jorgee April 26, 2026 13:56
@bentsherman bentsherman requested a review from a team as a code owner April 26, 2026 13:56
@netlify
Copy link
Copy Markdown

netlify Bot commented Apr 26, 2026

Deploy Preview for nextflow-docs-staging ready!

Name Link
🔨 Latest commit bb13792
🔍 Latest deploy log https://app.netlify.com/projects/nextflow-docs-staging/deploys/69ee19ecc0a9040008c1e33b
😎 Deploy Preview https://deploy-preview-7077--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 26.04 milestone Apr 26, 2026
Signed-off-by: Ben Sherman <bentshermann@gmail.com>
@bentsherman bentsherman force-pushed the fix-runtime-type-reflection branch from 1dcbf53 to bb13792 Compare April 26, 2026 13:58
Copy link
Copy Markdown
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.

Changes looks fine. Just a comment I noted here and I missed in the other PR. The plugin spec type can have a String or a Map with name and typeArguments. It is only used to write the plugin spec. Not sure who is using this spec. Could it create incompatibilities with other tools using specs generated with this PR.

@bentsherman
Copy link
Copy Markdown
Member Author

It is currently only used by the language server, which already supports both string and map

@bentsherman bentsherman merged commit 916f029 into master Apr 27, 2026
25 checks passed
@bentsherman bentsherman deleted the fix-runtime-type-reflection branch April 27, 2026 14:18
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