Windows build fails to load webview2.dll #2

Closed
opened 2025-08-28 21:37:44 +00:00 by rattatwinko · 1 comment
Owner

Description:
Currently, the Windows build produced by our Gitea CI pipeline throws the error:

webview2.dll cannot be loaded

This happens because:

  1. The pipeline cross-compiles on Linux using the x86_64-pc-windows-gnu target.
  2. The WebView2 runtime is not bundled with the binary, and Windows machines without it installed cannot run the app.

Why this matters:
Tauri requires WebView2 to function on Windows. Without it, our .exe artifacts are unusable on fresh Windows installations.

Possible solutions:

  • Bundle bootstrapper (recommended):
    Update src-tauri/tauri.conf.json to embed the WebView2 bootstrapper so the app auto-installs WebView2 at first launch:

    {
      "tauri": {
        "windows": {
          "webviewInstallMode": {
            "type": "embedBootstrapper",
            "silent": true,
            "installHooks": true
          }
        }
      }
    }
    
  • Ship installer separately:
    Download the Evergreen WebView2 installer (MicrosoftEdgeWebview2Setup.exe) during CI and include it in the release artifacts.

  • Long term:
    If possible, add a Windows runner and build with x86_64-pc-windows-msvc for maximum compatibility.

Acceptance Criteria:

  • Running the .exe on a clean Windows VM should not fail with a missing webview2.dll.
  • Either the app bundles the bootstrapper or the release artifacts include the installer.
**Description:** Currently, the Windows build produced by our Gitea CI pipeline throws the error: ``` webview2.dll cannot be loaded ``` This happens because: 1. The pipeline cross-compiles on Linux using the `x86_64-pc-windows-gnu` target. 2. The WebView2 runtime is **not bundled** with the binary, and Windows machines without it installed cannot run the app. **Why this matters:** Tauri requires WebView2 to function on Windows. Without it, our `.exe` artifacts are unusable on fresh Windows installations. **Possible solutions:** * **Bundle bootstrapper (recommended):** Update `src-tauri/tauri.conf.json` to embed the WebView2 bootstrapper so the app auto-installs WebView2 at first launch: ```json { "tauri": { "windows": { "webviewInstallMode": { "type": "embedBootstrapper", "silent": true, "installHooks": true } } } } ``` * **Ship installer separately:** Download the Evergreen WebView2 installer (`MicrosoftEdgeWebview2Setup.exe`) during CI and include it in the release artifacts. * **Long term:** If possible, add a Windows runner and build with `x86_64-pc-windows-msvc` for maximum compatibility. **Acceptance Criteria:** * Running the `.exe` on a clean Windows VM should **not** fail with a missing `webview2.dll`. * Either the app bundles the bootstrapper or the release artifacts include the installer.
rattatwinko changed title from **Title:** Windows build fails to load `webview2.dll` to Windows build fails to load `webview2.dll` 2025-08-28 21:37:53 +00:00
Author
Owner

this is a known issue on debloated installs default windows handles this fine.
run web or some different version if you debloated windows.

tldr:
if you want to run bytechat dont debloat

this is a known issue on debloated installs default windows handles this fine. run web or some different version if you debloated windows. tldr: if you want to run bytechat dont debloat
Sign in to join this conversation.
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: rattatwinko/bytechat-desktop#2
No description provided.