{"record":{"id":"4683d125f33af15e","repo":"wavetermdev/waveterm","slug":"electron-executable-path-not-set-4683d1","errorCode":null,"errorMessage":"electron executable path not set","messagePattern":"electron executable path not set","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"pkg/buildercontroller/buildercontroller.go","lineNumber":214,"sourceCode":"\t\tbc.handleBuildError(fmt.Errorf(\"failed to parse app id: %w\", err), resultCh)\n\t\treturn\n\t}\n\n\tappPath, err := waveappstore.GetAppDir(appId)\n\tif err != nil {\n\t\tbc.handleBuildError(fmt.Errorf(\"failed to get app directory: %w\", err), resultCh)\n\t\treturn\n\t}\n\n\tcachePath, err := GetBuilderAppExecutablePath(appPath)\n\tif err != nil {\n\t\tbc.handleBuildError(fmt.Errorf(\"failed to get builder executable path: %w\", err), resultCh)\n\t\treturn\n\t}\n\n\tnodePath := wavebase.GetWaveAppElectronExecPath()\n\tif nodePath == \"\" {\n\t\tbc.handleBuildError(fmt.Errorf(\"electron executable path not set\"), resultCh)\n\t\treturn\n\t}\n\n\tscaffoldPath := waveapputil.GetTsunamiScaffoldPath()\n\tsettings := wconfig.GetWatcher().GetFullConfig().Settings\n\tsdkReplacePath := settings.TsunamiSdkReplacePath\n\tsdkVersion := settings.TsunamiSdkVersion\n\tif sdkVersion == \"\" {\n\t\tsdkVersion = waveapputil.DefaultTsunamiSdkVersion\n\t}\n\tgoPath := settings.TsunamiGoPath\n\n\toutputCapture := build.MakeOutputCapture()\n\t_, err = build.TsunamiBuildInternal(build.BuildOpts{\n\t\tAppPath:        appPath,\n\t\tAppNS:          appNS,\n\t\tVerbose:        true,\n\t\tOpen:           false,","sourceCodeStart":196,"sourceCodeEnd":232,"githubUrl":"https://github.com/wavetermdev/waveterm/blob/a4447c1563b2df285ab89e76c82f91e1a1a49c1e/pkg/buildercontroller/buildercontroller.go#L196-L232","documentation":"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.","triggerScenarios":"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.","commonSituations":"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.","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"],"exampleFix":null,"handlingStrategy":"validation","validationCode":"if wavebase.GetWaveAppElectronExecPath() == \"\" {\n    return fmt.Errorf(\"cannot build: electron exec path not initialized\")\n}","typeGuard":null,"tryCatchPattern":"if err := runBuild(appId); err != nil {\n    if strings.Contains(err.Error(), \"electron executable path not set\") { /* re-init environment */ }\n}","preventionTips":["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"],"tags":["go","electron","environment"],"backgroundTag":"missing-env-var","analyzedSha":"a4447c1563b2df285ab89e76c82f91e1a1a49c1e","analyzedAt":"2026-09-01T15:26:23.972Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-08T10:18:20.063Z"}