OutSystems / WebView

Avalonia/WPF control that wraps CefGlue webview control
Apache License 2.0
396 stars 44 forks source link

Xilium.CefGlue.CefVersionMismatchException: CEF runtime version mismatch #260

Closed kurtyoder closed 2 years ago

kurtyoder commented 2 years ago

After installing the Nuget package, I used

<webview:WebView Grid.Column="1" x:Name="webview" Address="{Binding CurrentAddress}" /> to add the control to my view.

When the view is loaded, I get the following error:

Xilium.CefGlue.CefVersionMismatchException: CEF runtime version mismatch: loaded version API hash "b262c3a2cbd2632de1bfed887da8b8114c9ecbf5", but supported "4150bd26e7bf639a9b1f3e5860af8c76eeae8570" (91.1.6+g8a752eb+chromium-91.0.4472.77).
   at Xilium.CefGlue.CefRuntime.CheckVersionByApiHash()
   at Xilium.CefGlue.CefRuntime.CheckVersion()
   at Xilium.CefGlue.CefRuntime.Load(String path)
   at Xilium.CefGlue.CefRuntime.Load()
   at Xilium.CefGlue.Common.CefRuntimeLoader.InternalInitialize(CefSettings settings, KeyValuePair`2[] flags, CustomScheme[] customSchemes, BrowserProcessHandler browserProcessHandler)
   at Xilium.CefGlue.Common.CefRuntimeLoader.<>c__DisplayClass2_0.<Initialize>b__0(BrowserProcessHandler browserProcessHandler)
   at Xilium.CefGlue.Common.CefRuntimeLoader.Load(BrowserProcessHandler browserProcessHandler)
   at Xilium.CefGlue.Common.BaseCefBrowser..ctor()
   at Xilium.CefGlue.Avalonia.AvaloniaCefBrowser..ctor()
   at WebViewControl.ChromiumBrowser..ctor()
   at WebViewControl.WebView.Initialize()
   at WebViewControl.WebView..ctor(Boolean useSharedDomain)
   at WebViewControl.WebView..ctor()

This occurred in versions 2.91.25, 2.91.26, and 2.91.27

joaompneves commented 2 years ago

Have you tried a clean checkout? Were there errors during projects restore/build? Check the version of the libcef.dll, it should be 91.0.4472.77.

kurtyoder commented 2 years ago

Ok, my version was 91.1.6.0, let me try deleting the directory and retrying this.

kurtyoder commented 2 years ago

So, I cleared my nuget cache and restored the project. My build failed until I removed the WebViewControl-Avalonia nuget package from the solution. It was upset with some dependency related to DinkToPdf. Is it possible that WebView and DinkToPDF aren't playing nice?

joaompneves commented 2 years ago

I don't know that package.