AVFoundationErrorDomain Code=-11853

Hi

The AVPlayer notify AVPlayerItemFailedToPlayToEndTimeNotification when playing the stream . i use the below code and print the error details :

NSError *error = notification.userInfo[AVPlayerItemFailedToPlayToEndTimeErrorKey];

NSLog(@"itemFailedToPlayMPMovieFinishReasonPlaybackError=%@" ,error);


Error details:

Error Domain=AVFoundationErrorDomain Code=-11853 "Stream has no valid alternates" UserInfo={NSLocalizedFailureReason=This data is damaged, incomplete, or incompatible., NSLocalizedDescription=Cannot Parse, NSDebugDescription=Stream has no valid alternates, NSUnderlyingError=0x155aa070 {Error Domain=CoreMediaErrorDomain Code=-12880 "Can not proceed after removing variant" UserInfo={NSDescription=Can not proceed after removing variant}}}


And the Error just only happen on the IOS10 . And i did not find Code=-11853 in https://developer.apple.com/library/ios/documentation/AVFoundation/Reference/AVFoundation_ErrorConstants/index.html#//ap…

my question:

1>What is the cause of this error?

2>how to fix it ?


Thanks

Replies

Hi jerryZhu


Did you find the solution for your problem? I am also getting same error.

Hi,


I'm still having this error. In my case it occurs when using PlayReady media player wich obviously is built on top of AVFoundation. It only happens when the app is made with XCODE 7.3.1 and runs under iOS 10.x

It is not possible for me to use XCODE 8 for this release because it's an older version of the app that should support iOS < 8


I can force this error to occur when moving away from the WIFI access point so it may possible occur when "squeezing" the connection.


Did you find a solution? Thanks

Hi,

I am seeing a similar error, but what I have noticed is that it occures when closed captioning is enabled.

Hi!


I see that this error was reported on July, I'm dealing with this right now, debugging into it, I can see that is more like a timeout connection error and the the app can recover, do we know why and what can we do about it?

Hi,


We got the same error today, but we figure it out why, maybe this can help you figuring out yours:


We have HLS stream and the manifest that was made was also containing a subtitle track/manifest.


one of those assets inside that subtitle track caused a 204 No Content error,...


This was the root case as described in this thread, "Can not proceed after removing variants" in our AppleTV app using AVFoundation player.


Also I was able to simulate this problem in Safari, by enabling the Captions as soon I did that it stopped playing the stream.


Make sure to validate your streams with Apples Validator tools you can download at:


https://developer.apple.com/streaming/



best


Marc