feat: modernization phase 5 PR2#53
Merged
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
This PR extends the raw receiver’s surfaced payload metadata to include the E1.31 Data Framing Layer sequence number, options bitfield, and synchronization universe (sync address), and adds wire-layer + receiver characterization tests to lock in the new behavior.
Changes:
- Parse and carry
syncAddressfromDataFramingLayer, and add areplacingSyncAddress(with:)helper for tests/packet crafting. - Surface
sequence,options(as a newsACNDataOptionsOptionSet), andsyncUniverseonsACNReceiverRawSourceData, and populate them insACNReceiverRaw. - Add tests validating sync-address parsing and that raw receiver output includes the new metadata.
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| Tests/sACNKitTests/ReceiverRawTests.swift | Adds a characterization test asserting sequence/options/sync-universe are surfaced on raw received data. |
| Tests/sACNKitTests/LayerTests.swift | Extends framing-layer round-trip assertions and adds a focused sync-address parse test. |
| Sources/sACNKit/Receiver/sACNReceiverRaw.swift | Populates newly surfaced metadata fields when emitting sACNReceiverRawSourceData. |
| Sources/sACNKit/Receiver/Delegate/sACNReceiverRawSourceData.swift | Adds public fields for sequence/options/sync-universe to the raw receiver payload type. |
| Sources/sACNKit/Receiver/Delegate/sACNDataOptions.swift | Introduces a public OptionSet representing the on-wire data framing options byte. |
| Sources/sACNKit/Layers/DataFramingLayer.swift | Parses syncAddress and adds a Data mutator to patch it for crafted packets. |
Comments suppressed due to low confidence (1)
Sources/sACNKit/Layers/DataFramingLayer.swift:219
- The doc comment for
replacingPriority(with:)incorrectly says it replaces "options" and describes thepriorityparameter as options, which is misleading for callers.
/// Replaces the `DataFramingLayer` options.
///
/// - Parameters:
/// - priority: The options to be replaced in the layer.
///
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
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.
No description provided.