eclipse-theia / generator-theia-extension

A Yeoman generator for extensions to the Theia IDE
Other
49 stars 37 forks source link

Scaffolding start error #170

Closed bad-github closed 1 year ago

bad-github commented 1 year ago

Bug Description:

I use the widget option of scaffolding to create a project, but it fails to run on the desktop

Steps to Reproduce:

1.yo theia-extension -t 1.34.4 2.I also added "main": "src-gen/frontend/electron-main.js" to electron-app/package.json 3.yarn watch && yarn start:electron image

Additional Information

vince-fugnitto commented 1 year ago

@gouych thank you for the discussion, I transferred the issue to the appropriate repository.

Can you try with the latest version of the generator (0.1.35)? Everything works fine for me, I point to the lib folder for the main entry:

"main": "lib/backend/electron-main.js",
msujew commented 1 year ago

@vince-fugnitto The issue seems to be about the latest community release (1.34.4), using the main entry you point out won't work.

@gouych Can you try the latest Theia release (1.39.0) as well? Just to narrow down whether it's an issue related to the community release or a general one.

bad-github commented 1 year ago

Everything works fine with the latest version. Is there a solution for version 1.34.4.

jfaltermeier commented 1 year ago

I am seeing issues with 1.39 in the electron-app as well, using the hello world template and the 0.1.35 generator. For me either changing prepare to rebuild before the actual build ("prepare": "theia rebuild:electron && theia build --mode development",) or adding "main": "src-gen/backend/electron-main.js", works.

Otherwise starting the electron app fails with Error: node-loader: Error: Module did not self-register: errors.

Steps to reproduce:

mkdir my-extension && cd my-extension
yo theia-extension
<Enter> (Hello World extension type)
<Enter> (hello-world extension name)
yarn start:electron
vince-fugnitto commented 1 year ago

Fixed by https://github.com/eclipse-theia/generator-theia-extension/pull/173.