Very Big Refactor 2#142
Merged
Merged
Conversation
… node removal - Rename add_node to add_primitive_node, node_type to type_ - Rename update_node_init_args to update_primitive_node_init_args - Backend handles edge cleanup on node deletion (not frontend) - Only stop downstream nodes on delete, not upstream - Use onEdgesDelete for user-initiated edge removal only Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Three-layer separation in GraphManager: - Graph topology: nodes/edges CRUD (unchanged) - Channel topology: _reconcile() returns (sender_plan, receiver_plan) as a pure plan without touching live handles - Wiring: run() creates fresh Sender/Receiver from the plan, stores on Node.senders/Node.receivers. stop() clears them. Also: - Receiver takes (channel, stop_event) in __init__, registers immediately - Remove _wire/_unwire from Receiver - Remove _sender_handles, _receiver_handles, _ui_channels from GraphManager - sender_handles()/receiver_handles() rebuilt from nodes on the fly - CompositeComponent typed properly instead of Component[Any, Any] - CompositeComponent boundary naming uses slot name disambiguation - Only stop downstream nodes on delete_node, not upstream Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
… and wiring - _reconcile() returns (sender_plan, receiver_plan) as a pure plan - run() creates fresh Sender/Receiver from the plan, stores on Node - stop() marks senders as stopped, doesn't clear handles - Receiver registers in __init__, unregisters in __del__ - Remove _wire/_unwire, _sender_handles, _receiver_handles, _ui_channels - run() accepts optional overrides for composite boundary wiring - CompositeComponent uses tuple I/O with proper type bounds - Composite boundary slot naming uses disambiguation (slot, Type.slot, Type.slot.N) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…oller - UIChannelBridge owns WebSocket lifecycle via run(ws) - wire() creates UI channels and returns overrides for GraphManager.run() - Paired encode/decode functions for binary and JSON wire formats - One blocking task per UI output using Receiver properly - Controller reduced to accept + bridge.run() - Move SenderKey/ReceiverKey to utils - CompositeComponent uses tuple I/O with proper type bounds Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…oller - UIChannelBridge owns WebSocket lifecycle via run(ws) - wire() creates UI channels and returns overrides for GraphManager.run() - Paired encode/decode functions for binary and JSON wire formats - One blocking task per UI output using Receiver properly - Controller reduced to accept + bridge.run() - Move SenderKey/ReceiverKey to utils - Update all tests for new Receiver(channel, stop_event) signature - Update tests for update_primitive_node_init_args returning (node, was_running) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…soon_threadsafe - run(ws) blocks for WS lifetime, stores loop for cross-thread scheduling - wire() creates channels from sync thread, schedules task spawning on event loop - Handles all orderings: WS before start, start before WS, config change while running - WS disconnect cleans up all tasks in run()'s finally block Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…otion) - Sidebar now groups by functionality (Audio/Vision/LLM/Motion/Misc) at top level - IO tags (Sources/Conduits/Sinks) shown as subsections within each group - Fix tag names: video→vision, image/movement→motion to match backend - Add null guard for unknown functionality tags in InfoPanel Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…ture Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…nges Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Test Coverage
|
- GraphManager section: handles on Node, _reconcile returns plans - Channel topology: three-layer separation explained - UI channels: UIChannelBridge owns WS lifecycle, external to GraphManager - Node CRUD: renamed methods, delete_node only stops downstream - Frontend: direct backend calls via API_BASE, no proxy Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Fix dev.ts: use --no-default-groups instead of --no-group cuda12 - Add --amd as alias for --rocm - README: add AMD/ROCm setup instructions with bun run dev -- --amd Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…ive sleep, composite non-blocking stop - DoNothing: break on None (was spinning indefinitely ignoring stop) - Throttle: use stop_event.wait(interval) instead of time.sleep() so stop is detected immediately during the interval - CompositeComponent.stop(): only signal inner components, don't join — prevents cascading join timeouts from blocking outer stop loop Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Replace warmSubtypeCache's N*(N-1) individual /is-subtype calls with a single /subtype-pairs batch endpoint. Eliminates hundreds of requests on page load that were lagging the frontend. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
add_node/update_node_init_argstoadd_primitive_node/update_primitive_node_init_args_reconcile()returns(sender_plan, receiver_plan)as a pure planrun()creates fresh Sender/Receiver from the plan, stores on Node__init__, no more_wire/_unwireUIChannelBridgewithwire()+run(ws)accept + bridge.run()SenderKey/ReceiverKeytoutilsfor shared accessonEdgesDeletecallback, notonEdgesChangeTest plan
uv run pytestpasses (149/149)uv run mypy srccleanuv run ruff check .clean🤖 Generated with Claude Code