woocommerce / woocommerce-gateway-stripe

The official Stripe Payment Gateway for WooCommerce
https://wordpress.org/plugins/woocommerce-gateway-stripe/
236 stars 206 forks source link

Shipping must be selected for virtual variations when using payment request buttons on product pages #1619

Open apmwebdev opened 3 years ago

apmwebdev commented 3 years ago

Describe the bug Shipping is required for virtual products under some specific conditions, which means that sites that only sell virtual products cannot have payment request buttons enabled at all.

The conditions are:

  1. It only happens with payment request buttons (possibly only Google Pay).
  2. It only happens when you click the payment request button on the product page. This doesn't seem to be an issue if you initiate the payment request process on the cart or checkout pages.
  3. It only happens with variable products. If you choose a variation that is virtual, shipping is still included. Simple products seem unaffected.

This means that sites that only sell virtual products (and therefore don't have any shipping methods set up) cannot offer payment request buttons at all, as customers that try to use payment request buttons on the product pages for variable products won't be able to check out since they can't select a shipping method.

To Reproduce

  1. Create a variable product and make the variations virtual.
  2. Go to the product page and select one of the variations.
  3. Click the "Buy with Google Pay" button.
  4. Note that the purchase cannot be completed because there are no shipping methods.
  5. Create a shipping method
  6. Repeat steps 1-4 and note that the shipping method is selected.

I'm unclear if shipping is actually charged or not. I got inconsistent behavior with this.

Expected behavior Shipping should not be required for virtual products under any circumstances.

Environment (please complete the following information):

Akismet Anti-Spam: by Automattic – 4.1.9
AutomateWoo - Refer A Friend Add-on: by WooCommerce – 2.6.1
AutomateWoo: by WooCommerce – 5.4.2
Jetpack: by Automattic – 9.8.1
WooCommerce AvaTax: by SkyVerge – 1.12.0
WooCommerce Bookings Availability: by WooCommerce – 1.1.19
WooCommerce Amazon Pay: by WooCommerce – 2.0.2 (update to version 2.0.3 is available)
WooCommerce PayPal Checkout Gateway: by WooCommerce – 2.1.2
WooCommerce Stripe Gateway: by WooCommerce – 5.2.3
WooCommerce Memberships: by SkyVerge – 1.22.2
WooCommerce Payments Dev Tools: by Automattic –
WooCommerce Payments: by Automattic – 2.5.0 (update to version 2.6.1 is available)
WooCommerce PayPal Payments: by WooCommerce – 1.3.1 (update to version 1.3.2 is available)
WooCommerce Pre-Orders: by WooCommerce – 1.5.29 (update to version 1.5.30 is available)
WooCommerce Quick View: by WooCommerce – 1.2.12 (update to version 1.4.0 is available)
WooCommerce Shipping & Tax: by WooCommerce – 1.25.15
WooCommerce Royal Mail: by WooCommerce – 2.5.33 (update to version 2.5.35 is available)
WooCommerce USPS Shipping: by WooCommerce – 4.4.55
WooCommerce - ShipStation Integration: by WooCommerce – 4.1.42
WooCommerce Slack: by WooCommerce – 1.2.8
WooCommerce Square: by WooCommerce – 2.5.1
WooCommerce Subscriptions: by WooCommerce – 3.1.3
WooCommerce: by Automattic – 5.4.1

### Inactive Plugins (2) ###

WooCommerce Admin: by WooCommerce – 2.3.1
WooCommerce Bookings: by WooCommerce – 1.15.30 (update to version 1.15.41 is available)

### Dropin Plugins (2) ###

advanced-cache.php: advanced-cache.php
object-cache.php: Memcached

Additional context Ticket: 30295360-hc

shameemreza commented 2 months ago

Another similar report here: 8758982-zen Thread: https://wordpress.org/support/topic/new-checkout-experience-asks-for-postal-code/