macOS: Chromium process failed to start

3D WebView for Windows and macOS works by running Chromium in a separate process. It achieves this by launching a separate executable for Chromium, which is embedded in the 3D WebView library. In some rare circumstances, 3D WebView's attempt to start the Chromium process may fail with an error like this in the Unity Editor or Player logs:

3D WebView's Chromium process failed to start. To resolve this issue, please see this article: https://support.vuplex.com/articles/mac-chromium-failed-to-start

Launch path: "{path to the plugin}/VuplexWebViewMac.bundle/Contents/Frameworks/Vuplex WebView.app/Contents/MacOS/Vuplex WebView"

Exception: "launch path not accessible"

If this error occurs, it is likely due to 3D WebView's macOS files becoming corrupted. As a first step, please perform a clean reinstall of 3D WebView in the project by following these steps:

  1. On macOS, close Unity or verify that it is closed. This step is important because Unity's unable to reload native macOS plugins while the project is open in the Editor.

  2. Delete the project's existing Assets/Vuplex directory.

  3. Open the project in the Unity Editor for macOS.

  4. Import the latest version of 3D WebView for Windows and macOS.

If performing a clean reinstall of 3D WebView doesn't resolve the issue, then please see the following sections on potential causes and how to resolve them:

Chromium executable doesn't exist at the expected path

The first potential cause is that the Chromium executable may not exist at the expected path. To check if this is the issue, find the "Launch path" from the error message in the logs (like shown in the example error message above) and check if the file exists at that path. If it doesn't, then that likely means that 3D WebView wasn't able to locate the Chromium executable in the project's Assets folder. To resolve the issue, please verify that 3D WebView is installed in the project's Assets folder. If it's installed in a different folder, like Packages (i.e. Library/PackageCache), then 3D WebView won't be able to find the executable successfully. If the issue is occurring in a compiled app but not the Editor, then that likely indicates 3D WebView MacBuildScript.cs script is failing to copy the Chromium files into the compiled app at build time as expected. If that's the case, please add logging to MacBuildScript.cs to verify that it is running as expected.

Chromium executable doesn't doesn't have "execute" file permission

If the Chromium executable does exist at the "Launch path" path from the error message, then the issue may be that 3D WebView's Chromium files are somehow missing executable permission. If that's the case, you can resolve it by opening the macOS Terminal and executing the following commands to assign executable permission (replacing {path to the plugin} with the remaining part of "Launch path" from the error message):

cd "{path to the plugin}/VuplexWebViewMac.bundle/Contents/Frameworks/Vuplex WebView.app/Contents/"
chmod 755 "MacOS/Vuplex WebView" \
          "Frameworks/Vuplex WebView Helper.app/Contents/MacOS/Vuplex WebView Helper" \
          "Frameworks/Vuplex WebView Helper (GPU).app/Contents/MacOS/Vuplex WebView Helper (GPU)" \
          "Frameworks/Vuplex WebView Helper (Plugin).app/Contents/MacOS/Vuplex WebView Helper (Plugin)" \
          "Frameworks/Vuplex WebView Helper (Renderer).app/Contents/MacOS/Vuplex WebView Helper (Renderer)"

Diagnosing other causes

If the steps so far haven't resolve the issue, then the cause is something that hasn't been anticipated. To determine the issue, try running executable from the macOS Terminal like this and check for error messages:

cd "{path to the plugin}/VuplexWebViewMac.bundle/Contents/Frameworks/Vuplex WebView.app/Contents/MacOS/"
./Vuplex\ WebView

.