Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Continuous "Installing dependencies" after launching BabylonJS Editor v5.0.0 #486

Open
iHaiduk opened this issue Feb 8, 2025 · 4 comments
Labels

Comments

@iHaiduk
Copy link

iHaiduk commented Feb 8, 2025

Bug Report: Continuous "Installing dependencies" after launching BabylonJS Editor v5.0.0-alpha.7 (Apple Silicon)

Description:
After downloading and installing BabylonJS Editor v5.0.0-alpha.7 for Apple Silicon, the editor is stuck on "Installing dependencies". This prevents me from launching the project in live mode or working with the scene at all. Additionally, sometimes after closing a project, I get the following error:

Uncaught Exception:
TypeError: Object has been destroyed
at _.send (node:electron/js2c/browser_init:2:75233)
at /Applications/BabylonJS Editor.app/Contents/Resources/app.asar/build/src/electron/node-pty.js:46:19
at EventEmitter2.fire (/Applications/BabylonJS Editor.app/Contents/Resources/app.asar/node_modules/node-pty/lib/eventEmitter2.js:41:22)
at ReadStream.<anonymous> (/Applications/BabylonJS Editor.app/Contents/Resources/app.asar/node_modules/node-pty/lib/terminal.js:93:76)
at ReadStream.emit (node:events:519:28)
at Terminal.emit (/Applications/BabylonJS Editor.app/Contents/Resources/app.asar/node_modules/node-pty/lib/terminal.js:155:34)
at ReadStream.<anonymous> (/Applications/BabylonJS Editor.app/Contents/Resources/app.asar/node_modules/node-pty/lib/unixTerminal.js:93:27)
at Object.onceWrapper (node:events:634:26)
at ReadStream.emit (node:events:531:35)
at TTY.<anonymous> (node:net:339:12)

This error appears after closing the project, and it seems to be related to the destruction of an object that is still being referenced.

Expected Behavior:
After installation, I should be able to create a basic project and run or build it immediately without issues. After closing a project, no errors should occur.

Environment:

  • BabylonJS Editor Version: v5.0.0-alpha.7
  • Device: MacBook with M1 Pro
  • OS: macOS 15.3
  • Node.js: v22.13.1
  • npm: 10.9.2

Additional Information:

Steps to Reproduce:

  1. Download and install BabylonJS Editor v5.0.0-alpha.7 for Apple Silicon.
  2. Launch the editor.
  3. Try to create or open any project.
  4. Observe that the editor is stuck on "Installing dependencies".
  5. Close the project and observe the error message about the destroyed object.
@julien-moreau
Copy link
Contributor

Hi @iHaiduk !
Thanks a lot for the feedback!

I just pushed a fix that checks for availability of Node.js, Yarn and Visual Studio Code to update the UI in consequence: 4aa7367

Can you confirm that you did not install Node.js or Yarn that are required by the Editor? Else, if you have Node.js and Yarn installed the issue comes from something else and I still have to investiguate.

I'm using Yarn at the moment but I plan to add support of npm too.

@iHaiduk
Copy link
Author

iHaiduk commented Feb 12, 2025

Hi @julien-moreau !
Thanks for the update!

I can confirm that I have the following tools installed globally:

  • Node.js: v22.13.1
  • npm: 10.9.2
  • yarn: 4.6.0
  • bun: 1.2.2

As for the editor, besides downloading and launching it, I haven't done anything additional.

Let me know if you need any more info!

@iHaiduk
Copy link
Author

iHaiduk commented Feb 12, 2025

Maybe this will help you.
SCR-20250212-nwoe

> yarn install

Usage Error: The nearest package directory ($folder/Documents/projects/babylon) doesn't seem to be part of the project declared in $folder.

- If $folder isn't intended to be a project, remove any yarn.lock and/or package.json file there.
- If $folder is intended to be a project, it might be that you forgot to list Documents/projects/babylon in its workspace configuration.
- Finally, if $folder is fine and you intend Documents/projects/babylon to be treated as a completely separate project (not even a workspace), create an empty yarn.lock file in it.

$ yarn install [--json] [--immutable] [--immutable-cache] [--refresh-lockfile] [--check-cache] [--check-resolutions] [--inline-builds] [--mode #0]

@julien-moreau I found a fix for it. You just need to check and create an empty yarn.lock file before installing the dependencies.
On there:

const installProcess = await execNodePty("yarn install", {

@iHaiduk
Copy link
Author

iHaiduk commented Feb 12, 2025

I'm using Yarn at the moment but I plan to add support of npm too.

It would be great if you have support for npm or even Bun

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants