Skip to content

electron uninstall error #120

@ariaieboy

Description

@ariaieboy

What were you trying to do?

I am trying to run the dev env by running php artisan native:dev

What happened?

it shows me an error

How to reproduce the bug

I installed herd on windows.
updated the laravel installer and php
created a new site using laravel herd app.
installed nativephp and ran native:install command
then i ran native:run to run the dev env.

Debug Output

php artisan native:run -vvv

  Starting NativePHP dev server… 

 Fetching latest dependencies…

 Installing NPM dependencies (This may take a while)...

 Installing NPM dependencies using the npm package manager...


> laravel-dev@1.0.0 postinstall
> node ./node_modules/electron-builder/cli.js install-app-deps

  • electron-builder  version=26.8.1
  • executing @electron/rebuild  electronVersion=38.5.0 arch=x64 buildFromSource=false workspaceRoot=\Herd\v3\vendor\nativephp\desktop\resources\electron projectDir=./ appDir=./
  • installing native dependencies  arch=x64
  • completed installing native dependencies

up to date, audited 962 packages in 5s

204 packages are looking for funding
  run `npm fund` for details

26 vulnerabilities (1 low, 8 moderate, 16 high, 1 critical)

To address issues that do not require attention, run:
  npm audit fix

To address all issues (including breaking changes), run:
  npm audit fix --force

Run `npm audit` for details.

 Starting NativePHP app

 Running the dev script with npm...


> laravel-dev@1.0.0 dev
> cross-env node php.js && electron-vite dev --watch

Binary Source:  \Herd\v3\vendor\nativephp\php-bin\bin\win\x64\php-8.4.zip
Binary Filename:  php.exe
PHP version: 8.4
Unzipping PHP binary from \Herd\v3\vendor\nativephp\php-bin\bin\win\x64\php-8.4.zip to \Herd\v3\vendor\nativephp\desktop\resources\build\php
Copied PHP binary to  \Herd\v3\vendor\nativephp\desktop\resources\build\php\php.exe
vite v7.1.12 building SSR bundle for development...

watching for file changes...                                                                                                                                                                                                                                                   

build started...                                                                                                                                                                                                                                                               
transforming...
renderer and preload config is missing
✓ 37 modules transformed.
rendering chunks...
out/main/index.js  90.14 kB
built in 343ms.

build the electron main process successfully                                                                                                                                                                                                                                   
error during start dev server and electron app:
Error: Electron uninstall                                                                                                                                                                                                                                                      
    at getElectronPath (file:////Herd/v3/vendor/nativephp/desktop/resources/electron/node_modules/electron-vite/dist/chunks/lib-ClgyQuZx.js:132:19)                                                                                                              
    at startElectron (file:////Herd/v3/vendor/nativephp/desktop/resources/electron/node_modules/electron-vite/dist/chunks/lib-ClgyQuZx.js:205:26)                                                                                                                
    at createServer (file:////Herd/v3/vendor/nativephp/desktop/resources/electron/node_modules/electron-vite/dist/chunks/lib-B4dCEySN.js:74:14)                                                                                                                  
    at async CAC.<anonymous> (file:////Herd/v3/vendor/nativephp/desktop/resources/electron/node_modules/electron-vite/dist/cli.js:67:9)                                                                                                                          

 Command failed: 'npm run dev' (exit code 1)

Which operating systems have you seen this occur on?

Windows

Notes

I've tested with nodejs v22 and v26.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions