Skip to content

Conversation

@AustinMroz
Copy link
Collaborator

@AustinMroz AustinMroz commented Dec 8, 2025

When moving an existing link with subgraphInput as source to a new node, the prior link is removed, but the previous target node would not have it's link property cleared.

Resolves #7225

Also re-enables several functional skipped tests.

It feels like I'm having to play whack-a-mole reimplementing the same fixes on every permutation of subgraphIO links. I'd like to setup up a unified test set that covers them all, but wouldn't want the added work to further delay this fix.

┆Issue is synchronized with this Notion page by Unito

@AustinMroz AustinMroz requested a review from a team as a code owner December 8, 2025 19:28
@dosubot dosubot bot added the size:M This PR changes 30-99 lines, ignoring generated files. label Dec 8, 2025
@github-actions
Copy link

github-actions bot commented Dec 8, 2025

🎭 Playwright Test Results

⚠️ Tests passed with flaky tests

⏰ Completed at: 12/08/2025, 07:48:19 PM UTC

📈 Summary

  • Total Tests: 497
  • Passed: 485 ✅
  • Failed: 0
  • Flaky: 2 ⚠️
  • Skipped: 10 ⏭️

📊 Test Reports by Browser

  • chromium: View Report • ✅ 476 / ❌ 0 / ⚠️ 2 / ⏭️ 10
  • chromium-2x: View Report • ✅ 2 / ❌ 0 / ⚠️ 0 / ⏭️ 0
  • chromium-0.5x: View Report • ✅ 1 / ❌ 0 / ⚠️ 0 / ⏭️ 0
  • mobile-chrome: View Report • ✅ 6 / ❌ 0 / ⚠️ 0 / ⏭️ 0

🎉 Click on the links above to view detailed test results for each browser configuration.

@github-actions
Copy link

github-actions bot commented Dec 8, 2025

🎨 Storybook Build Status

Build completed successfully!

⏰ Completed at: 12/08/2025, 07:38:30 PM UTC

🔗 Links


🎉 Your Storybook is ready for review!

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Dec 8, 2025

📝 Walkthrough

Walkthrough

When moving a link into a subgraph input, the connectToInput flow now resolves the previously connected link, clears its input.link reference (sets it to null), and dispatches an 'input-moved' event. Related tests for disconnection and validation were re-enabled and expanded.

Changes

Cohort / File(s) Summary
Link connection cleanup
src/lib/litegraph/src/canvas/ToInputFromIoNodeLink.ts
connectToInput now resolves the existing link when creating a new link, clears the old input's link (sets to null), and dispatches an 'input-moved' event.
Link validation tests
tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
Re-enabled and expanded tests: added "Link disconnection validation" case verifying input cleanup and callback invocation; re-enabled previously skipped suites (MovingOutputLink, ToOutputRenderLink, dropOnIoNode, isSubgraphInputValidDrop); consolidated imports to include ToInputFromIoNodeLink and LinkDirection.

Pre-merge checks and finishing touches

✅ Passed checks (2 passed)
Check name Status Explanation
Linked Issues check ✅ Passed Code changes properly address linked issue #7225 by resolving and clearing input links when moving subgraphInput connections, preventing orphaned node references.
Out of Scope Changes check ✅ Passed All changes are scoped to fixing subgraph input link disconnection behavior and re-enabling related tests, with no unrelated modifications.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch austin/move-subgraph-input-link-fix

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: ASSERTIVE

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 7bfe62d and 6d705ef.

📒 Files selected for processing (1)
  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts (4 hunks)
🧰 Additional context used
📓 Path-based instructions (4)
tests-ui/**/*.test.{js,ts,jsx,tsx}

📄 CodeRabbit inference engine (tests-ui/CLAUDE.md)

tests-ui/**/*.test.{js,ts,jsx,tsx}: Write tests for new features
Follow existing test patterns in the codebase
Use existing test utilities rather than writing custom utilities
Mock external dependencies in tests
Always prefer vitest mock functions over writing verbose manual mocks

Files:

  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
**/*.ts

📄 CodeRabbit inference engine (AGENTS.md)

Use TypeScript exclusively; no new JavaScript code

Files:

  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
**/*.{ts,vue}

📄 CodeRabbit inference engine (AGENTS.md)

**/*.{ts,vue}: Use camelCase for variable and function names
Indent with 2 spaces (see .prettierrc)
Use single quotes for strings (see .prettierrc)
No trailing semicolons (see .prettierrc)
Maximum line width of 80 characters (see .prettierrc)
Sort and group imports by plugin (run pnpm format before committing)
Never use any type; use proper TypeScript types instead
Never use as any type assertions; fix the underlying type issue instead
Avoid code comments unless absolutely necessary; write expressive, self-documenting code instead
When writing new code, ask if there is a simpler way to introduce the same functionality; if yes, choose the simpler approach
Use refactoring to make complex code simpler
Use es-toolkit for utility functions
Use Vite for fast development and building
Implement proper error handling
Write tests for all changes, especially bug fixes to catch future regressions

Files:

  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
**/*.test.ts

📄 CodeRabbit inference engine (AGENTS.md)

