amzn / amazon-payments-magento-2-plugin

Extension to enable Amazon Pay on Magento 2
https://amzn.github.io/amazon-payments-magento-2-plugin/
Apache License 2.0
108 stars 75 forks source link

Pay With Amazon script errors on checkout page after install #73

Closed digitalredefned closed 7 years ago

digitalredefned commented 7 years ago

What I expected

Checkout Page should return all payment options including Pay With Amazon

What happened instead

Checkout page starts to load - shows all payment options but loading icon continues to spin and Amazon Pay option is not displayed. Cannot interact with page and there are errors in console regarding the Amazon Pay scripts not being found

image image

Upon further review, in the back end it shows that version 1.0.1 of the module is being used even though I installed 1.1.1 via composer.

image

Confirmed this in the composer.json files in vendor/amzn/amazon-payments-magento-2-plugin/ as well.

Steps to reproduce the issue

Install on Magento 2.1.7 Install V1.1.1 of amazon-payments-magento-2-plugin Configure account, enable Amazon pay in Magento admin Add product to cart Go to Checkout

Your setup

danielneu commented 7 years ago

HI,

I'm sorry for the issues you are experiencing.

I think you are touching three different topics here:

a) Module version. This seems to be an issue we should address, but will not lead to any negative impact. It is a mismatch of actual version and what is displayed. Thanks for the heads up, I created #74 for this.

b) Amazon Pay not displayed with payment options

This is by design. Amazon Pay is a checkout solution, thus we place buttons at locations wherea checkout can be started. In the checkout, we provide easy to use widgets which take way the need to enter any data manually during checkout. There will be no Amazon Pay option at the payment step, it starts earlier (basket, mini-basket, shipping step).

I guess you haven't seen a button due to c)

c) Static files missing.

Did you compile DI and deploy the static files like you should with any Magento installation in the production mode? The missing JS files might be a result of this being not done. http://devdocs.magento.com/guides/v2.1/config-guide/cli/config-cli-subcommands-static-view.html

I will double check the installation guidelines in our documentation today.

Hope this resolves your issue. If not, can you provide a staging site, where an agency can reproduce this and find the root cause for you?

Best wishes Daniel

digitalredefned commented 7 years ago

Hi Daniel

Thanks for the follow up!

I gotcha on the module version - I was wondering what was up with that!

As for the payment options, I would think this should be implemented. We want to go this route so that we don't clutter our product pages with extra actions. We utilize paypal so if we started including pay by paypal, amazon pay, etc it would get busy on those pages. We had great success with your extension working like this on our 1.9x site and what we were looking for.

As far as compilation, yup I performed a setup:upgrade and a setup:static-content:deploy after activating the extension. Scripts from other extensions are loading in their proper areas so I'm pretty sure that process is working. As far as documentation, you'll want to update the composer require command to reference 1.1.1 as it's referencing 1.1.0 but otherwise seems spot on. I can get our dev site back up and running either today or Monday. Is there a way to contact you directly? I'll send the credentials your way. I'll also need your IP to whitelist for SSH access.

Thanks again for the follow up! Jim

danielneu commented 7 years ago

Hi Jim,

I will raise a feature request for adding us to the payment options and discuss this internally. The main intention and best customer flow, is however the way it is implemented at this time.

For the version, it states "^1.1.0" which means, 1.1.x, this way you will always get the newest version which will be non-breaking according to semantic versioning.

I will hand the actual issue over to the agency doing the support for us. They will get in touch with you.

Can you send an email to payments-cp-devel@amazon.com mentioning this ticket with your contact details?

Thanks, Daniel

danielneu commented 7 years ago

@digitalredefned

I did not directly mention you in my request, my bad.

Could you review my last message and send the email I asked for?

Thanks Daniel

digitalredefned commented 7 years ago

@danielneu

Not a problem! I'll get that sent out this afternoon. I've got setting up the dev site on my list for tomorrow or Thursday.

Thanks, JIm

andidhouse commented 7 years ago

Hi @danielneu and @digitalredefned,

i think there are two things in magento2 which are different. If you checkout for virtual products only (like buying software etc.) the step where you type in your address is canceled by magento and yo jut need your email to checkout and of course the payment option.

In this case i think it makes indeed sense to implement amazon pay as a payment.

The second thing is i do think it makes also sense to have the amazon pay included in the payment options - at least for testing.

The thing is that the people learned to checkout this way and all buttons (on product pages, cart etc.) are at the moment often very missleading because the customer does not exactly know what is happening when pressing these.

I also understand the logic of @danielneu - because the benefit of amazon pay is that you do not need to type in your address data etc. because this is loaded from amazon.

For this is it would for example make sense to have the Payment option implemented as a first step - so if a customer choses amazon pay - the address data is loaded from amazon in the next step. If another payment method is chosen the next step is the address fields input.

But i know this is not the magento2 logic :-/.

danielneu commented 7 years ago

@andidhouse

If only virtual items are in the cart, we will also not surface our address widget.

I agree, this is a situation where we could also put ourselves into the list of other options in this case.

For anything else, you totally understand what I am up to and coming from. We have to use our address widget for physical goods, therefor the customer flow would be off:

The CX was the initial reason not to add Amazon Pay on the payment page.

Hope this makes sense.

Daniel

digitalredefned commented 7 years ago

FWIW, I ended up turning off the pay with paypal option from the product pages on all of the magento sites that I currently support mainly because of user feedback as it was confusing and they were used to going to a checkout page. The Amazon pay experience in the 1.9.x implementation worked well for us.

danielneu commented 7 years ago

@digitalredefned Did you send the message I asked for with contact details? Our agency is asking for it.

Best wishes Daniel

danielneu commented 7 years ago

closing this due to lack of feedback.

Please reopen once you can share contact details with our agency:

Can you send an email to payments-cp-devel@amazon.com mentioning this ticket with your contact details?

Best wishes Daniel

hamdansalik commented 6 years ago

Hello @danielneu

I am using amazon pay with magento 2.1.1 and trying to install through composer got the same error as mentioned in the above can you help me to fix this issue on my instance?

Please help if you can we need to go live soon we fix this issue

Thanks Salik

lemked commented 6 years ago

Hi Salik,

Do you encounter exactly the same error as in the issue description? Can you please provide the version of the Amazon Pay plugin for Magento 2 that you are using?

Kind regards, Daniel

hamdansalik commented 6 years ago

Hi Daniel,

This is the latest version what i tried to install /usr/local/php70/bin/php-cli composer.phar require amzn/amazon-payments-magento-2-plugin:^1.2.6

Please suggest

Thanks Salik

lemked commented 6 years ago

And you have exactly the same behavior and error message as described in this issue? If so, please send us the log files to payments-cp-devel@amazon.com along with screenshots of the website that illustrate the error.