I have been trying to implement auto renewable subscription (ARS) with trial period. I already had an app with ARS implemented and it was working fine. Now I wanted to add trial period as well in these subscriptions. So for testing purpose I created two new products with trial period of 1 month set in them.
Now in sandbox environment, when I try to purchase these two new products from a sandbox Id from which I already had taken the subscription, the process goes smoothly without any issue. But when I try to purchase them with a new sandbox account, app crashes after reaching updatedTransaction observer method. In this method, I have received the receipt of the product purchase and the whole transaction details. But the app crashes after this. Restore purchase for the same product works fine.
Below is the crash log and snapshot:
Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '* -[__NSDictionaryM removeObjectForKey:]: key cannot be nil' * First throw call stack: (0x186c081c0 0x18564055c 0x186b06534 0x100f052a4 0x19362ded8 0x1022e925c 0x1022e921c 0x1022ee284 0x186bb5f2c 0x186bb3b18 0x186ae2048 0x188565198 0x18cabc628 0x18cab7360 0x10065831c 0x185ac45b8) libc++abi.dylib: terminating with uncaught exception of type NSException


[AppStore productsRequest:]method in the call stack on the left and edit your question with its code, stating the line where it crashed. - pckill[ApStore productsRequest:didReceiveResponse:]? I was under impression the debugger will show the line where it crashed in that function, but it seems like it is from some library. - pckill