Hiccoughs

Posted by Stuart Wheelwright on April 24, 2023 · 2 mins read

After releasing the big update I discovered a problem.

The new list sharing feature wasn’t working properly. I had a busy Saturday bug fixing and re-publishing the app.

The fix (v3.3.1) was approved by the App Store team this morning, and it is now available for download.

What caused the problem?

When a change is made, iCloud sends a notification to all devices that share the list.

The notification is received if the app is active (on screen), in the background (in memory but not actively consuming resources), and even if the app is not running — iOS will launch the app for up to 30 seconds to give it a chance to process the notification.

When Shopping UK was not active, it would sometimes crash.

This caused two problems:

  1. The notification was not fully processed.
  2. The app didn’t send a result back to iOS.

This second point turns out to be really important.

After the app has finished, iOS expects to receive a result: newdata, nodata or failed. iOS uses this to categorise the app’s energy use.

It’s all about saving battery. iOS continually monitors if each app is playing by the rules and being a good efficient energy citizen.

iOS does not send every notification to the app. Sometimes, a notification will be skipped or delayed. This happens when an app exceeds its energy budget or doesn’t play by the rules.

When Shopping UK didn’t return a result, iOS would punish it by refusing to send notifications for a while.

Fortunately, this issue was not a disaster. I paused the phased rollout immediately, and only 1.3% of users (870 devices) had updated to v3.3, and very few of them were using the new sharing feature, and those that were could manually refresh the list.

The issue is now fixed and I’m pretty happy with how fast items synchronise:


(Day 20 of 87)

Please try Shopping UK and let me know what you think at @wheelies