Post

Replies

Boosts

Views

Activity

Cannot use AVAudioPlayer in simulator in Xcode 12 beta 3
This might relate to a similar problem I had with the first beta, where trying to use an AVAudioPlayer caused the app to hang and spit out a lot of errors and not really work. This was resolved in beta 2 but beta 3 has reverted back to the old behaviour where trying to call prepareToPlay() or play() on a valid AVAudioPlayer instance causes lots of error output (and no sound). Additionally, trying to call prepareToPlay() during an onAppear{ } block for the root view of a SwiftUI app appears to block the main thread while all of this error output is being spat out and causes a significant delay in app launch. I've been able to reproduce this bug in a very simple example app. I have filed a feedback: FB8116155 This is an example of the sort of errors I'm getting: https://gist.github.com/lukeredpath/e9485d0d83e6b5f7acea2eedb98e144c Is anyone else able to reproduce this or having similar problems?
4
0
4.1k
Feb ’22
Cannot use AVAudioPlayer in simulator in Xcode 12 beta 3
This might relate to a similar problem I had with the first beta, where trying to use an AVAudioPlayer caused the app to hang and spit out a lot of errors and not really work. This was resolved in beta 2 but beta 3 has reverted back to the old behaviour where trying to call prepareToPlay() or play() on a valid AVAudioPlayer instance causes lots of error output (and no sound). Additionally, trying to call prepareToPlay() during an onAppear{ } block for the root view of a SwiftUI app appears to block the main thread while all of this error output is being spat out and causes a significant delay in app launch. I've been able to reproduce this bug in a very simple example app. I have filed a feedback: FB8116155 This is an example of the sort of errors I'm getting: https://gist.github.com/lukeredpath/e9485d0d83e6b5f7acea2eedb98e144c Is anyone else able to reproduce this or having similar problems?
Replies
4
Boosts
0
Views
4.1k
Activity
Feb ’22