-
Notifications
You must be signed in to change notification settings - Fork 55
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
WebView2 freezes after logging in to facebook. #3488
Comments
Thanks for reporting the issue. I've assigned this to a dev who can help follow up on this. |
same error |
Hi @NicatQaraxanov @hazem-it, I simply navigate to Facebook website in our WinForms sample app. I successfully logged in and receive notification on my test. Could you give more details about your scenario? so I can address the root cause. Thanks. |
@ElyssaJyu error occurs every time Facebook attempts to display a white overlay with a popup, which I suspect is caused by a certain JavaScript call. This popup and overlay don't appear every time you log in, only the very first time and if you have cleaned your cache and cookies. You might see this popup in Edge browser's private mode. And here additional video about what happens. |
You need to delete all files created by the browser before trying again |
Untitled.mp4 |
@hazem-it yes, that is exactly what happens on my application too. |
I've got the same error. Looks like a bug. |
Thanks for provided details. I tracked as a bug internally and investigate it. I will async with you when there is a fix. Thanks. |
Hi, I haven't been able to completely reproduce the issue based on your scenario, but I have encountered a similar freeze situation on my end. I would like to confirm a few details:
Thanks for the incoming feedbacks. |
I have the same issue when trying using it in a WPF application. First time logging into facebook it crashes the entire program. After log in is cached, subsequent loading of the page cause only the control to stop working. The webview2 does not appear to be disposed but does become invalid. I can still access it via code. When trying to set a new source for it, it throws the following error. System.InvalidOperationException: 'The WebView control is no longer valid because the browser process crashed.To work around this, please listen for the CoreWebView2.ProcessFailed event to explicitly manage the lifetime of the WebView2 control in the event of a browser failure.https://docs.microsoft.com/en-us/dotnet/api/microsoft.web.webview2.core.corewebview2.processfailed' The CoreWebView2.ProcessFailed event returns the following: <title>Document</title>
|
Hi @ElyssaJyu, Thank you for your detailed feedback and observations. I'll attempt to address your queries as concisely as possible:
I hope this information proves helpful in understanding the issue at hand better, and I look forward to any insights or solutions you might be able to suggest. |
@johnasebok did approach with CoreWebView2.ProcessFailed help? WebView2 stopped freezing? |
Hi @NicatQaraxanov,
this seems your .net version and framework. I'd like to clarify your WebView2 runtime and SDK version. Your can find SDK version from NuGet package manager in your project and using CoreWebView2Environment.GetAvailableBrowserVersionString(String) Method to find runtime version.
Thanks |
@ElyssaJyu the SDK version is mentioned on my very first message in this issue (WebView2: 1.0.1774.30). It is latest. |
@ElyssaJyu The ProcessFailed event has been triggered, providing the same information as @johnasebok mentioned. However, once the process has failed, how can I recover from it? I have tried to recreate the WebVeiw instance and all but it didn't work. Same error happening again. |
@NicatQaraxanov. I'm trying to find a workaround, will post it ASAP. Sorry for that inconvenience. |
@ElyssaJyu Thank you for your response. I appreciate your effort in finding a workaround and your commitment to resolving the issue. Take your time. I look forward to hearing from you as soon as possible. |
Hi @NicatQaraxanov. I find a potential workaround. Please try to disable this Web App Widgets. Could you confirm whether it will work? I'm still working on finding the root cause. Thanks. |
@ElyssaJyu Thank you for providing the workaround! I appreciate your efforts in finding a solution. I have tried disabling the Web App Widgets as you suggested, and I'm happy to inform you that it has successfully resolved the problem. |
Thanks @ElyssaJyu that works for me. The WPF control doesn't seem to have an option to set the CoreWebView2EnvironmentOptions.AdditionalBrowserArguments. So just I used: And viola! It no longer crashes. |
Hi @ElyssaJyu! I have a quick question. Does disabling Web App Widgets affect WebView2 performance? I'm not entirely certain, but I believe I might experience some performance loss after disabling the Web App Widgets. For example, when visiting YouTube and so on. |
Hi @NicatQaraxanov, I don't think disabling this feature should affect WebView2 performance, could you provide some details about performance loss you faced? Thanks |
@ElyssaJyu I cant say 100% if its happening because of Web App Widgets. I will ping you after i gain much more information about this problem. Thank you for your response :) |
Hi, the issue has been fixed in webview2 runtime 114+, and new version has been released. @NicatQaraxanov, I will close this issue since webview2 freeze has been fixed. If any further issue with webview2 performance, please either reopen this case or open a new one, and notify me, thank you. |
Hi @ElyssaJyu! When I disable Web App Widgets and try to enter YouTube, it freezes sometimes. Could you please check it? |
@NicatQaraxanov Hi, have you upgraded the runtime to 114 version? In the latest version, you don't need to disable the Widgets feature to avoid webview2 freezing. Please let me know if WebView2 still freezes occasionally in the 114+ without disabling behavior. Thanks Also, I have reached out the feature team, currently, the crash when manually disabling widgets is an understood behavior that should not be impacting any users who are not manually passing command line flags. The team will make some change on this feature in the near future. |
Do you mean installing the latest version on WebView2 from nuget package manager @ElyssaJyu? The latest is 1.0.1823.32 |
NuGet package is for WebView2 SDK. If you use Evergreen distribution mode, it's automatically up to date; if fixed version mode, please try to manually upgrade it. |
I also encounter the same issue; when I try to open the Facebook website, it becomes unresponsive. WebView2 Runtime Evergreen Bootstrapper |
Hi, I encounter a WebView2 freezing in my app when I open the Facebook website for authentication. WebView2 Runtime version is 120.0.2210.121, taken from Settings -> Apps -> Installed Apps. Now, I am no longer able to sign into Facebook from my app. |
I also encounter the same issue; when I try to open the Facebook website, it becomes unresponsive. WebView2 Runtime Evergreen Bootstrapper |
I am experiencing a similar issue |
Hi, I have the same issue. My app worked in December 2023, now it stopped showing the facebook site, other sites are working so far. I also tried to use the code from the WebView2Samples but the same problem there with facebook. |
Hi @Ychyi1 @HoangPhiHung0618 @didess27 @ixiaokang @tekmun, the issue you are facing is actually a new / different bug, tracked in the following GitHub issue. The issue is fixed in Edge Canary 122.0.2330.0+. Could you please test with Canary channel and validate the fix? |
In the meantime, I am closing this issue as it's solved, and the new issue is tracked in #4281 |
Description
When I try to log in to Facebook, WebView2 occasionally freezes. I can't determine the exact cause, but I've noticed a possible correlation with requests for notification permissions; when a website requests these permissions, it tends to freeze. Conversely, when the website does not request notification permissions, it operates normally. While I'm not entirely certain that this is the cause, it's a potential lead. Moreover, this issue only occurs when I'm logging into Facebook. Everything works normally on the login page.
Version
WebView2: 1.0.1774.30
Framework: WinForms.
OS: Win10.
Screenshots
Here you can see that this happens and after this WebView just stops working.
AB#44688481
The text was updated successfully, but these errors were encountered: