razorpay / razorpay-pod

:iphone: CocoaPod implementation of Razorpay's Payment SDK. Refer for instructions:
https://docs.razorpay.com/v1/page/ios-integration
MIT License
21 stars 18 forks source link

RazorpayCheckoutWebView deinitialized Xcode 11 #82

Closed aksh1995 closed 4 years ago

aksh1995 commented 4 years ago

I have upgraded to all the latest version of Xcode and razorpay

I am not able to pay after using the new documentation razorpay.open(options, display: self) razorpay.open(options) with web view both give out the same error

ERROR LOG

<UINavigationController: 0x7fbb3f06e800> which is already presenting <UINavigationController: 0x7fbb3e968800> /Users/sachinnautiyal/Documents/Razorpay/razorpay-ios/RazorpayIOS/CheckoutOtpelf/Classes/RazorpayCheckoutVC.swift deinitialized /Users/sachinnautiyal/Documents/Razorpay/razorpay-ios/RazorpayIOS/CheckoutOtpelf/Classes/RazorpayCheckoutWebView.swift:["/Users/sachinnautiyal/Documents/Razorpay/razorpay-ios/RazorpayIOS/CheckoutOtpelf/Classes/RazorpayCheckoutWebView.swift deinitialized"]

how do I solve this I am not able to push and update as this is not working

IDE Specs

Retro Steps

Screenshots

Nautiyalsachin commented 4 years ago

Can you give me more details :-

  1. From where are you executing razorpay.open(options)? If it is from ViewDidLoad() then change it to ViewDidAppear(). else please give me more details about how you are trying to present it.
  2. Also include which pod version are you using?
aksh1995 commented 4 years ago

hey, I am using Razorpay Standard SDK 1.2.1 and I tried in both ViewDidAppear() and ViewDidLoad() I used web view to open and the view opens and closes and comes back to older vc where we ask for users upi id and I am following the same process which I was using fr older version of sdk the update version asked me to change from razorpay.authorize => razorpay.open and it was working fine in that

aksh1995 commented 4 years ago

["currency": "INR", "amount": 100, "order_id": "order_DTqYDarwWXEMzH", "email": "**1@gmail.com", "contact": "904*****", "vpa": "**", "method": "upi"]

this is the options attached in the razorpay.open function

Nautiyalsachin commented 4 years ago

Hi @aksh1995, Can you create a sample app and share the Github url here? I am still unable to figure out the issue.

aksh1995 commented 4 years ago

I tried using razorpay.open(options, display: self)

this was the error log------

/Users/sachinnautiyal/Documents/Razorpay/razorpay-ios/RazorpayIOS/CheckoutOtpelf/Classes/InternalRazorpay.swift:["payment failed"] /Users/sachinnautiyal/Documents/Razorpay/razorpay-ios/RazorpayIOS/CheckoutOtpelf/Classes/RazorpayCheckoutVC.swift deinitialized /Users/sachinnautiyal/Documents/Razorpay/razorpay-ios/RazorpayIOS/CheckoutOtpelf/Classes/RazorpayCheckoutWebView.swift:["/Users/sachinnautiyal/Documents/Razorpay/razorpay-ios/RazorpayIOS/CheckoutOtpelf/Classes/RazorpayCheckoutWebView.swift deinitialized"]

Nautiyalsachin commented 4 years ago

Hi, there are some things which I've noticed that doesn't look right: -

  1. Options are looked as you are using Custom SDK not the Standard SDK, please verify your options again.

  2. Remove WebKit from your code as its only applicable for Custom SDK (You are using pods and pods are available only for Standard SDK). refer the Razorpay iOS documentation (https://razorpay.com/docs/payment-gateway/ios-integration/) for more details.

  3. I am getting logs in success method that is giving output as "Payment Failed - Unexpected Error"

  4. Order_id is giving me error that it's not valid after debugging it more. Please try to remove it and try again. We are working on it and right now you can proceed it without the Order_id field.

  5. Try open method in didAppear. Then only it will show present the checkout controller.

Let me know if anything doesn't look right or you need more clarification.

aksh1995 commented 4 years ago

thanks for your help solved it!!

aksh1995 commented 4 years ago

hey I got the same error in the device iPhone XR running with iOS version 13.1.2

the order id was order_Df2ZDBm57oiF6P

what is causing this error????

the user is not able to make payment for past couple of weeks

On Mon, Oct 14, 2019 at 2:57 PM Sachin Nautiyal notifications@github.com wrote:

Hi, there are some things which I've noticed that doesn't look right: -

1.

Options are looked as you are using Custom SDK not the Standard SDK, please verify your options again. 2.

Remove WebKit from your code as its only applicable for Custom SDK (You are using pods and pods are available only for Standard SDK). refer the Razorpay iOS documentation ( https://razorpay.com/docs/payment-gateway/ios-integration/) for more details. 3.

I am getting logs in success method that is giving output as "Payment Failed - Unexpected Error" 4.

Order_id is giving me error that it's not valid after debugging it more. Please try to remove it and try again. We are working on it and right now you can proceed it without the Order_id field.

Let me know if anything doesn't look right or you need more clarification.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/razorpay/razorpay-pod/issues/82?email_source=notifications&email_token=ANLLLI4UHURLQJGDMD24GFLQOQ3QRA5CNFSM4JAKW4H2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEBD4U5I#issuecomment-541575797, or unsubscribe https://github.com/notifications/unsubscribe-auth/ANLLLI7CZ7HOOIYL5BQIO4LQOQ3QRANCNFSM4JAKW4HQ .