**/*.test.ts: Avoid writing change detector tests that just assert default values
Avoid writing tests dependent on non-behavioral features like utility classes or styles
Avoid writing redundant tests

Files:

  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
🧠 Learnings (10)
📓 Common learnings
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/lib/litegraph/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:56.371Z
Learning: Applies to src/lib/litegraph/**/*.{test,spec}.{ts,tsx} : Use provided test helpers `createTestSubgraph` and `createTestSubgraphNode` from `./fixtures/subgraphHelpers` for consistent subgraph test setup
📚 Learning: 2025-11-24T19:47:56.371Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/lib/litegraph/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:56.371Z
Learning: Applies to src/lib/litegraph/**/*.{test,spec}.{ts,tsx} : Use provided test helpers `createTestSubgraph` and `createTestSubgraphNode` from `./fixtures/subgraphHelpers` for consistent subgraph test setup

Applied to files:

  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
📚 Learning: 2025-11-24T19:47:56.371Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/lib/litegraph/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:56.371Z
Learning: Applies to src/lib/litegraph/**/*.{test,spec}.{ts,tsx} : When writing tests for subgraph-related code, always import from the barrel export at `@/lib/litegraph/src/litegraph` to avoid circular dependency issues

Applied to files:

  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
📚 Learning: 2025-11-24T19:47:56.371Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/lib/litegraph/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:56.371Z
Learning: Applies to src/lib/litegraph/**/*.{test,spec}.{js,ts,jsx,tsx} : When adding features, always write vitest unit tests using cursor rules in @.cursor

Applied to files:

  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
📚 Learning: 2025-11-24T19:47:56.371Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/lib/litegraph/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:56.371Z
Learning: Applies to src/lib/litegraph/**/*.{js,ts,jsx,tsx} : Do not replace `&&=` or `||=` with `=` when there is no reason to do so. If you do find a reason to remove either `&&=` or `||=`, leave a comment explaining why the removal occurred

Applied to files:

  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
📚 Learning: 2025-12-06T00:52:35.750Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-06T00:52:35.750Z
Learning: Applies to **/*.test.ts : Avoid writing redundant tests

Applied to files:

  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
📚 Learning: 2025-11-24T19:47:56.371Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/lib/litegraph/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:56.371Z
Learning: Applies to src/lib/litegraph/**/*.{js,ts,jsx,tsx} : Run ESLint instead of manually figuring out whitespace fixes or other trivial style concerns using the `pnpm lint:fix` command

Applied to files:

  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
📚 Learning: 2025-11-24T19:47:56.371Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/lib/litegraph/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:56.371Z
Learning: Applies to src/lib/litegraph/**/*.{ts,tsx} : Type assertions are an absolute last resort. In almost all cases, they are a crutch that leads to brittle code

Applied to files:

  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
📚 Learning: 2025-12-06T00:52:35.750Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-06T00:52:35.750Z
Learning: Applies to **/*.test.ts : Avoid writing tests dependent on non-behavioral features like utility classes or styles

Applied to files:

  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
📚 Learning: 2025-11-24T19:48:09.318Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: .cursor/rules/unit-test.mdc:0-0
Timestamp: 2025-11-24T19:48:09.318Z
Learning: Applies to test/**/*.{test,spec}.{js,ts,jsx,tsx} : Prefer the use of `test.extend` over loose variables; import `test as baseTest` from `vitest`

Applied to files:

  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
  • GitHub Check: setup
  • GitHub Check: test
  • GitHub Check: lint-and-format
  • GitHub Check: collect
🔇 Additional comments (2)
tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts (2)

25-66: Excellent test coverage for the disconnection fix.

This new test directly validates the PR objective by verifying that when a link is moved from fromTargetNode to toTargetNode, the old node's input.link is properly cleared (set to null) and both nodes receive the onConnectionsChange callback. The test structure is clear and comprehensive.


68-178: Well-structured validation tests re-enabled.

The re-enabled tests for MovingOutputLink and ToOutputRenderLink provide comprehensive coverage of type compatibility checking, including edge cases like wildcard types. The test structure is clean and assertions are appropriate.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

@github-actions
Copy link

github-actions bot commented Dec 8, 2025

Bundle Size Report

Summary

  • Raw size: 17 MB baseline 17 MB — 🔴 +183 B
  • Gzip: 3.38 MB baseline 3.38 MB — 🔴 +37 B
  • Brotli: 2.59 MB baseline 2.59 MB — 🟢 -81 B
  • Bundles: 97 current • 97 baseline • 37 added / 37 removed

Category Glance
App Entry Points 🔴 +183 B (3.2 MB) · Vendor & Third-Party ⚪ 0 B (8.56 MB) · Other ⚪ 0 B (3.81 MB) · Graph Workspace ⚪ 0 B (976 kB) · Panels & Settings ⚪ 0 B (298 kB) · UI Components ⚪ 0 B (177 kB) · + 3 more

Per-category breakdown
App Entry Points — 3.2 MB (baseline 3.2 MB) • 🔴 +183 B

Main entry bundles and manifests

File Before After Δ Raw Δ Gzip Δ Brotli
assets/index-I9PESaLu.js (new) 2.98 MB 🔴 +2.98 MB 🔴 +620 kB 🔴 +471 kB
assets/index-D1h2eUqO.js (removed) 2.98 MB 🟢 -2.98 MB 🟢 -620 kB 🟢 -471 kB
assets/index-BeBjGZY2.js (removed) 223 kB 🟢 -223 kB 🟢 -47.6 kB 🟢 -39.3 kB
assets/index-DpVC9esA.js (new) 223 kB 🔴 +223 kB 🔴 +47.6 kB 🔴 +39.2 kB
assets/index-Be5KSsfa.js (removed) 345 B 🟢 -345 B 🟢 -245 B 🟢 -234 B
assets/index-Hrxu4o2R.js (new) 345 B 🔴 +345 B 🔴 +245 B 🔴 +232 B

