AdaptySDK-iOS icon indicating copy to clipboard operation
AdaptySDK-iOS copied to clipboard

setFallbackPaywalls returns error

Open MatusevichMaxim opened this issue 3 years ago • 2 comments

Hi Adapty Team! I'm trying to use fallback feature with offline. I loaded fallback-json from dashboard and then added it into a project. Afterwards i try set fallback from file: private func fetchFallback() { let file = R.file.fallback_paywallsJson if let path = Bundle.main.path(forResource: file.name, ofType: file.pathExtension), let paywall = try? String(contentsOfFile: path, encoding: .utf8) { Adapty.setFallbackPaywalls(paywall, completion: { error in if let error = error { Log.error(error) } }) } }

In completion block i get an error "An unknown error occurred".

MatusevichMaxim avatar Jun 27 '22 19:06 MatusevichMaxim

Hi, @MatusevichMaxim! Are you still facing this issue? If yes, could you please provide us some more information about the error, is there an originalError property filled? What is adaptyErrorCode value?

x401om avatar Jul 18 '22 15:07 x401om

Yes, it's still happening. Look at the error: Screenshot 2022-07-25 at 22 56 21

MatusevichMaxim avatar Jul 25 '22 18:07 MatusevichMaxim

The problem was that even though fallback_paywalls were handled correctly, the callback could get an error from StoreKit. It didn't affect the operation of the method. We recently released a public beta where we fixed this problem, now you won't get this kind of error. All fixes will be available in the stable release soon.

x401om avatar Sep 30 '22 10:09 x401om