Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Jetpack Setup] Show error screen directly when Woo is not installed #14837

Open
wants to merge 2 commits into
base: trunk
Choose a base branch
from

Conversation

hichamboushaba
Copy link
Member

@hichamboushaba hichamboushaba commented Jan 9, 2025

Closes: #14806

Description

This PR adds an improvement to the flow post Jetpack setup: when we detect that the site doesn't have Woo, we will show the error screen right away, instead of navigating to the store picker and hoping that the user will figure out the next step themselves. This change also fixes the crash of the linked ticket.

Note

I didn't add any unit tests for this part, adding the tests will require more work than the fix itself as the Coordinator doesn't have any tests yet, but let me know if it's a blocker.

Steps to reproduce

Important

Calypso's plugin installation seems to be broken, it will take you to the login page after finishing the installatio, I plan on investigating this further. For this PR, to be able to test the full flow, apply the following
patch, then when the installation is done just dismiss the WebView.

  1. Prepare a self hosted site without Jetpack and WooCommerce
  2. Sign in using WordPress.com
  3. Open the site picker.
  4. Tap on "Connect an existing store"
  5. Complete the Jetpack connection flow.
  6. Tap on "Go to store"

Testing information

  • Before this PR, tapping twice on the button could lead to the crash as shown below.
  • Regardless of the crash, the experience was not good, as we show the site picker and the added site will be at the bottom of the list unselected.
  • With this PR, we will show the error screen right away.

Screenshots

Before (crash)

Simulator.Screen.Recording.-.iPhone.16.Pro.-.2025-01-09.at.13.17.35.mp4

Before (without crash)

Simulator.Screen.Recording.-.iPhone.16.Pro.-.2025-01-09.at.14.52.27.mp4

After

Simulator.Screen.Recording.-.iPhone.16.Pro.-.2025-01-09.at.14.42.14.mp4

  • I have considered if this change warrants user-facing release notes and have added them to RELEASE-NOTES.txt if necessary.

Reviewer (or Author, in the case of optional code reviews):

Please make sure these conditions are met before approving the PR, or request changes if the PR needs improvement:

  • The PR is small and has a clear, single focus, or a valid explanation is provided in the description. If needed, please request to split it into smaller PRs.
  • Ensure Adequate Unit Test Coverage: The changes are reasonably covered by unit tests or an explanation is provided in the PR description.
  • Manual Testing: The author listed all the tests they ran, including smoke tests when needed (e.g., for refactorings). The reviewer confirmed that the PR works as expected on all devices (phone/tablet) and no regressions are added.

@hichamboushaba hichamboushaba added type: bug A confirmed bug. feature: login Related to any part of the log in or sign in flow, or authentication. labels Jan 9, 2025
@hichamboushaba hichamboushaba changed the title Show error screen directly when Woo is not installed [Jetpack Setup] Show error screen directly when Woo is not installed Jan 9, 2025
@hichamboushaba hichamboushaba marked this pull request as ready for review January 9, 2025 14:06
@wpmobilebot
Copy link
Collaborator

wpmobilebot commented Jan 9, 2025

WooCommerce iOS📲 You can test the changes from this Pull Request in WooCommerce iOS by scanning the QR code below to install the corresponding build.

App NameWooCommerce iOS WooCommerce iOS
Build Numberpr14837-eda92f1
Version21.3
Bundle IDcom.automattic.alpha.woocommerce
Commiteda92f1
App Center BuildWooCommerce - Prototype Builds #12449
Automatticians: You can use our internal self-serve MC tool to give yourself access to App Center if needed.

@hichamboushaba hichamboushaba added this to the 21.4 milestone Jan 9, 2025
@wpmobilebot wpmobilebot modified the milestones: 21.4, 21.5 Jan 10, 2025
@wpmobilebot
Copy link
Collaborator

Version 21.4 has now entered code-freeze, so the milestone of this PR has been updated to 21.5.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature: login Related to any part of the log in or sign in flow, or authentication. type: bug A confirmed bug.
Projects
None yet
2 participants