-
Notifications
You must be signed in to change notification settings - Fork 51
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Crash with "Run as admin" compatibility flag #2356
Comments
The dumps in the crashpad indicates that it is crashing due to repeatedly failed to launch GPU processing. Since the app also logged renderer process launch failure, I believe that this is the case where the security configurations on the server doesn't allow those sandboxed WebView2 child processes msedgewebview2.exe to be created. Try to see whether there are events from antivirus product or OS security components. |
Thought about this again. If the app works normally, it should not be antivirus/security configuration related. |
@deemaseeq , we’ve made a change based on educated guess. Could you please try it out and see whether that works for you? • Install Edge browser canary channel from Microsoft Edge Insider |
Hello, @LiangTheDev. I've also tried to investigate the issue more. It was also possible to reproduce the issue with Microsoft Edge itself, Chrome and chromium. Firefox and Visual Studio Code also don't work properly when flag is set, although they do not crash, just fail to open anything. On every crash the event in Microsoft-Windows-UAC/Operational is generated. "The process failed to handle ERROR_ELEVATION_REQUIRED during the creation of a child process." with EventID: 1. Thank you for the intervention, you guys are amazing. |
Thanks for all the details, and glad that the change works. We will now make the change for Edge WebView2 Runtime, probably in version 103. |
This is fixed in runtime version 103.0.1254.0+. Thanks! |
Description
I have an issue in WinForms application. We are using WebView2 to show some embedded video from the internet. WebView is always navigated to a fixed single page. It works fine, but in certain circumstances it crashes.
Specifically:
I've checked several things.
Here is the exception:
System.InvalidOperationException: CoreWebView2 members cannot be accessed after the WebView2 control is disposed.
---> System.Runtime.InteropServices.COMException (0x8007139F): The group or resource is not in the correct state to perform the requested operation. (0x8007139F)
at Microsoft.Web.WebView2.Core.Raw.ICoreWebView2Controller.MoveFocus(COREWEBVIEW2_MOVE_FOCUS_REASON reason)
at Microsoft.Web.WebView2.Core.CoreWebView2Controller.MoveFocus(CoreWebView2MoveFocusReason reason)
--- End of inner exception stack trace ---
at Microsoft.Web.WebView2.Core.CoreWebView2Controller.MoveFocus(CoreWebView2MoveFocusReason reason)
at Microsoft.Web.WebView2.WinForms.WebView2.OnGotFocus(EventArgs e)
at System.Windows.Forms.Control.WmSetFocus(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at Microsoft.Web.WebView2.WinForms.WebView2.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, WM msg, IntPtr wparam, IntPtr lparam)
Also, here is the data we got from ProcessFailed event:
CoreWebView2_ProcessFailed was invoked. Sender is Microsoft.Web.WebView2.Core.CoreWebView2.ExitCode: [18];
FrameInfosForFailedProcess: [];
ProcessDescription: [];
ProcessFailedKind: [RenderProcessExited];
Reason: [LaunchFailed];
I've omitted stack trace and loaded assemblies.
Also, I created sample project where just put WebView2 on the form to replicate the issue. I've included Crashpad folder from WebView2 data folder. There are some dumps there, which I'm not sure how to analyze. All I can tell is that error 0x0517A7ED is occurred.
Crashpad.zip
Version
We are running .NET 5, sdk version 5.0.405.
NuGet: 1.0.1150.38
Runtime: Fixed runtime supplied with the project. We used 93.0.961.47 at first, tried to update to 99.0.1150.46 but it didn't fixed the issue.
Framework: WinForms.
OS: Windows Server 2016 Standard 10.0.14393, Build 14393
Architecture: X64.
AB#39176451
The text was updated successfully, but these errors were encountered: