WKInterfaceController page layout init and awake are not called until user swipes pages

I've noticed a bug in my app recently, it appears that in watchOS 8.5 (or earlier) that page layout is no longer initializing or awakingWithContext the pages beyond the first index.

According to the documentation:

In a page-based interface, all interface controllers are initialized up front but only the first one is displayed initially.

https://developer.apple.com/documentation/watchkit/wkinterfacecontroller/1619521-init

I am simply not seeing this happen anymore. I have logging in all of the lifecycle method of all three of my pages and the second and third controllers don't fire anything (including init) until I swipe to the right. This is when I would expect the willActivate and didActivate methods to be invoked. Instead I get init, awake, willActivate, and then didActivate. :/

This is unfortunate and a bug to the user because the second controller asks to becomeCurrent under some certain conditions that the first detects and fires via NotificationCenter. The automatic programatic switching between pages is totally broken.

FB9972047

The most recent documentation updates suggest moving to and using SwiftUI for any watch development, that is something to consider given there is much more flexibility.

WKInterfaceController page layout init and awake are not called until user swipes pages
 
 
Q