Status: 3 added / 3 removed

Graph Workspace — 976 kB (baseline 976 kB) • ⚪ 0 B

Graph editor runtime, canvas, workflow orchestration

File Before After Δ Raw Δ Gzip Δ Brotli
assets/GraphView-CpqxrtV8.js (new) 976 kB 🔴 +976 kB 🔴 +189 kB 🔴 +144 kB
assets/GraphView-DI4puqjr.js (removed) 976 kB 🟢 -976 kB 🟢 -189 kB 🟢 -144 kB

Status: 1 added / 1 removed

Views & Navigation — 6.54 kB (baseline 6.54 kB) • ⚪ 0 B

Top-level views, pages, and routed surfaces

File Before After Δ Raw Δ Gzip Δ Brotli
assets/UserSelectView-Bhn-2v3H.js (new) 6.54 kB 🔴 +6.54 kB 🔴 +2.14 kB 🔴 +1.89 kB
assets/UserSelectView-CBG_a4YX.js (removed) 6.54 kB 🟢 -6.54 kB 🟢 -2.14 kB 🟢 -1.89 kB

Status: 1 added / 1 removed

Panels & Settings — 298 kB (baseline 298 kB) • ⚪ 0 B

Configuration panels, inspectors, and settings screens

File Before After Δ Raw Δ Gzip Δ Brotli
assets/CreditsPanel-BXrtuVH3.js (removed) 21.4 kB 🟢 -21.4 kB 🟢 -5.15 kB 🟢 -4.5 kB
assets/CreditsPanel-CEKLyM2l.js (new) 21.4 kB 🔴 +21.4 kB 🔴 +5.15 kB 🔴 +4.5 kB
assets/KeybindingPanel-B31kGVmJ.js (removed) 13.6 kB 🟢 -13.6 kB 🟢 -3.42 kB 🟢 -3.01 kB
assets/KeybindingPanel-ujovHXBm.js (new) 13.6 kB 🔴 +13.6 kB 🔴 +3.42 kB 🔴 +3.01 kB
assets/ExtensionPanel-BfNlrLpW.js (new) 10.8 kB 🔴 +10.8 kB 🔴 +2.58 kB 🔴 +2.26 kB
assets/ExtensionPanel-C1lfKfnh.js (removed) 10.8 kB 🟢 -10.8 kB 🟢 -2.57 kB 🟢 -2.26 kB
assets/AboutPanel-1FAvEruk.js (new) 9.16 kB 🔴 +9.16 kB 🔴 +2.46 kB 🔴 +2.21 kB
assets/AboutPanel-Hsms0ZMn.js (removed) 9.16 kB 🟢 -9.16 kB 🟢 -2.46 kB 🟢 -2.21 kB
assets/ServerConfigPanel-D4My8w-S.js (new) 6.56 kB 🔴 +6.56 kB 🔴 +1.83 kB 🔴 +1.63 kB
assets/ServerConfigPanel-DMtQddW0.js (removed) 6.56 kB 🟢 -6.56 kB 🟢 -1.83 kB 🟢 -1.63 kB
assets/UserPanel-BUmevTzh.js (removed) 6.23 kB 🟢 -6.23 kB 🟢 -1.72 kB 🟢 -1.5 kB
assets/UserPanel-D24XGXpW.js (new) 6.23 kB 🔴 +6.23 kB 🔴 +1.72 kB 🔴 +1.5 kB
assets/settings-BhbWhsRg.js 101 B 101 B ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-BXTtSH4O.js 33.3 kB 33.3 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-C9Pzn-NG.js 25.2 kB 25.2 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-CCy2fA_h.js 27.3 kB 27.3 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-CQpqEFfl.js 26.6 kB 26.6 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-DHcnxypw.js 21.7 kB 21.7 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-DhFTK9fY.js 25.1 kB 25.1 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-DlT4t_ui.js 25.9 kB 25.9 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-DRgSrIdD.js 24.2 kB 24.2 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-tjkeqiZq.js 21.1 kB 21.1 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B

Status: 6 added / 6 removed

UI Components — 177 kB (baseline 177 kB) • ⚪ 0 B

Reusable component library chunks

