MicrosoftEdge / MicrosoftEdge/WebView2Feedback
[Problem/Bug]: Disabling built-in error pages not working as expected
@ParadoxZero is already working on this.
Since Feb 13, 2025.
- Dominant language
- PowerShell
- Stars
- 526
- Forks
- 67
- PR merge metrics
- No merged PRs in 30d
Description
What happened?
Setting IsBuiltInErrorPageEnabled to FALSE via ICoreWebView2Settings::put_IsBuiltinErrorPageEnabled does not disable the built-in error pages as expected.
Expected Behavior
- The built-in error pages should be disabled after setting
IsBuiltInErrorPageEnabledtoFALSE. - Unless the library-user navigates to a custom error page, nothing should be displayed instead of the built-in error pages when navigation errors occur.
Actual Behavior
- Even with
IsBuiltInErrorPageEnabledset toFALSE, the built-in error pages still appear. - Emitting HTML error responses from
ICoreWebView2WebResourceRequestedEventHandlerresults in the built-in error page flashing before displaying the custom error page.
Additional Information
The issue persists even when omitting the NavigateToString call in ICoreWebView2NavigationCompletedEventHandler.
Importance
Moderate. My app's user experience is affected, but still usable.
Runtime Channel
Stable release (WebView2 Runtime)
Runtime Version
124.0.2478.80
SDK Version
1.0.2088.41
Framework
Win32
Operating System
Windows 11
OS Version
23H2
Repro steps
- Set
IsBuiltInErrorPageEnabledtoFALSEwithin theICoreWebView2CreateCoreWebView2ControllerCompletedHandlercallback. - Register a custom URI scheme and handle associated requests using
AddWebResourceRequestedFilterandICoreWebView2WebResourceRequestedEventHandler. - Register a
ICoreWebView2NavigationCompletedEventHandlerto handle navigation errors and display a custom error page usingNavigateToString.
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
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.