MicrosoftEdge / MicrosoftEdge/WebView2Feedback

[Problem/Bug]: WebView2 not running when uap10:TrustLevel="appContainer" is set for WinUI3 packaged app

Open
#5,320 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
PowerShell
Stars
526
Forks
67
PR merge metrics
No merged PRs in 30d

Description

What happened?

WebView2 is not showing on UI when following is configure in Package.appxmanifest:

<Package
  ...
  xmlns:uap10="http://schemas.microsoft.com/appx/manifest/uap/windows10/10"
  ...>
  ...
  <Applications>
    <Application Id="App"
      Executable="$targetnametoken$.exe"
      EntryPoint="Windows.PartialTrustApplication"
      uap10:TrustLevel="appContainer"
      uap10:RuntimeBehavior="packagedClassicApp">
...
Importance

Blocking. My app's basic functions are not working due to this issue.

Runtime Channel

Stable release (WebView2 Runtime)

Runtime Version

No response

SDK Version

1.0.2903.40

Framework

WinUI3/WinAppSDK

Operating System

Windows 11

OS Version

26100.4652

Repro steps
  1. Create WinUI Blank App (Packaged)
  2. Modify Package.appxmanifest setting values:
    EntryPoint="Windows.PartialTrustApplication"
    uap10:TrustLevel="appContainer"
    uap10:RuntimeBehavior="packagedClassicApp"
  3. Place WebView2 control on a page and set its Source

AR: Application runs without an error but no WebView2 control can be seen on UI

ER: Application runs and WebView2 is rendered on UI with

Repros in Edge Browser

No, issue does not reproduce in the corresponding Edge version

Regression

Don't know

Last working version (if regression)

No response

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the issue with the Package.appxmanifest settings shown and a WebView2 control whose Source is set. Compare the packaged app's behavior with the expected rendered WebView2 UI, then investigate the interaction between appContainer trust, packagedClassicApp runtime behavior, and WinUI3/WinAppSDK. Done means WebView2 renders correctly under the reported configuration.

Written by the indexing model from the issue text.

Assessment

Domain
desktop
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.