File Before After Δ Raw Δ Gzip Δ Brotli
assets/Load3D.vue_vue_type_script_setup_true_lang-asgUvVDO.js (removed) 53.9 kB 🟢 -53.9 kB 🟢 -8.52 kB 🟢 -7.32 kB
assets/Load3D.vue_vue_type_script_setup_true_lang-CALpazPi.js (new) 53.9 kB 🔴 +53.9 kB 🔴 +8.52 kB 🔴 +7.32 kB
assets/WidgetSelect.vue_vue_type_script_setup_true_lang-BzzDqktB.js (removed) 48 kB 🟢 -48 kB 🟢 -10.3 kB 🟢 -8.97 kB
assets/WidgetSelect.vue_vue_type_script_setup_true_lang-hEHoMvAs.js (new) 48 kB 🔴 +48 kB 🔴 +10.3 kB 🔴 +8.97 kB
assets/LazyImage.vue_vue_type_script_setup_true_lang-9WzqYsb6.js (removed) 46.9 kB 🟢 -46.9 kB 🟢 -10.5 kB 🟢 -9.17 kB
assets/LazyImage.vue_vue_type_script_setup_true_lang-Bf7QUUPh.js (new) 46.9 kB 🔴 +46.9 kB 🔴 +10.5 kB 🔴 +9.17 kB
assets/WidgetInputNumber.vue_vue_type_script_setup_true_lang-BF1qK7ks.js (removed) 12.9 kB 🟢 -12.9 kB 🟢 -3.37 kB 🟢 -2.97 kB
assets/WidgetInputNumber.vue_vue_type_script_setup_true_lang-DN8q94lj.js (new) 12.9 kB 🔴 +12.9 kB 🔴 +3.37 kB 🔴 +2.96 kB
assets/ComfyQueueButton-Brd5-i2o.js (removed) 8.44 kB 🟢 -8.44 kB 🟢 -2.48 kB 🟢 -2.21 kB
assets/ComfyQueueButton-DXkjXa4K.js (new) 8.44 kB 🔴 +8.44 kB 🔴 +2.48 kB 🔴 +2.21 kB
assets/MediaTitle.vue_vue_type_script_setup_true_lang-60q2K1g6.js (removed) 897 B 🟢 -897 B 🟢 -505 B 🟢 -441 B
assets/MediaTitle.vue_vue_type_script_setup_true_lang-jWE-tsEZ.js (new) 897 B 🔴 +897 B 🔴 +502 B 🔴 +442 B
assets/UserAvatar.vue_vue_type_script_setup_true_lang-BPGmgVoN.js 1.34 kB 1.34 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/WidgetButton-CFWrwaAG.js 2.04 kB 2.04 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/WidgetLayoutField.vue_vue_type_script_setup_true_lang-6ZIklFyS.js 2.26 kB 2.26 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B

Status: 6 added / 6 removed

Data & Services — 12.5 kB (baseline 12.5 kB) • ⚪ 0 B

Stores, services, APIs, and repositories

File Before After Δ Raw Δ Gzip Δ Brotli
assets/keybindingService-BZ_vjQKL.js (new) 7.51 kB 🔴 +7.51 kB 🔴 +1.83 kB 🔴 +1.57 kB
assets/keybindingService-DOdJQGQ-.js (removed) 7.51 kB 🟢 -7.51 kB 🟢 -1.83 kB 🟢 -1.58 kB
assets/audioService-1IEQi7oC.js (removed) 2.2 kB 🟢 -2.2 kB 🟢 -963 B 🟢 -828 B
assets/audioService-DUGB7UrJ.js (new) 2.2 kB 🔴 +2.2 kB 🔴 +962 B 🔴 +830 B
assets/serverConfigStore-L3qzi_1Z.js 2.83 kB 2.83 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B

Status: 2 added / 2 removed

Utilities & Hooks — 2.94 kB (baseline 2.94 kB) • ⚪ 0 B

Helpers, composables, and utility bundles

File Before After Δ Raw Δ Gzip Δ Brotli
assets/audioUtils-D_9-6pyM.js (removed) 1.41 kB 🟢 -1.41 kB 🟢 -651 B 🟢 -553 B
assets/audioUtils-DqFgWhwZ.js (new) 1.41 kB 🔴 +1.41 kB 🔴 +652 B 🔴 +547 B
assets/mathUtil-CTARWQ-l.js 1.07 kB 1.07 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeFilterUtil-CXKCRJ-m.js 460 B 460 B ⚪ 0 B ⚪ 0 B ⚪ 0 B

Status: 1 added / 1 removed

Vendor & Third-Party — 8.56 MB (baseline 8.56 MB) • ⚪ 0 B

External libraries and shared vendor chunks

File Before After Δ Raw Δ Gzip Δ Brotli
assets/vendor-chart-DJFoH6N_.js 452 kB 452 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/vendor-other-BZV8aGUB.js 3.98 MB 3.98 MB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/vendor-primevue-DUTcKlCc.js 1.96 MB 1.96 MB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/vendor-three-aR6ntw5X.js 1.37 MB 1.37 MB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/vendor-tiptap-Cmu0_BY4.js 232 kB 232 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/vendor-vue-Bz22sFex.js 160 kB 160 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/vendor-xterm-BZLod3g9.js 407 kB 407 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
Other — 3.81 MB (baseline 3.81 MB) • ⚪ 0 B

Bundles that do not match a named category

