Pinning a pushed window to a wall breaks pushWindow for all other apps on the system

I posted https://developer.apple.com/forums/thread/809481 yesterday about an issue I discovered with pushWindow in visionOS 26.2 RC, but today I discovered a second problem with pushWindow.

If window A calls pushWindow to present window B, and the user pins window B to a wall, the following unexpected behaviors are observed:

  • Window B spontaneously disappears.
  • If the user re-launches the (still running) app from the visionOS home view, both window A and window B appear simultaneously. I assume only window B should be visible at this point, since window A pushed window B.
  • If the user closes window B, it's now impossible to present window B again. Calls to pushWindow appear to be ignored.
  • If the user force-quits the app and relaunches it, and pushWindow is called again, window B appears, but window A remains visible.

I also noticed this surprising behavior:

  • This broken state of pushWindow behavior now affects all other apps on the system that may call pushWindow in the future, not just the app whose pushed window was pinned above.

A workaround is to reboot the device, and then the system will behave as expected until the next time the user pins a pushed window.

Answered by drewolbrich in 869634022

I believe I've discovered a workaround for this pushWindow bug. If I add the .restorationBehavior(.disabled) scene modifier to the WindowGroup corresponding to the pushed window, the bug doesn't happen.

If the user pins a pushed window to the wall, the window doesn't disappear, and the app and all other apps that may call pushWindow aren't bricked until the next device reboot.

Hey @drewolbrich,

Thanks for pointing this out and for filing FB21294645. I've forwarded this to the relevant team(s).

Thanks!

Accepted Answer

I believe I've discovered a workaround for this pushWindow bug. If I add the .restorationBehavior(.disabled) scene modifier to the WindowGroup corresponding to the pushed window, the bug doesn't happen.

If the user pins a pushed window to the wall, the window doesn't disappear, and the app and all other apps that may call pushWindow aren't bricked until the next device reboot.

Pinning a pushed window to a wall breaks pushWindow for all other apps on the system
 
 
Q