Skip to content

Fresh builds of livekit 0.7.49 from crates.io are broken: June 30 release partially published (webrtc-sys 0.3.36 without libwebrtc 0.3.39) due to a known cargo bug #1216

Description

@Choudhry18

Summary

Since 2026-06-30, any fresh cargo build that resolves the LiveKit Rust SDK from
crates.io fails inside libwebrtc. The June 30 release workflow published
webrtc-sys 0.3.36 (which changed the FrameMetadata FFI, adding user_data)
but crashed before publishing the matching libwebrtc 0.3.39 and livekit 0.7.50.
Both published libwebrtc versions (0.3.37, 0.3.38) declare webrtc-sys = "^0.3.35",
so cargo resolves them against 0.3.36 and compilation fails:

error[E0063]: missing field `user_data` in initializer of `webrtc_sys::video_track::ffi::FrameMetadata`
  --> libwebrtc-0.3.38/src/native/video_source.rs:88

error[E0061]: this method takes 4 arguments but 3 arguments were supplied
  --> libwebrtc-0.3.38/src/native/packet_trailer.rs:192 (store_frame_metadata)

This doesn't show up in your CI because the workspace builds with path
dependencies — it only affects downstream consumers resolving from crates.io.

Root cause

The publish-crates job of the June 30 "Release packages" run failed mid-publish
with a cargo 1.96.0 internal error:

https://github.com/livekit/rust-sdks/actions/runs/28420077950/job/84211146107

   Uploaded livekit-protocol v0.7.10 to registry `crates-io`
   Uploaded webrtc-sys v0.3.36 to registry `crates-io`
error: no packages ready to publish but 2 packages remain in plan with 1 awaiting
       confirmation: libwebrtc v0.3.39 and livekit v0.7.50
note: this is an unexpected cargo internal error
note: cargo 1.96.0 (30a34c682 2026-05-25)

This is a known cargo bug in workspace publishing
(rust-lang/cargo#17093, also #17028/#17100/#17144), fixed in
rust-lang/cargo#17071. The fix is in nightly since 2026-06-12, was beta-backported
(rust-lang/rust#157787), and reaches stable on July 9.

Suggested fix

Re-run the publish for the two missing crates (libwebrtc 0.3.39,
livekit 0.7.50) using a beta or nightly toolchain — the cargo maintainer's
recommended interim approach in rust-lang/cargo#17093 — or wait for the July 9
stable. You may also want to pin the release workflow's toolchain accordingly
until then.

As an opinion from the downstream side (feel free to disagree — the republish
above fully resolves this): declaring the libwebrtcwebrtc-sys dependency
with an exact requirement (=x.y.z) would have made this incident a non-event,
since a newer webrtc-sys on the registry could never retroactively break
already-published libwebrtc versions. The tradeoff is that compatible
webrtc-sys patches would then require a libwebrtc republish to reach users.

Workaround for anyone hitting this

livekit = { version = "0.7", features = ["tokio", "rustls-tls-native-roots"] }
webrtc-sys = "=0.3.35"   # pin until libwebrtc 0.3.39 is published

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions