Subscription downgrade in sandbox produces SSServerErrorDomain/SKErrorDomain (code 0) error

Viewed 823

I got this when downgrading a subscription. The paymentQueue:updatedTransactions: function provides a transaction with error Error Domain=SSServerErrorDomain Code=0 "You are all set" UserInfo={NSLocalizedDescription=You are all set} and state as .failed.

Note the error domain is SSServerErrorDomain NOT the more common SKErrorDomain. There seems to be no documentation about SSServerErrorDomain either.

If I try to purchase the same downgraded plan again, I will get “You are already subscribed.”.

The receipt right after the downgrade does not contain the new plan, which is expected because a downgrade will take effect at next renewal date. After 1 hour, I check the receipt again and it contains the new downgraded plan. (Monthly subscription interval is 5 mins in sandbox, and renews for about 6 times.)

I don't think we can do anything here because it comes from StoreKit. May be it's an Apple sandbox bug.

Steps to Reproduce:

  • Set up 2 subscriptions with different levels (will call plan A and B) in a subscription group in iTunes Connect
  • Go to the app, purchase the plan with higher level (A), observe successful purchase
  • Then immediately purchase lower level plan (B)
  • Got the mentioned error.

Version: iOS 10.3.2 (14F89), iPhone 7 plus

Seems like some other people are seeing this also: https://github.com/bizz84/SwiftyStoreKit/issues/231

I filed a radar: http://www.openradar.me/radar?id=4998361958580224

Questions:

  • Has anyone experience this?
  • Could this be a sandbox only issue?
  • If it's also in production, how can I get around this?

Update: I tested again today and it's returning error domain SKErrorDomain code=0 now. Apple, please tell us how to test subscription downgrade!

1 Answers
Related