Environment
- OS: Windows 11 25H2 (OS Build 26200.9445)
- JDK: 21
- Compose Native Webview version: 1.0.3
- Nucleus version: 2.5.5
- Gradle:9.5.1
- Kotlin 2.4.10
- Compose Multiplatform 1.11.1
- WebView2 Runtime version:
152.0.4191.66
- WebView2 executable path:
C:\Program Files (x86)\Microsoft\EdgeWebView\Application\152.0.4191.66\msedgewebview2.exe
Description
I am getting the following exception when creating a WebView on Windows 11. The WebView2 Runtime appears to be installed, and msedgewebview2.exe exists at the path above, but the library still reports that WebView2 could not be created.
Steps to reproduce
- Check out the repository at tag
v1.0.3.
- Build the desktop example using the documented command:
./gradlew :e2e-desktop:run
or package a distributable.
- Run the packaged desktop binary on Windows 11.
- The app crashes when the WebView is created.
Expected behavior
The WebView should be created successfully using the installed WebView2 Runtime.
Actual behavior
It throws:
Exception in thread "main" java.lang.IllegalArgumentException: Failed to create WebView2 (is WebView2 Runtime installed?)
at dev.nucleusframework.webview.web.windows.WindowsWebView2NativeWebView.<init>(WindowsWebView2NativeWebView.kt:73)
at dev.nucleusframework.webview.web.windows.WindowsWebView2NativeWebView.<init>(WindowsWebView2NativeWebView.kt)
at dev.nucleusframework.webview.web.WebViewDesktopKt.defaultWebViewFactory(WebViewDesktop.kt:115)
at dev.nucleusframework.webview.web.WebViewKt$WebView$factory$1$1.invoke(WebView.kt:30)
at dev.nucleusframework.webview.web.WebViewKt$WebView$factory$1$1.invoke(WebView.kt:30)
at dev.nucleusframework.webview.web.WebViewDesktopKt.ActualWebView(WebViewDesktop.kt:182)
at dev.nucleusframework.webview.web.WebViewKt.WebView(WebView.kt:64)
at dev.nucleusframework.webview.e2e.visualsuite.VisualSuiteAppKt.VisualSuiteApp(VisualSuiteApp.kt:269)
Troubleshooting already tried
Environment
152.0.4191.66C:\Program Files (x86)\Microsoft\EdgeWebView\Application\152.0.4191.66\msedgewebview2.exeDescription
I am getting the following exception when creating a WebView on Windows 11. The WebView2 Runtime appears to be installed, and
msedgewebview2.exeexists at the path above, but the library still reports that WebView2 could not be created.Steps to reproduce
v1.0.3.Expected behavior
The WebView should be created successfully using the installed WebView2 Runtime.
Actual behavior
It throws:
Troubleshooting already tried
Confirmed that this file exists:
C:\Program Files (x86)\Microsoft\EdgeWebView\Application\152.0.4191.66\msedgewebview2.exeConfirmed WebView2 Runtime installation:
Output:
Checked registry:
Output: