Skip to content

Update schema metadata validation logic - #1328

Open
ladvoc wants to merge 2 commits into
mainfrom
ladvoc/schema-validation-fix
Open

Update schema metadata validation logic#1328
ladvoc wants to merge 2 commits into
mainfrom
ladvoc/schema-validation-fix

Conversation

@ladvoc

@ladvoc ladvoc commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

No longer allow Other to be used at publish time and allow custom encodings to be used with well-known ones.

@ladvoc
ladvoc requested a review from 1egoman as a code owner August 13, 2026 17:23
@github-actions

github-actions Bot commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

Changeset ✓

This PR includes a changeset covering all affected packages:

Package Bump
livekit patch
livekit-datatrack patch
livekit-ffi patch
livekit-uniffi patch

devin-ai-integration[bot]

This comment was marked as resolved.

Update schema metadata validation logic as per issue #1328.
Comment on lines +193 to +197

/// The 'other' encoding represents an unrecognized encoding on received tracks
/// and cannot be used when publishing.
#[error("The 'other' encoding cannot be used when publishing")]
OtherEncoding,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

nitpick(non-blocking): I wonder if there's a way to do this where you aren't exposing ::Other in the publishing context by splitting up this DataTrackSchemaEncoding into a publishing variant and a subscribing variant. I don't think there would be a way to do this where it wouldn't be a breaking change though, so maybe disregard if you see to many problems with this idea.

Comment on lines +205 to +206
use DataTrackFrameEncoding as FrameEncoding;
use DataTrackSchemaEncoding as SchemaEncoding;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

nitpick: Why alias these here rather than just the fully qualified names below? IMO, it adds some confusion because it's not 100% clear that FrameEncoding and DataTrackFrameEncoding / etc mean the same thing if you enter the file from further down.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants