Conversation
EncoderOrderingTests pins that XMLCoder emits child elements in CodingKeys declaration order and sorts only under the opt-in .sortedKeys, so a future XMLCoder bump that changes default ordering fails loudly. ChoiceEncodingSpike answers the Step 3 (#8) design question: the synthesized decode of an items = "" choice array silently yields an empty array, so Spine must hand-write init(from:) (attributes via the keyed container, items via singleValueContainer choice-array decode); the synthesized encode with items = "" + DynamicNodeEncoding composes and emits children in array order with attributes intact. SpineOrderTests asserts the transitions FeaturePair spine is asset-clip, transition, asset-clip as a raw tree (permanent), and marks the round-trip order assertion XCTExpectFailure until #8 lands ordered Spine.items (XCTSkip on corelibs-xctest platforms). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* Step 3: Ordered Spine.items (#8) * Replace choice if/switch ladders with XMLChoiceField tables Avoid cyclomatic_complexity disables on SpineItem/Spine by walking field-handler and batch-append tables. Document the anti-pattern in agent notes and a Cursor rule. Co-authored-by: Cursor <cursoragent@cursor.com> * Restore XMLChoiceField.encode after helper split The encode method was dropped when OrderedChoiceItems moved to its own file; choice encoding needs it. Co-authored-by: Cursor <cursoragent@cursor.com> * Add XMLChoiceCodable and OrderedChoiceItems payloads/replace Share choice decode/encode via protocol extension and fold typed slice get/set into OrderedChoiceItems so Spine drops isX accessors. Co-authored-by: Cursor <cursoragent@cursor.com> * Move Spine typed item accessors into Spine+Items Keep Spine.swift under the file_length warning limit. Co-authored-by: Cursor <cursoragent@cursor.com> * Fix strict lint violations - Expand one-line conditional returns in SpineItem+Accessors.swift - Split XMLChoiceCodable protocol and extension out of XMLChoiceField.swift into XMLChoiceCodable.swift (one declaration per file, file types order) - Move ChoiceKey typealias above CodingKeys enum in SpineItem.swift - Apply swift-format/swiftlint autofixes (line breaks, whitespace) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> * Replace OrderedChoiceItems with OrderedChoiceContainer protocol. Co-authored-by: Cursor <cursoragent@cursor.com> --------- Co-authored-by: Cursor <cursoragent@cursor.com> Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
…ngKeys (#23) * feat: implement AnchoredItem choice enum and DTD-ordered CodingKeys for story elements (Issue #9) * Replace choice if/switch ladders with XMLChoiceField tables Avoid cyclomatic_complexity disables on SpineItem/Spine by walking field-handler and batch-append tables. Document the anti-pattern in agent notes and a Cursor rule. Co-authored-by: Cursor <cursoragent@cursor.com> * Apply XMLChoiceField tables to AnchoredItem and seed inits Convert AnchoredItem choice Codable and AssetClip/Storyline/SyncClip/ RefClip/MCClip convenience seed chains to table-driven helpers so large if/switch ladders are gone on Step 4. Co-authored-by: Cursor <cursoragent@cursor.com> * Add XMLChoiceCodable and OrderedChoiceItems payloads/replace Share choice decode/encode via protocol extension and fold typed slice get/set into OrderedChoiceItems so Spine drops isX accessors. Co-authored-by: Cursor <cursoragent@cursor.com> * Clear file_length/line_length via choice protocols and splits Adopt XMLChoiceCodable and AnchoredChoiceContainer, wrap DTD comments, and move decode inits into +Coding files so clip types need no lint disables. Co-authored-by: Cursor <cursoragent@cursor.com> * Fix step4 lint violations: decoder docs, AnchoredItem ordering, auto-format - Document public init(from decoder:) in the five clip +Coding files - Put conditional returns on their own lines in AnchoredItem+Accessors - Move ChoiceKey typealias ahead of CodingKeys in AnchoredItem - Apply swift-format/swiftlint auto-fixes (trailing comma, whitespace) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> * Remove stray doc comments duplicated from +Coding inits Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> * Replace OrderedChoiceItems with OrderedChoiceContainer protocol. Co-authored-by: Cursor <cursoragent@cursor.com> --------- Co-authored-by: Cursor <cursoragent@cursor.com> Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
* Step 5: ResourceID/ResourceRef and typed resource shells (#10). Adopt phantom-typed refs across resources, document shells, and story refs; keep Asset.audioRate as String Hz while Sequence/Multicam use AudioRate. Co-authored-by: Cursor <cursoragent@cursor.com> * Replace choice if/switch ladders with XMLChoiceField tables Avoid cyclomatic_complexity disables on SpineItem/Spine by walking field-handler and batch-append tables. Document the anti-pattern in agent notes and a Cursor rule. Co-authored-by: Cursor <cursoragent@cursor.com> * Restore XMLChoiceField.encode after helper split The encode method was dropped when OrderedChoiceItems moved to its own file; choice encoding needs it. Co-authored-by: Cursor <cursoragent@cursor.com> * Apply XMLChoiceField tables to AnchoredItem and seed inits Convert AnchoredItem choice Codable and AssetClip/Storyline/SyncClip/ RefClip/MCClip convenience seed chains to table-driven helpers so large if/switch ladders are gone on Step 4. Co-authored-by: Cursor <cursoragent@cursor.com> * Add XMLChoiceCodable and OrderedChoiceItems payloads/replace Share choice decode/encode via protocol extension and fold typed slice get/set into OrderedChoiceItems so Spine drops isX accessors. Co-authored-by: Cursor <cursoragent@cursor.com> * Move Spine typed item accessors into Spine+Items Keep Spine.swift under the file_length warning limit. Co-authored-by: Cursor <cursoragent@cursor.com> * Clear file_length/line_length via choice protocols and splits Adopt AnchoredChoiceContainer on clip hosts, wrap DTD comments, and move decode inits into +Coding extensions while keeping ResourceRef typing. Co-authored-by: Cursor <cursoragent@cursor.com> * Apply lint auto-fixes from swift-format and swiftlint No step5-specific violations found; remaining lint findings are inherited from step3/step4 and resolve when those branches merge up. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> * Replace OrderedChoiceItems with OrderedChoiceContainer protocol. Co-authored-by: Cursor <cursoragent@cursor.com> --------- Co-authored-by: Cursor <cursoragent@cursor.com> Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
#14). - .gitignore: /transitions.fcpxml and /titles.fcpxml are reproducible via `swift run fcpxml-dsl export`. - typed-generation-gate.md: accept the DSL import gate — transitions and titles imported into Final Cut Pro, dissolve confirmed between clips, anchored title lane confirmed. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
Important Review skippedToo many files! This PR contains 417 files, which is 317 over the limit of 100. To get a review, narrow the scope: Upgrade to a paid plan to raise the limit. Usage-priced reviews support at most 300 files. ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (417)
You can disable this status message by setting the 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. Comment |
SBObject proxies resolve sdef term names (name, id, duration, file, ...) through value(forKey:), not the sdef cocoa keys the inspector was passing (displayName, uniqueIdentifier, durationDict, URL). The cocoa keys raised NSUnknownKeyException against a running Final Cut Pro, and ObjC exceptions are uncatchable from Swift, so the whole test process died. Every key was probed individually against a live FCP in isolated child processes before adoption: - name/id/file/duration/frameDuration/startTime/timecodeFormat and the children keys all resolve live. - persistent ID is declared in the sdef but unimplemented by FCP (errors -1728 even in AppleScript); persistentID is now optional on the scripted models and read tolerantly. - media time records arrive as value/timescale/epoch/flags dictionaries, which the existing parser already handles. - timecode format arrives as an OSType NSNumber (drop/ndrp/unsp); the parser now decodes four-char codes, with a regression test. Mock tests re-pin the term-name contract so they can no longer pass while the live path is broken, and the live test now asserts non-empty library content when Final Cut is running (verified live: 12 tests, 6 suites pass with FCP open). Docs known-issue callouts removed accordingly. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Apple-platform legs were using the library-only FCPKit scheme (no test action); omit scheme so swift-build derives FCPKit-Package. Stub xmllint Process usage on iOS/tvOS/watchOS/visionOS. Point CodeQL at xcode-27 so autobuild can parse swift-tools-version 6.4. Co-authored-by: Cursor <cursoragent@cursor.com>
|
You are seeing this message because GitHub Code Scanning has recently been set up for this repository, or this pull request contains the workflow file for the Code Scanning tool. What Enabling Code Scanning Means:
For more information about GitHub Code Scanning, check out the documentation. |
Merges the v0.1.0 release branch into main: Steps 0–8 of the accepted plan (ADR 0002) plus scaffolding, gates, and docs sync.
Highlights
FCPTimeand strong value types, DTD-orderedCodingKeys, single orderedSpine.items(fixes the transition mis-ordering Final Cut rejected),AnchoredItemchoice arrays, resources and document shells.FCPKitDSL: create-first authoring (Document+ result builders) with transition overlap packing, anchored lanes, and DTD-valid export (media-rep, not pre-1.6src);fcpxml-dslCLI exports smoke-test cuts and drivesverify-import.FCPKitScripting: macOS-only read-only ScriptingBridge inspector.docs/manual/typed-generation-gate.md) — transitions and titles cuts imported, dissolve confirmed between clips.Before merging
v0.1.x) so it is included here, then close Step 8: Docs sync after code lands #13.Known issue shipped with v0.1.0
FCPKitScriptingSBObject bridge crashes against a live running Final Cut Pro (cocoa keys vs sdef term names). Deliberately deferred past v0.1.0.After merging
v0.1.0.🤖 Generated with Claude Code