react-native-track-player icon indicating copy to clipboard operation
react-native-track-player copied to clipboard

[AVPlayerItem addOutput:] Cannot attach an output that is already attached or nil output

Open AjayGol opened this issue 1 year ago • 2 comments

Describe the Bug *** [AVPlayeritem addOutput:] Cannot attach an output that is already attached or nil output.

Steps To Reproduce TBH it did not happen to me on debug, but it seems that is happening to my users in production. I have reports from Firebase Crashlytics.

Screenshot 2023-12-29 at 12 25 40 PM

Screenshot 2023-12-29 at 12 25 50 PM

OS: macOS 13.5.2 CPU: (8) arm64 Apple M1 react-native: ^0.68.0 => ^0.68.0 xCode: 15(15A240d)/usr/bin/xcodebuild

Using react-native-track-player@^4.0.1

This is happen on real devices, most of them iOS 16 and up.

AjayGol avatar Dec 29 '23 07:12 AjayGol

My users are getting this in production off v4.0.1 as well (with an example today on iOS 17.4 using iPhone 15 Pro). @jspizziri : in #1818, you mentioned that the particular issue would be better handled/supported if people got off the RC's... I think it's now been seen by many folks on 4.0.1, so it feels like a legitimate/continued issue.

I'm happy to help make a PR here, but I'm not positive what the actual fix should be. For instance, should we try to detect an already-attached or nil output, and simply not try to startObserving it? Or alternatively, does hitting this code path indicate a deeper problem that we need to fix upstream of this moment?

fivecar avatar Mar 18 '24 04:03 fivecar

This issue is also affecting my app, I hope it gets fixed soon

9mzodiac avatar Apr 13 '24 18:04 9mzodiac

This issue is stale because it has been open 90 days with no activity. Remove stale label or comment or this will be closed in 7 days.

github-actions[bot] avatar Jul 14 '24 01:07 github-actions[bot]

This issue was closed because it has been stalled for 7 days with no activity.

github-actions[bot] avatar Jul 22 '24 01:07 github-actions[bot]