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

[Woo POS payments onboarding] Analytics events #12922

Merged

Conversation

kidinov
Copy link
Contributor

@kidinov kidinov commented Nov 14, 2024

Closes: #12903

Description

The PR adds:

  • woocommerceandroid_hub_menu_option_tapped, Properties: {"option":"pointOfSale"
  • woocommerceandroid_pos_payments_onboarding_shown, Properties: {"onboarding_state":"account_overdue_requirements"
  • woocommerceandroid_pos_payments_onboarding_dismissed, Properties: {"onboarding_state":"account_overdue_requirements"
    Tracking events

Steps to reproduce

  • Use a store with unfinished IPP onboarding
  • More -> POS
  • Connect to a reader
  • Close the onboarding flow

Notice the events:

🔵 Tracked: woocommerceandroid_pos_payments_onboarding_shown, Properties: {"onboarding_state":"account_overdue_requirements","plugin_slug":"woocommerce-payments","country":"US","blog_id":198219640,"is_wpcom_store":true,"was_ecommerce_trial":false,"plan_product_slug":"business-bundle","store_id":"f7681b0f-a272-4402-9520-0b1471736552","is_debug":true,"site_url":"https:\/\/anotherpaymentssite.wpcomstaging.com","cached_woo_core_version":"9.4.1"}
🔵 Tracked: woocommerceandroid_hub_menu_option_tapped, Properties: {"option":"pointOfSale","blog_id":198219640,"is_wpcom_store":true,"was_ecommerce_trial":false,"plan_product_slug":"business-bundle","store_id":"f7681b0f-a272-4402-9520-0b1471736552","is_debug":true,"site_url":"https:\/\/anotherpaymentssite.wpcomstaging.com","cached_woo_core_version":"9.4.1"}
🔵 Tracked: woocommerceandroid_blaze_entry_point_displayed, Properties: {"source":"menu","blog_id":198219640,"is_wpcom_store":true,"was_ecommerce_trial":false,"plan_product_slug":"business-bundle","store_id":"f7681b0f-a272-4402-9520-0b1471736552","is_debug":true,"site_url":"https:\/\/anotherpaymentssite.wpcomstaging.com","cached_woo_core_version":"9.4.1"}

Testing information

Follow steps to reproduce

The tests that have been performed

From steps to reproduce

Images/gif

No UI changes in the PR expected

  • I have considered if this change warrants release notes and have added them to RELEASE-NOTES.txt if necessary. Use the "[Internal]" label for non-user-facing changes.

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 big (tablet) and small (phone) in case of UI changes, and no regressions are added.

@kidinov kidinov added the feature: point of sale POS project label Nov 14, 2024
@kidinov kidinov added this to the 21.2 milestone Nov 14, 2024
@dangermattic
Copy link
Collaborator

dangermattic commented Nov 14, 2024

1 Message
📖

This PR contains changes to Tracks-related logic. Please ensure (author and reviewer) the following are completed:

  • The tracks events must be validated in the Tracks system.
  • Verify the internal Tracks spreadsheet has also been updated.
  • Please consider registering any new events.
  • The PR must be assigned the category: tracks label.

Generated by 🚫 Danger

@wpmobilebot
Copy link
Collaborator

wpmobilebot commented Nov 14, 2024

📲 You can test the changes from this Pull Request in WooCommerce-Wear Android by scanning the QR code below to install the corresponding build.
App Name WooCommerce-Wear Android
Platform⌚️ Wear OS
FlavorJalapeno
Build TypeDebug
Commit5007efb
Direct Downloadwoocommerce-wear-prototype-build-pr12922-5007efb.apk

@wpmobilebot
Copy link
Collaborator

wpmobilebot commented Nov 14, 2024

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

App Name WooCommerce Android
Platform📱 Mobile
FlavorJalapeno
Build TypeDebug
Commit5007efb
Direct Downloadwoocommerce-prototype-build-pr12922-5007efb.apk

@kidinov kidinov requested a review from AnirudhBhat November 14, 2024 12:22
@kidinov kidinov added the category: tracks Related to analytics, including Tracks Events. label Nov 14, 2024
@codecov-commenter
Copy link

codecov-commenter commented Nov 14, 2024

Codecov Report

Attention: Patch coverage is 85.18519% with 4 lines in your changes missing coverage. Please review.

Project coverage is 39.64%. Comparing base (3e60a27) to head (5007efb).
Report is 44 commits behind head on trunk.

Files with missing lines Patch % Lines
...reader/onboarding/CardReaderOnboardingViewModel.kt 60.00% 2 Missing and 2 partials ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##              trunk   #12922      +/-   ##
============================================
+ Coverage     39.61%   39.64%   +0.02%     
- Complexity     5925     5935      +10     
============================================
  Files          1261     1261              
  Lines         72843    72867      +24     
  Branches       9963     9967       +4     
============================================
+ Hits          28855    28885      +30     
+ Misses        41415    41408       -7     
- Partials       2573     2574       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.


🚨 Try these New Features:

…-dont-know-country-and-currency' into 12903-woo-pos---payments-onboarding-add-analytics-events
Base automatically changed from 12904-woo-pos---payments-onboarding-handle-case-when-we-dont-know-country-and-currency to trunk November 18, 2024 15:27
@kidinov kidinov linked an issue Nov 18, 2024 that may be closed by this pull request
@AnirudhBhat AnirudhBhat self-assigned this Nov 19, 2024
Copy link
Contributor

@AnirudhBhat AnirudhBhat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for working on this @kidinov. Overall, it looks good. I noticed that woocommerceandroid_card_present_onboarding_not_completed event gets triggered twice. First when the onboarding error screen is shown in POS and the second time when you exit the POS Mode.

Screenshot 2024-11-19 at 3 18 49 PM

@kidinov
Copy link
Contributor Author

kidinov commented Nov 19, 2024

@AnirudhBhat thanks for the review

Yep, that's kinda expected as we track the status every time we check it

@kidinov kidinov merged commit d73b599 into trunk Nov 19, 2024
18 checks passed
@kidinov kidinov deleted the 12903-woo-pos---payments-onboarding-add-analytics-events branch November 19, 2024 14:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category: tracks Related to analytics, including Tracks Events. feature: point of sale POS project
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Woo POS - payments onboarding] Add analytics events
5 participants