Post

Replies

Boosts

Views

Activity

How should I react to SKErrors with error code 0 on subscription starts?
Sometimes, in my iOS app subscription starts fail in production with an SKError with code 0. This code means that an "unknown or unexpected error" occurred, and in this case I display the localized description to the user. In most cases this is "Cannot connect to iTunes Store". What are the most common reasons for this? Can I provide better suggestions to the user than "Try again"? Is this usually a problem with their Apple ID, or a network failure? Futher, I noticed that in some cases there is an underlying error object with the error domain ASDServerErrorDomain. Is this error domain documented somewhere? I couldn't find any information about this. I have seen multiple cases where this underlying error had the code 3532, and the NSLocalizedDescription is: You’re currently subscribed to this. I find that surprising because (1) I would expect that StoreKit simply treats this as a successful "purchased" transaction (I think this case is mentioned on some WWDC talk) instead of throwing an error and (2) there is no documented way to detect this case and unlock the subscribed content for the user. What's the recommended way to react to this error? What should I display to the user? The localized description of the SKError itself is in this case An unknown error occurred which is not helpful at all.
1
0
2.9k
Oct ’20
What does the error mean: Unable to obtain assetsd XPC proxy
My iOS app allows users to edit and save videos. The edited videos are saved with a call to PHAssetChangeRequest.creationRequestForAssetFromVideo(atFileURL: within a PHPhotoLibrary's performChanges block.These calls frequently fail with the error code 41002 (Domain: com.apple.photos.error). Its localizedDescription is:Unable to obtain assetsd XPC proxy for getPhotoKitServiceWithReply:. assetsd could have crashedWhat does the error mean? I tried to search for the error code, the domain and the keywords from the description, but couldn't find anything. Is there an official reference for the errors in this domain? What error message should I show to the user?
3
0
3.3k
Nov ’19