MicrosoftEdge / MicrosoftEdge/WebView2Feedback
WebView does not display the content in ~5% of runs
@champnic is already working on this.
Since Dec 1, 2021.
- Dominant language
- PowerShell
- Stars
- 526
- Forks
- 67
- PR merge metrics
- No merged PRs in 30d
Description
Description
Hi! I use Fixed Version WebView in Win32 application.
It usually works fine. But in ~5% of application runs, the WebView does not display the content.
Usually, 8 msedgewebview2.exe processes are created on the system to service WebView control. But in those 5% of cases when the WebView content is not displayed, there are only 4 or 5 processes.
Crashpad\reports is empty.
Event Log is empty.
ProcessFailed event does not happen.
What could be the problem? Are there any tools for debugging?
Usage sample:
auto options = Make<CoreWebView2EnvironmentOptions>();
checkHRESULT( options->put_AdditionalBrowserArguments( L"--disable-features=msSmartScreenProtection" ) );
checkHRESULT( CreateCoreWebView2EnvironmentWithOptions( runtimePath, userDataPath, options.Get(),
Callback<ICoreWebView2CreateCoreWebView2EnvironmentCompletedHandler>( this, &CWebView::OnCreateEnvironmentCompleted ).Get() ) );
// Pseudo-synchronous creation https://github.com/MicrosoftEdge/WebView2Feedback/issues/740
while( webviewWindow == nullptr && ::WaitMessage() ) {
CMessageLoop::PumpMessages( 0, WM_USER + 1, WM_USER + 1 );
}
checkHRESULT( webviewWindow->add_ProcessFailed(
Callback<ICoreWebView2ProcessFailedEventHandler>( this, &CWebView::OnProcessFailed ).Get(), &processFailedToken ) );
CComPtr<ICoreWebView2Settings> settings;
checkHRESULT( webviewWindow->get_Settings( &settings ) );
checkHRESULT( settings->put_IsZoomControlEnabled( FALSE ) );
checkHRESULT( settings->put_IsStatusBarEnabled( FALSE ) );
checkHRESULT( settings->put_AreDefaultContextMenusEnabled( FALSE ) );
checkHRESULT( settings->put_AreDevToolsEnabled( FALSE ) );
checkHRESULT( controller->put_Bounds( rect ) );
checkHRESULT( webviewWindow->Navigate( url ) );
Version
SDK: 1.0.1020.30
Runtime: 95.0.1020.53
Framework: Win32
OS: Win10
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.