wavetermdev/waveterm · error
electron executable path not set
Error message
electron executable path not set
What it means
Before building, the controller fetches the Electron executable path via wavebase.GetWaveAppElectronExecPath() and requires it to be non-empty, since the Tsunami build uses the Electron node binary. This literal error is thrown when the path was never set (empty string), meaning the app is running outside a properly initialized Wave shell/electron environment.
Source
Thrown at pkg/buildercontroller/buildercontroller.go:214
bc.handleBuildError(fmt.Errorf("failed to parse app id: %w", err), resultCh)
return
}
appPath, err := waveappstore.GetAppDir(appId)
if err != nil {
bc.handleBuildError(fmt.Errorf("failed to get app directory: %w", err), resultCh)
return
}
cachePath, err := GetBuilderAppExecutablePath(appPath)
if err != nil {
bc.handleBuildError(fmt.Errorf("failed to get builder executable path: %w", err), resultCh)
return
}
nodePath := wavebase.GetWaveAppElectronExecPath()
if nodePath == "" {
bc.handleBuildError(fmt.Errorf("electron executable path not set"), resultCh)
return
}
scaffoldPath := waveapputil.GetTsunamiScaffoldPath()
settings := wconfig.GetWatcher().GetFullConfig().Settings
sdkReplacePath := settings.TsunamiSdkReplacePath
sdkVersion := settings.TsunamiSdkVersion
if sdkVersion == "" {
sdkVersion = waveapputil.DefaultTsunamiSdkVersion
}
goPath := settings.TsunamiGoPath
outputCapture := build.MakeOutputCapture()
_, err = build.TsunamiBuildInternal(build.BuildOpts{
AppPath: appPath,
AppNS: appNS,
Verbose: true,
Open: false,View on GitHub (pinned to a4447c1563)
Solutions
- Launch wave through the normal electron bootstrap so GetWaveAppElectronExecPath is populated
- Check startup code that sets the electron exec path and why it did not run
- Verify the installed wave binary ships/locates the electron executable for the current OS
- Set the appropriate wave base path override in the environment before starting
Defensive patterns
Strategy: validation
Validate before calling
if wavebase.GetWaveAppElectronExecPath() == "" {
return fmt.Errorf("cannot build: electron exec path not initialized")
} Try / catch
if err := runBuild(appId); err != nil {
if strings.Contains(err.Error(), "electron executable path not set") { /* re-init environment */ }
} Prevention
- Launch wave through the standard electron bootstrap
- Check electron path registration at startup in dev/test harnesses
- Verify packaging includes/locates the electron binary per OS
When it happens
Trigger: GetWaveAppElectronExecPath() returns "" — the electron executable path global was never populated at startup, or wave is running in a context (headless/dev) where the electron binary path was not registered.
Common situations: Running the builder from a dev/test harness without the full electron bootstrap; packaging issue where the electron binary was not located at launch; WAVE override paths pointing at missing binaries.
Understand the failure class
Background: "environment variable is not set" and "Missing keys in environment" errors: what missing required env var messages mean and how to fix them — this error's family across 28 libraries.
Related errors
- setting auth key: %v
- failed to build secret environment (ERR-SECRET): %w
- error expanding home dir: %w
- error expanding query home dir: %w
- env string too large (max %d bytes)
AI-assisted analysis of wavetermdev/waveterm@a4447c1563 (2026-09-01).
Data as JSON: /api/errors/4683d125f33af15e.
Report an issue: GitHub.