App remediation in Windows 10

When building the Universal Windows Platform, one of the core tenets we had was ensuring app behavior was predicable, successful and reliable. While we were able to make very strong guarantees, unfortunately sometimes things still go awry - but don't worry, we planned for that too! In the rare occurrence that a UWP app has hit an error, the platform is able to detect this and provide a neat way to fix the problem with the help of the Store - we call this app remediation.

Here's what it looks like when an app is in some error state and launch is attempted.


For the most part, these errors are transient and require some basic user action (e.g. an app's trial expired, it must be purchased or removed) and in other cases they require a bit more help from the Store (e.g. the app's files are corrupted, it must be re-downloaded). In all cases, when an app requires remediation, the action can be quickly completed without loosing any of the app's local data!! (e.g. game save or configuration)

While we generally don't like that there are speed bumps between our users and apps, we believe the Universal Windows Platform provides an easy way to get apps functional again without sacrificing on any of our core tenets.



For those who want to understand the nitty gritty of how app remediation works, it operates by leveraging the PackageStatus class to indicate to the system that the app is in some non-ok state. Different components in the system are responsible for setting different PackageStatus values for their own unique circumstances.

For example, as part of activating an app, the system will check the state of the license of the app and may set the PackageStatus to LicenseIssue if the app's trial has expired. Another scenario could be anti-virus software setting the PackageStatus to Tampered if some files in the app have been altered in any way (based on the appxblockmap.xml). Yet another expected scenario could be PackageStatus getting set to PackageOffline or DataOffline if the package or the user's data (respectively) is on an ejected drive.

You might ask - what about groups of packages that have a dependency on one another? We simply take the union of all PackageStatus values and use it as the global PackageStatus for that package / user.

For those of you who have used App Extensions, PackageStatus can be used as a way to check the status of an App Extension. A typical scenario would be PackageStatus set to Servicing if the App Extension is being currently updated.



Any questions? leave them in the comments!



Jason Salameh, Senior Program Manager – Windows Developer Platform

Comments (2)
  1. Mary B says:

    How about error states that don’t display app UI, like the UWP bug that has reappeared in FCU, where UWP apps sometimes open as a small, white window that’s just the titlebar with no content rendered?

    1. John.V says:

      Thanks for the feedback, we will look into what we can do here. For the Fall Creators Update issue the bug was related to the platform and not a specific app. The app generally worked on a subsequent launch.

Comments are closed.

Skip to main content