Repository navigation
fix: report zero volume from useTrackVolume - #473
Merged
davidliu merged 1 commit intoOct 15, 2026
Merged
Conversation
RaphaelFakhri
requested review from
changt,
davidliu,
hiroshihorie and
xianshijing-lk
as code owners
October 10, 2026 19:58
🦋 Changeset detectedLatest commit: b3bc601 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
davidliu
approved these changes
Oct 15, 2026
Merged
davidliu
pushed a commit
that referenced
this pull request
Oct 17, 2026
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated. # Releases ## @livekit/react-native@3.1.0 ### Minor Changes - Update @livekit/react-native-webrtc to 150.1.0. - [#461](#461) ([@cloudwebrtc](https://github.com/cloudwebrtc)) iOS: the `LiveKitWebRTC` pod is published to the [livekit/podspecs](https://github.com/livekit/podspecs) spec repo and the CocoaPods trunk. The CocoaPods trunk stops accepting new pods on December 2, 2026, so later `LiveKitWebRTC` versions will only be available from livekit/podspecs. Add both sources to the top of your `ios/Podfile`: ```ruby source 'https://github.com/livekit/podspecs.git' source 'https://cdn.cocoapods.org/' ``` Keep the `cdn.cocoapods.org` line: once a `Podfile` lists any `source`, CocoaPods stops using trunk by default, and your other pods still come from there. Expo users don't need to edit the `Podfile` by hand: version 1.1.0 and later of the [Expo plugin](https://github.com/livekit/client-sdk-react-native-expo-plugin) adds these sources during prebuild. If `pod install` then reports that it could not find compatible versions for `LiveKitWebRTC`, run `cd ios && pod update LiveKitWebRTC`. ### Patch Changes - android: Fix build failure on Android Gradle Plugin 9+ for Expo 58+ - [#454](#454) ([@gabrieldonadel](https://github.com/gabrieldonadel)) - android: Fix useTrackVolume reading audio samples in the wrong byte order - [#466](#466) ([@darrenabridge](https://github.com/darrenabridge)) - Require `livekit-client` ^2.20.0. Earlier 2.19.x releases pre-allocate media sections in single peer connection mode, which React Native's libwebrtc doesn't support, causing remote tracks to never be subscribed or render black (livekit/client-sdk-js#1977, livekit/client-sdk-js#2113). - [#463](#463) ([@davidliu](https://github.com/davidliu)) - Fix `useTrackVolume` staying at the last non-zero value when the audio track goes silent - [#473](#473) ([@RaphaelFakhri](https://github.com/RaphaelFakhri)) - Fix `useRoom` disconnecting the room on every render when `sortParticipants` is passed as an inline function - [#472](#472) ([@cpruijsen](https://github.com/cpruijsen)) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
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.
Fixes
useTrackVolumeso it reports silence.The native volume processors emit
volume: 0when a track is silent or muted. The event handler checkedevent.volumefor truthiness, so a value of0was ignored and the hook kept returning the last non-zero volume. A level meter built on the hook stays stuck at its last level after the speaker stops.The handler now only skips events where
volumeisnullorundefined.Testing:
0fails before the change (Expected: 0,Received: 0.4) and passes after it. It needsreact-test-rendererand a jest environment change, so it is not included. It can be added on request.yarn lintandyarn typescriptpass.