woocommerce / google-listings-and-ads

Sync your store with Google to list products for free, run paid ads, and track performance straight from your store dashboard.
https://woo.com/products/google-listings-and-ads/
GNU General Public License v3.0
45 stars 21 forks source link

Policy compliance check failing due to store address #1782

Closed sukafia closed 1 year ago

sukafia commented 1 year ago

Describe the bug:

On the setup flow, the Confirm your store is live and accessible to all users policy compliance check is using the store's address for validation.

This means that you may meet all the policy checklists but not entering your full store address will result in your inability to complete the setup. (The "Continue" button isn't clickable)

Steps to reproduce:

  1. Ensure your store meets all the policy checklist
  2. Go to WooCommerce > Settings > Store Address (section) > leave your address line empty and enter city, state, and postcode.
  3. Attempt the extension setup and notice the "Continue" button isn't clickable
  4. Refresh the page and you'll notice "Confirm your store is live and accessible to all user" is automatically unchecked (Other checklists that passed the check will remain checked)

Expected behavior:

"Confirm your store is live and accessible to all user" should check that the website is live and accessible to all. e.g, the website isn’t on maintenance mode and can be accessed by visitors.

Actual behavior:

It's checking that the store address is fully entered.

Additional details

Missing store address

O9vKeV.png

Issue on the checkout

xGb8KV.png

mikkamp commented 1 year ago

That's interesting, because that check doesn't actually use the address field.

It calls the WC get_allowed_countries to get a list of countries the site sells to, and then checks if all the target countries we selected in the previous onboarding step are on that list.

It seems if the option woocommerce_allowed_countries is not set (probably the case on initial install of a WC site), it defaults to only a specific list of included countries. I think we would need to confirm if that option is saved on initial install, and whether updating the store address forced it to be saved with the default value of all, because that would change the outcome of the check.

We'd need to do some more testing to validate what's happening here, and whether it's an inconsistency to report in WooCommerce or if there is a way to work around it.

sukafia commented 1 year ago

Affected users:

5677396-zd-woothemes 5713900-zd-woothemes https://wordpress.org/support/topic/unable-to-connect-25/

mikkamp commented 1 year ago

Thanks for the references to existing tickets, I took some time to look through those and confirmed that none of them is a case of the Policy Compliance checks blocking the onboarding. There are three main reasons why it is not the Policy Compliance checks:

  1. The policy compliance checks do not check the store address, so setting the store address does not allow any of the policy compliance checks to pass (where it was failing previously with the store address unset).
  2. The policy compliance checks are there as an assistance to automatically check, since they are not able to confirm all scenarios the user is able to manually verify and check the box that a compliance check passed. So if all policy compliance checks are confirmed they can continue.
  3. In the onboarding step "Confirm store requirements" there are three sections which need to be filled out before the continue button becomes enabled. Phone Number, Store Address, Confirm policy compliance checks. So the store address not being filled out completely is related to the second section.

Following are some screenshots which confirm that it's directly related to the Store Address section (in the tickets I also found screenshots of incomplete addresses).

  1. Store address is not filled out completely (street address is missing), some policy compliance checks fail which can be confirmed manually:

image

  1. Store address is not filled out completely (street address is missing), policy compliance checks have been confirmed manually, but continue button is still disabled:

image

  1. Store address is filled out completely, some policy compliance checks fail which can be confirmed manually. Until they are confirmed the continue button remains disabled:

image

  1. Store address is filled out completely, policy compliance checks have been confirmed manually. Now the continue button becomes enabled since all checks on the page are completed (not shown in screenshots but phone number must also be verified):

image

Based on the analysis above, I'm going to close this issue since it is not related to the policy compliance checks. I've added this specific scenario to issue https://github.com/woocommerce/google-listings-and-ads/issues/634 so we can track the need for improving error validation messages in one issue.