Skip to content

[backport core/1.40] fix: prevent non-widget inputs on nested subgraphs from appearing as button widgets (#9542)#9581

Merged
christian-byrne merged 1 commit intocore/1.40from
backport-9542-to-core-1.40
Mar 8, 2026
Merged

[backport core/1.40] fix: prevent non-widget inputs on nested subgraphs from appearing as button widgets (#9542)#9581
christian-byrne merged 1 commit intocore/1.40from
backport-9542-to-core-1.40

Conversation

@christian-byrne
Copy link
Contributor

Backport of #9542 to core/1.40.

Conflict: resolveSubgraphInputTarget.ts was modify/delete — kept as new file (the fix).

Original PR: #9542
Pipeline ticket: 15e1f241-efaa-4fe5-88ca-4ccc7bfb3345

…button widgets (#9542)

Fix non-widget inputs on nested subgraphs appearing twice — once as
slots and once as unresolved button widgets.

- **What**: Add `getTargetWidget()` guard in the `isSubgraphNode()`
branch of `resolveSubgraphInputTarget`, matching the existing check for
non-subgraph nodes. Non-widget inputs (e.g. AUDIO, IMAGE) now return
`undefined` instead of a bogus promotion entry.

`resolveSubgraphInputTarget` had an asymmetry: the non-subgraph branch
checked `getTargetWidget()` before returning, but the `isSubgraphNode()`
branch returned unconditionally for every input. For nested subgraphs
where non-widget slots are linked through to inner SubgraphNode inputs,
this created `PromotedWidgetView` entries that failed `resolveDeepest()`
(falling back to `type: 'button'`), while the inputs also rendered as
normal slot circles since `input.widget` was never set by
`_resolveInputWidget` (which correctly skipped them).

┆Issue is synchronized with this [Notion
page](https://www.notion.so/PR-9542-fix-prevent-non-widget-inputs-on-nested-subgraphs-from-appearing-as-button-widgets-31c6d73d3650816387c3f97f0385e762)
by [Unito](https://www.unito.io)

---------

Co-authored-by: Amp <amp@ampcode.com>
@christian-byrne christian-byrne requested a review from a team as a code owner March 8, 2026 02:30
@dosubot dosubot bot added the size:L This PR changes 100-499 lines, ignoring generated files. label Mar 8, 2026
@github-actions
Copy link

github-actions bot commented Mar 8, 2026

🎨 Storybook Build Status

Build completed successfully!

⏰ Completed at: 03/08/2026, 02:31:59 AM UTC

🔗 Links


🎉 Your Storybook is ready for review!

@github-actions
Copy link

github-actions bot commented Mar 8, 2026

Playwright: 🕵🏻 0 passed, 0 failed

📊 Browser Reports
  • chromium: ❌ Deployment failed
  • chromium-2x: ❌ Deployment failed
  • chromium-0.5x: ❌ Deployment failed
  • mobile-chrome: ❌ Deployment failed

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Mar 8, 2026

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: a1ecd1b6-fd6c-4970-903e-08b1db9045e8

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch backport-9542-to-core-1.40

Comment @coderabbitai help to get the list of available commands and usage tips.

@christian-byrne christian-byrne merged commit 00490e8 into core/1.40 Mar 8, 2026
10 of 15 checks passed
@christian-byrne christian-byrne deleted the backport-9542-to-core-1.40 branch March 8, 2026 02:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:L This PR changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants