New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
expo-av not handling chunked audio & crashing expo-go #28370
Comments
Here's the crash log from when the simulator/expo-go crashes: |
I'd like to reiterate that it seems to work fine in an Android simulator; the issue seems isolated to iOS. |
Will try to replicate this in the expo 51 SDK beta later today to confirm if it's still an issue |
Confirmed still an issue in SDK 51, using the recommended version of expo go for SDK 51 as prompted: import { Text, TouchableOpacity, View } from "react-native";
import {Audio} from "expo-av";
export default function Index() {
async function test() {
await Audio.Sound.createAsync(
{ uri: "https://synthesis.abair.ie/piper/synthesise?voice=snc22_no0.piper&input=t%C3%A1&outputType=AUDIO&audioEncoding=MP3&cutSilence=true&speed=1&ps=0.0&pa=1" },
{ shouldPlay: true });
}
return (
<View
style={{
flex: 1,
justifyContent: "center",
alignItems: "center",
}}
>
<TouchableOpacity onPress={() => test()}>
<Text>Edit app/index.tsx to edit this screen.</Text>
</TouchableOpacity>
</View>
);
} Touching the text crashes the app. This issue only appears to be an issue in the simulator, when testing via Expo-GO on a real device it does not crash. |
Minimal reproducible example
https://gist.github.com/ParadauxIO/5b3341560a1117223ece8f96fc1ab155
What platform(s) does this occur on?
iOS (Works fine on Android)
Did you reproduce this issue in a development build?
Yes
Summary
Hi there, I'm developing an accessibility tool in React native that uses synthetic speech, available via a RESTful API. I'm sort of cheating by using an API that doesn't serve static files and passing the link to Expo-AV as if it did. Although this was working until recent versions of Expo-AV, now it appears to crash my simulator without any ability to see why.
In published versions of my app, it seems to continue to work, but even when I revert to an earlier commit where it's confirmed to be working on real devices, it continues to crash my simulator. I think this might have to do with expo-go rather than expo-av directly.
I've included an example using some sample expo-av code, which you can throw into any component; the version serving the static file will successfully play the audio for the Irish word "tá" whereas the synthesis API will fail (although If you go to the link in your browser, it will work just fine) It also works just fine on Android directly from the API.
These are the headers received when getting the statically served audio (same physical server)
These are the headers received when getting audio from the synthesis API
As you can see, there is a header difference, so I'm thinking it might also have to do with that.
Low latency is super important for my application, so I'd like to avoid downloading the audio before playing it as I have been. Any help would be appreciated!
Environment
expo-env-info 1.2.0 environment info:
System:
OS: macOS 14.4.1
Shell: 5.9 - /bin/zsh
Binaries:
Node: 18.12.1 - /usr/local/bin/node
Yarn: 1.22.19 - /usr/local/bin/yarn
npm: 9.7.1 - /usr/local/bin/npm
Managers:
CocoaPods: 1.15.2 - /usr/local/bin/pod
SDKs:
iOS SDK:
Platforms: DriverKit 23.0, iOS 17.0, macOS 14.0, tvOS 17.0, watchOS 10.0
IDEs:
Android Studio: Giraffe 2022.3.1 Patch 2 Giraffe 2022.3.1 Patch 2
Xcode: 15.0/15A240d - /usr/bin/xcodebuild
npmPackages:
@expo/webpack-config: ~19.0.1 => 19.0.1
expo: ~50.0.17 => 50.0.17
react: 18.2.0 => 18.2.0
react-dom: 18.2.0 => 18.2.0
react-native: 0.73.6 => 0.73.6
react-native-web: ~0.19.6 => 0.19.10
npmGlobalPackages:
eas-cli: 7.4.0
expo-cli: 6.3.10
Expo Workflow: managed
Expo Doctor Diagnostics
✔ Check Expo config for common issues
✔ Check package.json for common issues
✔ Check native tooling versions
✔ Check dependencies for packages that should not be installed directly
✔ Check for common project setup issues
✔ Check npm/ yarn versions
✔ Check for issues with metro config
✔ Check Expo config (app.json/ app.config.js) schema
✔ Check that packages match versions required by installed Expo SDK
✔ Check that native modules do not use incompatible support packages
✔ Check for legacy global CLI installed locally
✔ Check that native modules use compatible support package versions for installed Expo SDK
Didn't find any issues with the project!
The text was updated successfully, but these errors were encountered: