mirror of
https://github.com/Comfy-Org/comfy-swift-sdk.git
synced 2026-11-04 23:47:26 +00:00
[PR #24] [MERGED] refactor(transport): remove dead WebSocket frame DTOs and unused typealias #27
Labels
No labels
enhancement
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Comfy-Org/comfy-swift-sdk#27
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/Comfy-Org/comfy-swift-sdk/pull/24
Author: @mattmillerai
Created: 7/4/2026
Status: ✅ Merged
Merged: 7/5/2026
Merged by: @mattmillerai
Base:
main← Head:chore/remove-dead-ws-frame-dtos📝 Commits (1)
160865frefactor(transport): remove dead WebSocket frame DTOs and unused typealias📊 Changes
1 file changed (+0 additions, -34 deletions)
View changed files
📝
Sources/ComfySwiftSDK/Internal/DTOs/JobStatusDTO.swift(+0 -34)📄 Description
ELI-5
There were four pieces of "dead" code in the WebSocket message file: three little
data-shape structs and one nickname (typealias) that nothing in the project ever
used. This PR deletes them. Nothing changes at runtime — it just removes clutter.
What
Removes declaration-only code from
Internal/DTOs/JobStatusDTO.swift:struct ProgressFrameDatastruct ExecutingFrameDatastruct ExecutionSuccessFrameDatatypealias JobStatusDTO = JobDetailResponseWhy
All four were verified unused via grep across
Sources+Tests— each appearedonly at its own declaration. The read loop parses
executing/progressframes byhand (
envelope.data?.value as? [String: Any], manualInt→Doublecoercion), sothese typed structs were never wired in;
ExecutionSuccessFrameDataand theJobStatusDTOalias likewise had no consumers.Scope notes / judgment calls
ExecutedFrameDataandExecutionErrorFrameDataare decoded and used in
WebSocketSession.swift(lines 236 and 308) — untouched.NodeOutputPayload.audioin place. It is decoded-but-never-read deadplumbing, but removing it also removes latent intent to support audio outputs —
deliberately left for maintainers.
executing/progressparsing onto typed structs). That is a real but optionalmedium-risk refactor that must preserve the tolerant "skip unknown/garbled frames"
behavior; out of scope for this zero-risk cleanup.
Testing
swift build— clean.swift test --no-parallel— 150 tests in 20 suites passed, including theWebSocket frame tests.
Pure deletion of dead declarations; no behavior change.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.