woocommerce / woocommerce-ios

WooCommerce iOS app
https://www.woocommerce.com/mobile
GNU General Public License v2.0
257 stars 108 forks source link

Fix/speculative fix for double order pushes #12643

Closed joshheald closed 2 weeks ago

joshheald commented 2 weeks ago

Part of: #12071

Description

Some of the issues under this crash appear to be related to double-pushing Order loaders, probably from a notification.

This really shouldn't be possible, because we make a new instance of the order loader every time that we use it, and we also don't push them, we set the splitview's viewcontroller's property to an array with just the one order loader in it.

So... I'm not confident that this fix will do anything, but it doesn't break anything either.

If this doesn't have any effect on the crash numbers, we should remove it

peaMlT-zn-p2 for context.

Testing instructions

I could not repro the crash, so these are general testing instructions.

  1. Launch the app, then background it
  2. Make an order on the web
  3. Tap the notification which comes up
  4. Observe that the order is shown as expected.

wpmobilebot commented 2 weeks ago

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 Numberpr12643-793b675
Version18.5
Bundle IDcom.automattic.alpha.woocommerce
Commit793b675e48e7f32311fc664aff17dfe4e2a8e4b8
App Center BuildWooCommerce - Prototype Builds #8945

Automatticians: You can use our internal self-serve MC tool to give yourself access to App Center if needed.

joshheald commented 2 weeks ago

@iamgabrielma thanks for the review.

Not sure about why you're not getting notifications, I get them even for pay-in-person orders.

iamgabrielma commented 2 weeks ago

Not sure about why you're not getting notifications, I get them even for pay-in-person orders.

I think is a wider issue not exclusive to iOS. More instances reported here p1714738845170739-slack-C025A8VV728