Skip to content

Conversation

@hichamboushaba
Copy link
Member

@hichamboushaba hichamboushaba commented Sep 2, 2025

Closes WOOMOB-1180

Description

This PR adds handling of errors in App Passwords flows according to what was decided in pe5sF9-4ye-p2#comment-4787.

For flagging websites as unsupported, I opted for using SharedPreferences, which makes the logic simpler, as fetching the site from the API won't override it.

Steps to reproduce

Test TC3, TC4 and TC5 from the testing plan pe5sF9-4Am-p2

Testing information

  • Confirm the test cases work as expected.

The tests that have been performed

The above.

  • 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.

@hichamboushaba hichamboushaba added type: task An internally driven task. category: performance Related to performance such as slow loading. labels Sep 2, 2025
@hichamboushaba hichamboushaba force-pushed the issue/WOOMOB-1126-app-passwords-network branch from 06cffda to 8ea3d7f Compare September 2, 2025 18:11
@hichamboushaba hichamboushaba force-pushed the issue/WOOMOB-1180-app-passwords-error-handling branch from 1b1f337 to 464912e Compare September 2, 2025 18:14
@wpmobilebot
Copy link
Collaborator

wpmobilebot commented Sep 2, 2025

📲 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
Commitc977e88
Direct Downloadwoocommerce-wear-prototype-build-pr14552-c977e88.apk

@hichamboushaba hichamboushaba force-pushed the issue/WOOMOB-1180-app-passwords-error-handling branch from 464912e to c977e88 Compare September 2, 2025 18:35
@wpmobilebot
Copy link
Collaborator

wpmobilebot commented Sep 2, 2025

📲 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
Commitc977e88
Direct Downloadwoocommerce-prototype-build-pr14552-c977e88.apk

@hichamboushaba hichamboushaba added this to the 23.2 milestone Sep 2, 2025
@codecov-commenter
Copy link

Codecov Report

❌ Patch coverage is 51.02041% with 24 lines in your changes missing coverage. Please review.
✅ Project coverage is 38.05%. Comparing base (8ea3d7f) to head (c977e88).

Files with missing lines Patch % Lines
...ionpasswords/JetpackApplicationPasswordsSupport.kt 0.00% 10 Missing ⚠️
.../android/fluxc/network/rest/wpcom/wc/WooNetwork.kt 0.00% 7 Missing ⚠️
...pplicationpasswords/ApplicationPasswordsManager.kt 25.00% 2 Missing and 1 partial ⚠️
...pplicationpasswords/ApplicationPasswordsNetwork.kt 0.00% 3 Missing ⚠️
...sswords/JetpackApplicationPasswordsErrorHandler.kt 96.00% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@                              Coverage Diff                              @@
##             issue/WOOMOB-1126-app-passwords-network   #14552      +/-   ##
=============================================================================
+ Coverage                                      38.04%   38.05%   +0.01%     
- Complexity                                      9473     9487      +14     
=============================================================================
  Files                                           2045     2047       +2     
  Lines                                         114338   114371      +33     
  Branches                                       15153    15162       +9     
=============================================================================
+ Hits                                           43501    43526      +25     
- Misses                                         66853    66860       +7     
- Partials                                        3984     3985       +1     

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@JorgeMucientes JorgeMucientes self-assigned this Sep 3, 2025
@hichamboushaba hichamboushaba force-pushed the issue/WOOMOB-1180-app-passwords-error-handling branch from 32c308d to c977e88 Compare September 4, 2025 14:15
@wpmobilebot wpmobilebot modified the milestones: 23.2, 23.3 Sep 5, 2025
@wpmobilebot
Copy link
Collaborator

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

Base automatically changed from issue/WOOMOB-1126-app-passwords-network to trunk September 5, 2025 22:12
Copy link
Contributor

@JorgeMucientes JorgeMucientes left a comment

Choose a reason for hiding this comment

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

Outstanding work @hichamboushaba, really clear testing instructions and (life saving snippets code config) to be able to test all the different error handling for this project. Everything worked as expected and the code looks clear and easy to follow despite the complexity of dealing with the many different error scenarios 👏🏼 .

@hichamboushaba hichamboushaba merged commit 370a6d4 into trunk Sep 8, 2025
23 of 24 checks passed
@hichamboushaba hichamboushaba deleted the issue/WOOMOB-1180-app-passwords-error-handling branch September 8, 2025 15:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

category: performance Related to performance such as slow loading. type: task An internally driven task.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants