Skip to content

Conversation

@malinajirka
Copy link
Contributor

@malinajirka malinajirka commented Oct 31, 2025

#WOOMOB-1623

Description

This is a tricky one. The issue is that when the navigation component returns result from RefundConfirmationDialog to RefundSummaryFragment, it first returns the result and later on performs the actual navigation to the RefundSummaryFragment. However, as the app processes the result it attempts to navigate to action_refundSummaryFragment_to_cardReaderFlow but since the navigation component is still on RefundConfirmationDialog the navigation doesn't happen since action action_refundSummaryFragment_to_cardReaderFlow is not found for RefundConfirmationDialog.

The proper fix would be to move this line to the bottom of the method. However, that's quite a risky change since it changes order throughout the app and we can't be sure it doesn't break anything.

Therefore, I opted for a suboptimal solution that feels significantly safer.

P.S. This issue was likely introduced here when we moved the action from dialog to summary fragment - #14083.

Test Steps

  1. Open an order that was paid with Interac card (canadian store)
  2. Tap on Refund Order
  3. Select some items in the order
  4. Continue
  5. Confirm Refund and notice the card reader flow starts (You won't be able to complete the flow without interac card, but just checking it starts is enough to verify the fix works)

Images/gif

Screen.Recording.2025-10-31.at.9.50.42.mov
  • 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.

@malinajirka malinajirka requested a review from kidinov October 31, 2025 08:52
@malinajirka malinajirka added the feature: mobile payments Related to mobile payments / card present payments / Woo Payments. label Oct 31, 2025
@malinajirka malinajirka added this to the 23.6 milestone Oct 31, 2025
@malinajirka malinajirka marked this pull request as ready for review October 31, 2025 08:52
@malinajirka malinajirka added the status: do not merge Dependent on another PR, ready for review but not ready for merge. label Oct 31, 2025
@dangermattic
Copy link
Collaborator

dangermattic commented Oct 31, 2025

1 Warning
⚠️ This PR is assigned to the milestone 23.6. The due date for this milestone has already passed.
Please assign it to a milestone with a later deadline or check whether the release for this milestone has already been finished.

Generated by 🚫 Danger

Base automatically changed from dependabot/gradle/stripe-terminal-4.7.1 to trunk October 31, 2025 08:55
@wpmobilebot
Copy link
Collaborator

wpmobilebot commented Oct 31, 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 NameWooCommerce-Wear Android
Platform⌚️ Wear OS
FlavorJalapeno
Build TypeDebug
Commit2e678a8
Direct Downloadwoocommerce-wear-prototype-build-pr14874-2e678a8.apk

@malinajirka malinajirka removed the status: do not merge Dependent on another PR, ready for review but not ready for merge. label Oct 31, 2025
Copy link
Contributor

@kidinov kidinov left a comment

Choose a reason for hiding this comment

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

I can not test it as I don't have the card, but the explanation and the code make sense to me

@wpmobilebot
Copy link
Collaborator

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

App NameWooCommerce Android
Platform📱 Mobile
FlavorJalapeno
Build TypeDebug
Commit2e678a8
Direct Downloadwoocommerce-prototype-build-pr14874-2e678a8.apk

@kidinov
Copy link
Contributor

kidinov commented Oct 31, 2025

@malinajirka I tested it with a simulator - works well!

@kidinov kidinov enabled auto-merge October 31, 2025 09:25
@kidinov kidinov merged commit f032e8d into trunk Oct 31, 2025
21 checks passed
@kidinov kidinov deleted the issue/woomob-1623-interac-refund-flow-is-broken-v2 branch October 31, 2025 09:34
@codecov-commenter
Copy link

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 38.27%. Comparing base (ef5f0d9) to head (2e678a8).
⚠️ Report is 72 commits behind head on trunk.

Additional details and impacted files
@@            Coverage Diff            @@
##              trunk   #14874   +/-   ##
=========================================
  Coverage     38.27%   38.27%           
- Complexity    10087    10088    +1     
=========================================
  Files          2135     2135           
  Lines        120976   120977    +1     
  Branches      16565    16565           
=========================================
+ Hits          46298    46302    +4     
+ Misses        69978    69976    -2     
+ Partials       4700     4699    -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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature: mobile payments Related to mobile payments / card present payments / Woo Payments.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants