Honor discardFrameWhenCryptorNotReady in BaseKeyProvider.create - #1171
Merged
Conversation
hiroshihorie
marked this pull request as ready for review
August 11, 2026 09:52
hiroshihorie
requested review from
cloudwebrtc and
xianshijing-lk
as code owners
August 11, 2026 09:52
cloudwebrtc
approved these changes
Aug 11, 2026
rokk4
added a commit
to rokk4/client-sdk-flutter
that referenced
this pull request
Aug 18, 2026
Fourteen upstream commits across the 2.11.0 release. Conflicts, both resolved deliberately: - lib/src/core/room.dart — our hardened pending-track flush (serialised via _pendingTrackFlushChain, transient vs permanent subscription failures, refreshAll on disconnect-skip, retry scheduling) against upstream's single-expression version. Kept ours: it is the reason this fork exists, and upstream added nothing to that path this cycle beyond reformatting, so nothing is lost by keeping it. - pubspec.lock — took upstream's and regenerated with pub get. All four carried patches verified intact after the merge. Three of them auto-merged, including VP9 whole-frame encryption in web/e2ee.frame_cryptor.dart, which is the one that must never be dropped: it keeps the web worker aligned with the native FrameCryptor, and removing it breaks web <-> mobile video silently. E2EE setup is still gated on isAV1Codec rather than isSVCCodec. The podspec carries upstream's bump to 2.11.0 alongside our platform 16.0. Behaviour change worth knowing about, from livekit#1171: BaseKeyProvider.create previously hardcoded defaultDiscardFrameWhenCryptorNotReady (false) and ignored the caller's argument. It now honours it. The app passes true in both video_repo_impl and guest_video_repo_impl, so a setting we have been requesting all along finally takes effect. The registered flow calls setSharedKey before connect and is largely unaffected; the guest flow, where the room key arrives late over the data channel, will now drop frames until it does instead of passing undecryptable ones through. Cleaner, but it changes the failure signature in the area TLE-347 covers, and with failureTolerance: -1 a key that never arrives means silent black video. Upstream reformatted the vendored web E2EE sources heavily (line wrapping and trailing commas, no semantic change once whitespace and line breaks are discounted). Re-vendored into therapy-lift/web/ and recompiled the worker anyway, so the copies stay in step. Verified: flutter analyze clean, all 80 tests in test/core pass.
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.
BaseKeyProvider.create accepted a discardFrameWhenCryptorNotReady parameter but never read it, every call got the built-in default. Now follows the same param-or-default pattern as the sibling options.
Pre-existing bug surfaced by Devin on the #1170 reformat diff, fixed separately to keep that PR mechanical.