File Before After Δ Raw Δ Gzip Δ Brotli
assets/WidgetRecordAudio-BeDUyUtY.js (new) 20.4 kB 🔴 +20.4 kB 🔴 +5.24 kB 🔴 +4.63 kB
assets/WidgetRecordAudio-DpD84in5.js (removed) 20.4 kB 🟢 -20.4 kB 🟢 -5.24 kB 🟢 -4.63 kB
assets/AudioPreviewPlayer-DCRpNLmv.js (new) 13.5 kB 🔴 +13.5 kB 🔴 +3.4 kB 🔴 +3.04 kB
assets/AudioPreviewPlayer-DnPD0yqv.js (removed) 13.5 kB 🟢 -13.5 kB 🟢 -3.4 kB 🟢 -3.05 kB
assets/WidgetGalleria-D_iyvylS.js (removed) 4.1 kB 🟢 -4.1 kB 🟢 -1.44 kB 🟢 -1.3 kB
assets/WidgetGalleria-D2XBAp3O.js (new) 4.1 kB 🔴 +4.1 kB 🔴 +1.45 kB 🔴 +1.3 kB
assets/WidgetColorPicker-BeH7lUod.js (removed) 3.41 kB 🟢 -3.41 kB 🟢 -1.38 kB 🟢 -1.23 kB
assets/WidgetColorPicker-BQ35cFm8.js (new) 3.41 kB 🔴 +3.41 kB 🔴 +1.38 kB 🔴 +1.23 kB
assets/WidgetMarkdown-2DfuOIth.js (new) 3.08 kB 🔴 +3.08 kB 🔴 +1.28 kB 🔴 +1.12 kB
assets/WidgetMarkdown-yKQtxMyO.js (removed) 3.08 kB 🟢 -3.08 kB 🟢 -1.28 kB 🟢 -1.12 kB
assets/WidgetTextarea-BCAqVuEy.js (removed) 2.93 kB 🟢 -2.93 kB 🟢 -1.17 kB 🟢 -1.04 kB
assets/WidgetTextarea-CFsmC5BH.js (new) 2.93 kB 🔴 +2.93 kB 🔴 +1.17 kB 🔴 +1.04 kB
assets/WidgetAudioUI-Bci4dcon.js (new) 2.85 kB 🔴 +2.85 kB 🔴 +1.16 kB 🔴 +1.06 kB
assets/WidgetAudioUI-Mc0r6mI2.js (removed) 2.85 kB 🟢 -2.85 kB 🟢 -1.16 kB 🟢 -1.06 kB
assets/WidgetInputText-BT_B8m6p.js (removed) 1.99 kB 🟢 -1.99 kB 🟢 -915 B 🟢 -849 B
assets/WidgetInputText-kwPqTpZS.js (new) 1.99 kB 🔴 +1.99 kB 🔴 +916 B 🔴 +848 B
assets/MediaImageBottom-BsJYHyrV.js (removed) 1.57 kB 🟢 -1.57 kB 🟢 -744 B 🟢 -648 B
assets/MediaImageBottom-K4JwcmLs.js (new) 1.57 kB 🔴 +1.57 kB 🔴 +738 B 🔴 +643 B
assets/MediaAudioBottom-BbfDr83j.js (new) 1.52 kB 🔴 +1.52 kB 🔴 +742 B 🔴 +659 B
assets/MediaAudioBottom-ZSjXupIy.js (removed) 1.52 kB 🟢 -1.52 kB 🟢 -742 B 🟢 -655 B
assets/MediaVideoBottom-0YdRvuF-.js (new) 1.52 kB 🔴 +1.52 kB 🔴 +739 B 🔴 +654 B
assets/MediaVideoBottom-CD0KCTOU.js (removed) 1.52 kB 🟢 -1.52 kB 🟢 -740 B 🟢 -655 B
assets/Media3DBottom-CS0llzE_.js (new) 1.5 kB 🔴 +1.5 kB 🔴 +732 B 🔴 +649 B
assets/Media3DBottom-D5Zl9iRU.js (removed) 1.5 kB 🟢 -1.5 kB 🟢 -732 B 🟢 -652 B
assets/Media3DTop-C4GOGwam.js (removed) 1.49 kB 🟢 -1.49 kB 🟢 -764 B 🟢 -653 B
assets/Media3DTop-D9MYk87-.js (new) 1.49 kB 🔴 +1.49 kB 🔴 +766 B 🔴 +650 B
assets/WidgetSelect-2IhiUaok.js (removed) 655 B 🟢 -655 B 🟢 -345 B 🟢 -290 B
assets/WidgetSelect-CU3Gg_UC.js (new) 655 B 🔴 +655 B 🔴 +344 B 🔴 +290 B
assets/WidgetInputNumber-CY0ZA3uD.js (new) 595 B 🔴 +595 B 🔴 +331 B 🔴 +276 B
assets/WidgetInputNumber-DFQL3r39.js (removed) 595 B 🟢 -595 B 🟢 -330 B 🟢 -276 B
assets/Load3D-B2TiljWt.js (new) 424 B 🔴 +424 B 🔴 +268 B 🔴 +223 B
assets/Load3D-CB2816HC.js (removed) 424 B 🟢 -424 B 🟢 -266 B 🟢 -227 B
assets/WidgetLegacy-Bu1RahaX.js (removed) 364 B 🟢 -364 B 🟢 -236 B 🟢 -192 B
assets/WidgetLegacy-msCmtnwz.js (new) 364 B 🔴 +364 B 🔴 +237 B 🔴 +193 B
assets/commands-_s-RvhJR.js 13.6 kB 13.6 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-BuUILW6P.js 13 kB 13 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-BV4R6fLx.js 14.9 kB 14.9 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-BWp4HdfU.js 101 B 101 B ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-CLwPdnT6.js 14.2 kB 14.2 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-CWMchBmd.js 15.9 kB 15.9 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-DazTQhtc.js 12.9 kB 12.9 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-DmWrOe93.js 13.7 kB 13.7 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-DwiH7Kr6.js 13.8 kB 13.8 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-mS3LCNPn.js 14.5 kB 14.5 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-B1JflQcI.js 72.2 kB 72.2 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-B2lyXe48.js 114 kB 114 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-B9XEQ-pc.js 94 kB 94 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-BErKFzc-.js 73.1 kB 73.1 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-Bf7Tze-u.js 83.4 kB 83.4 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-BhGMcO4Q.js 84.3 kB 84.3 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-CPZUloNQ.js 99 kB 99 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-Cw9RZWRY.js 89 B 89 B ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-Dva0z-T2.js 86.5 kB 86.5 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-un0K9wDS.js 81.8 kB 81.8 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/MediaAudioTop-BPDWO8-i.js 1.46 kB 1.46 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/MediaImageTop-BtY1hGDO.js 1.75 kB 1.75 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/MediaVideoTop-ehTZdDBw.js 2.76 kB 2.76 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-8e6QYQW0.js 283 kB 283 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-A_9dx4yn.js 304 kB 304 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-BbD3HDi7.js 307 kB 307 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-BOJhIPft.js 369 kB 369 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-Bw_Jitw_.js 101 B 101 B ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-C-Pw33mW.js 317 kB 317 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-ChLyG0UJ.js 285 kB 285 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-CUVPxA4l.js 342 kB 342 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-Dx5Y4xrW.js 310 kB 310 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-JqO5mNmW.js 306 kB 306 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/WidgetChart-j6EYUdOM.js 2.48 kB 2.48 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/WidgetImageCompare-D5bj5c8l.js 2.21 kB 2.21 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/widgetPropFilter-BIbGSUAt.js 1.28 kB 1.28 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/WidgetToggleSwitch-DPJMnc2A.js 1.58 kB 1.58 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B

Status: 17 added / 17 removed

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (2)
src/lib/litegraph/src/canvas/ToInputFromIoNodeLink.ts (1)

55-72: Resolve and clear the previous input slot before reconnecting

The new cleanup correctly targets the stale input.link, but doing:

const newLink = fromSlot.connect(input, node, fromReroute?.id)

if (existingLink) {
  const { input } = existingLink.resolve(this.network)
  if (input) input.link = null
}

relies on existingLink.resolve(this.network) still pointing at the old input after connect. If SubgraphInput.connect is ever refactored to update the same LLink instance, this would instead clear the new input.

To make this robust and avoid name shadowing, consider:

   connectToInput(
     node: LGraphNode,
     input: INodeInputSlot,
     events: CustomEventTarget<LinkConnectorEventMap>
   ) {
-    const { fromSlot, fromReroute, existingLink } = this
-
-    const newLink = fromSlot.connect(input, node, fromReroute?.id)
-
-    if (existingLink) {
-      // Moving an existing link
-      const { input } = existingLink.resolve(this.network)
-      if (input) input.link = null
+    const { fromSlot, fromReroute, existingLink } = this
+
+    const previousInput = existingLink
+      ? existingLink.resolve(this.network).input
+      : null
+
+    const newLink = fromSlot.connect(input, node, fromReroute?.id)
+
+    if (existingLink) {
+      // Moving an existing link
+      if (previousInput && previousInput !== input) previousInput.link = null
       events.dispatch('input-moved', this)
     } else {
       // Creating a new link
       events.dispatch('link-created', newLink)
     }
   }

This guarantees we always clear the actual previous target slot, independent of how connect mutates links, and improves readability.

tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts (1)

162-177: ToOutputRenderLink test ensures required API surface exists

The test for ToOutputRenderLink confirms that canConnectToSubgraphInput is implemented on the render-link used when connecting to subgraph outputs. This keeps LinkConnector logic safe to call that method without additional guards.

If you later expand behavior here, it could be worth adding a second test that exercises a simple valid/invalid compatibility scenario, but this presence check is sufficient for the current change set.

📜 Review details

Configuration used: CodeRabbit UI

Review profile: ASSERTIVE

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 6081404 and 7bfe62d.

📒 Files selected for processing (2)
  • src/lib/litegraph/src/canvas/ToInputFromIoNodeLink.ts (1 hunks)
  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts (4 hunks)
🧰 Additional context used
📓 Path-based instructions (10)
src/**/*.{vue,ts}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

src/**/*.{vue,ts}: Leverage VueUse functions for performance-enhancing styles
Implement proper error handling
Use vue-i18n in composition API for any string literals. Place new translation entries in src/locales/en/main.json

Files:

  • src/lib/litegraph/src/canvas/ToInputFromIoNodeLink.ts
src/**/*.ts

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

src/**/*.ts: Use es-toolkit for utility functions
Use TypeScript for type safety

Files:

  • src/lib/litegraph/src/canvas/ToInputFromIoNodeLink.ts
src/**/*.{ts,tsx,vue}

📄 CodeRabbit inference engine (src/CLAUDE.md)

src/**/*.{ts,tsx,vue}: Sanitize HTML with DOMPurify to prevent XSS attacks
Avoid using @ts-expect-error; use proper TypeScript types instead
Use es-toolkit for utility functions instead of other utility libraries
Implement proper TypeScript types throughout the codebase

Files:

  • src/lib/litegraph/src/canvas/ToInputFromIoNodeLink.ts
src/**/*.{vue,ts,tsx}

📄 CodeRabbit inference engine (src/CLAUDE.md)

Follow Vue 3 composition API style guide

Files:

  • src/lib/litegraph/src/canvas/ToInputFromIoNodeLink.ts
src/lib/litegraph/**/*.{js,ts,jsx,tsx}

📄 CodeRabbit inference engine (src/lib/litegraph/CLAUDE.md)

src/lib/litegraph/**/*.{js,ts,jsx,tsx}: Run ESLint instead of manually figuring out whitespace fixes or other trivial style concerns using the pnpm lint:fix command
Take advantage of TypedArray subarray when appropriate
The size and pos properties of Rectangle share the same array buffer (subarray); they may be used to set the rectangle's size and position
Prefer single line if syntax over adding curly braces, when the statement has a very concise expression and concise, single line statement
Do not replace &&= or ||= with = when there is no reason to do so. If you do find a reason to remove either &&= or ||=, leave a comment explaining why the removal occurred
When writing methods, prefer returning idiomatic JavaScript undefined over null

Files:

  • src/lib/litegraph/src/canvas/ToInputFromIoNodeLink.ts
src/lib/litegraph/**/*.{ts,tsx}

📄 CodeRabbit inference engine (src/lib/litegraph/CLAUDE.md)

Type assertions are an absolute last resort. In almost all cases, they are a crutch that leads to brittle code

Files:

  • src/lib/litegraph/src/canvas/ToInputFromIoNodeLink.ts
**/*.ts

📄 CodeRabbit inference engine (AGENTS.md)

Use TypeScript exclusively; no new JavaScript code

Files:

  • src/lib/litegraph/src/canvas/ToInputFromIoNodeLink.ts
  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
**/*.{ts,vue}

📄 CodeRabbit inference engine (AGENTS.md)

**/*.{ts,vue}: Use camelCase for variable and function names
Indent with 2 spaces (see .prettierrc)
Use single quotes for strings (see .prettierrc)
No trailing semicolons (see .prettierrc)
Maximum line width of 80 characters (see .prettierrc)
Sort and group imports by plugin (run pnpm format before committing)
Never use any type; use proper TypeScript types instead
Never use as any type assertions; fix the underlying type issue instead
Avoid code comments unless absolutely necessary; write expressive, self-documenting code instead
When writing new code, ask if there is a simpler way to introduce the same functionality; if yes, choose the simpler approach
Use refactoring to make complex code simpler
Use es-toolkit for utility functions
Use Vite for fast development and building
Implement proper error handling
Write tests for all changes, especially bug fixes to catch future regressions

Files:

  • src/lib/litegraph/src/canvas/ToInputFromIoNodeLink.ts
  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
tests-ui/**/*.test.{js,ts,jsx,tsx}

📄 CodeRabbit inference engine (tests-ui/CLAUDE.md)

tests-ui/**/*.test.{js,ts,jsx,tsx}: Write tests for new features
Follow existing test patterns in the codebase
Use existing test utilities rather than writing custom utilities
Mock external dependencies in tests
Always prefer vitest mock functions over writing verbose manual mocks

Files:

  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
**/*.test.ts

📄 CodeRabbit inference engine (AGENTS.md)

**/*.test.ts: Avoid writing change detector tests that just assert default values
Avoid writing tests dependent on non-behavioral features like utility classes or styles
Avoid writing redundant tests

Files:

  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
🧠 Learnings (4)
📓 Common learnings
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/lib/litegraph/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:56.371Z
Learning: Applies to src/lib/litegraph/**/*.{test,spec}.{ts,tsx} : Use provided test helpers `createTestSubgraph` and `createTestSubgraphNode` from `./fixtures/subgraphHelpers` for consistent subgraph test setup
📚 Learning: 2025-11-24T19:47:56.371Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/lib/litegraph/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:56.371Z
Learning: Applies to src/lib/litegraph/**/*.{test,spec}.{ts,tsx} : Use provided test helpers `createTestSubgraph` and `createTestSubgraphNode` from `./fixtures/subgraphHelpers` for consistent subgraph test setup

Applied to files:

  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
📚 Learning: 2025-11-24T19:47:56.371Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/lib/litegraph/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:56.371Z
Learning: Applies to src/lib/litegraph/**/*.{test,spec}.{ts,tsx} : When writing tests for subgraph-related code, always import from the barrel export at `@/lib/litegraph/src/litegraph` to avoid circular dependency issues

Applied to files:

  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
📚 Learning: 2025-11-24T19:47:56.371Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/lib/litegraph/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:56.371Z
Learning: Applies to src/lib/litegraph/**/*.{test,spec}.{js,ts,jsx,tsx} : When adding features, always write vitest unit tests using cursor rules in @.cursor

Applied to files:

  • tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
🧬 Code graph analysis (1)
tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts (3)
tests-ui/tests/litegraph/subgraph/fixtures/subgraphHelpers.ts (1)
  • createTestSubgraph (76-165)
src/lib/litegraph/src/LGraphCanvas.ts (1)
  • renderLink (5970-6021)
src/lib/litegraph/src/canvas/ToInputFromIoNodeLink.ts (1)
  • ToInputFromIoNodeLink (20-147)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
  • GitHub Check: test
  • GitHub Check: setup
  • GitHub Check: lint-and-format
  • GitHub Check: collect
🔇 Additional comments (4)
tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts (4)

25-64: Regression test accurately covers subgraph input link move cleanup

This test sets up a minimal subgraph, moves a link sourced from SubgraphInput to a new target via ToInputFromIoNodeLink, and asserts:

  • Old target input slot’s link is null.
  • New target input slot’s link is non-null.
  • Both nodes’ onConnectionsChange callbacks fire once.

That directly exercises the bug described in the PR and should prevent regressions around stale input.link references when retargeting subgraph input links.


67-160: MovingOutputLink tests give solid coverage of compatibility rules

The MovingOutputLink suite:

  • Verifies the presence of canConnectToSubgraphInput.
  • Checks strict type compatibility (matching number vs mismatched string).
  • Covers wildcard (*) subgraph inputs accepting any type.

The setup via createTestSubgraph and direct LLink construction is clear and focused on behavior, and the expectations align well with typical type-checking semantics for subgraph IO.


179-279: dropOnIoNode tests correctly gate invalid vs valid drops on SubgraphInputNode

These tests:

  • Use createTestSubgraph and MovingOutputLink to simulate dragging links.
  • For invalid types, assert:
    • console.warn is called with the expected message and types.
    • connectToSubgraphInput is not invoked.
  • For valid types, assert connectToSubgraphInput is invoked with the correct subgraph input and event target.

The use of spies for both console.warn and connectToSubgraphInput, and resetting connector.renderLinks, makes the behavior under test very explicit and should help catch regressions in drop handling.


281-356: isSubgraphInputValidDrop tests cover key edge cases

The isSubgraphInputValidDrop suite validates:

  • All-invalid render links → false.
  • All-valid render links → true.
  • Mixed valid/invalid → true (at least one connectable link).
  • A render link without canConnectToSubgraphInputfalse.

This is a good balance between positive and negative cases and also covers the defensive path for non-conforming render links in connector.renderLinks.

Comment on lines 1 to 14
// TODO: Fix these tests after migration
import { beforeEach, describe, expect, it, vi } from 'vitest'

import { LinkConnector } from '@/lib/litegraph/src/litegraph'
import { MovingOutputLink } from '@/lib/litegraph/src/litegraph'
import { ToOutputRenderLink } from '@/lib/litegraph/src/litegraph'
import { LGraphNode, LLink } from '@/lib/litegraph/src/litegraph'
import {
LinkConnector,
MovingOutputLink,
ToOutputRenderLink,
LGraphNode,
LLink
} from '@/lib/litegraph/src/litegraph'
import { ToInputFromIoNodeLink } from '@/lib/litegraph/src/canvas/ToInputFromIoNodeLink'
import type { NodeInputSlot } from '@/lib/litegraph/src/litegraph'
import { LinkDirection } from '@/lib/litegraph/src/types/globalEnums'

Copy link
Contributor

Choose a reason for hiding this comment

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

🧹 Nitpick | 🔵 Trivial

Clean up stale TODO and consider consolidating imports

Now that these tests are fixed and running, the comment on Line 1 (// TODO: Fix these tests after migration) is misleading. It can be removed to avoid confusion.

Also, you’re correctly using the litegraph barrel for most types. If ToInputFromIoNodeLink is (or can be) re-exported from the same barrel, consider importing it from there as well to keep subgraph-related tests on a single import surface and reduce the risk of deep-path coupling.

🤖 Prompt for AI Agents
In tests-ui/tests/litegraph/canvas/LinkConnectorSubgraphInputValidation.test.ts
around lines 1 to 14, remove the stale top-line comment "// TODO: Fix these
tests after migration" and, if ToInputFromIoNodeLink is re-exported by the
litegraph barrel, replace its deep import with a single import from
'@/lib/litegraph/src/litegraph' to consolidate imports; update the import list
accordingly so all litegraph symbols come from the same barrel and delete the
misleading TODO comment.

@AustinMroz AustinMroz force-pushed the austin/move-subgraph-input-link-fix branch from 7bfe62d to 6d705ef Compare December 8, 2025 19:36
@DrJKL DrJKL merged commit 248929c into main Dec 8, 2025
27 checks passed
@DrJKL DrJKL deleted the austin/move-subgraph-input-link-fix branch December 8, 2025 21:22
@christian-byrne christian-byrne added needs-backport Fix/change that needs to be cherry-picked to the current feature freeze branch core/1.33 Backport PRs for core 1.33 labels Dec 9, 2025
github-actions bot pushed a commit that referenced this pull request Dec 9, 2025
When moving an existing link with subgraphInput as source to a new node,
the prior link is removed, but the previous target node would not have
it's link property cleared.

Resolves #7225

Also re-enables several functional skipped tests.

It feels like I'm having to play whack-a-mole reimplementing the same
fixes on every permutation of subgraphIO links. I'd like to setup up a
unified test set that covers them all, but wouldn't want the added work
to further delay this fix.

┆Issue is synchronized with this [Notion
page](https://www.notion.so/PR-7229-When-moving-subgraphInput-link-properly-disconnect-old-link-2c36d73d36508149aca0ce477fee5c9e)
by [Unito](https://www.unito.io)
@comfy-pr-bot
Copy link
Member

@AustinMroz Successfully backported to #7255

@github-actions github-actions bot removed the needs-backport Fix/change that needs to be cherry-picked to the current feature freeze branch label Dec 9, 2025
christian-byrne pushed a commit that referenced this pull request Dec 9, 2025
…ect old link (#7255)

Backport of #7229 to `core/1.33`

Automatically created by backport workflow.

┆Issue is synchronized with this [Notion
page](https://www.notion.so/PR-7255-backport-core-1-33-When-moving-subgraphInput-link-properly-disconnect-old-link-2c46d73d365081cda606e81ec4cbfeec)
by [Unito](https://www.unito.io)

Co-authored-by: AustinMroz <austin@comfy.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

core/1.33 Backport PRs for core 1.33 size:M This PR changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

No link found in parent graph error after unlinked node left in subgraph

5 participants