generator-ui5-project icon indicating copy to clipboard operation
generator-ui5-project copied to clipboard

Error in generating sapui5 project using node 20

Open satyadwivedi opened this issue 1 year ago • 11 comments

Easy-Ui5 version:

Run yo easy-ui5 --plugins to print all relevant version strings image

Steps to reproduce the problem:

  1. Step 1 - yo easy-ui5 project
  2. Step 2 - choose project

What is the expected result?

Cannot find package 'chalk' imported from /Users/satyadwivedi/.npm/_generator-easy-ui5/plugin-generators/generator-ui5-project/generators/project/index.js Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'chalk' imported from /Users/satyadwivedi/.npm/_generator-easy-ui5/plugin-generators/generator-ui5-project/generators/customcontrol/index.js at new NodeError (node:internal/errors:406:5) at packageResolve (node:internal/modules/esm/resolve:789:9) at moduleResolve (node:internal/modules/esm/resolve:838:20) at defaultResolve (node:internal/modules/esm/resolve:1043:11) at ModuleLoader.defaultResolve (node:internal/modules/esm/loader:383:12) at ModuleLoader.resolve (node:internal/modules/esm/loader:352:25) at ModuleLoader.getModuleJob (node:internal/modules/esm/loader:228:38) at ModuleWrap. (node:internal/modules/esm/module_job:85:39) at link (node:internal/modules/esm/module_job:84:36) Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'chalk' imported from /Users/satyadwivedi/.npm/_generator-easy-ui5/plugin-generators/generator-ui5-project/generators/customcontrol/index.js

Any other information? (attach screenshot if possible)

image

satyadwivedi avatar Sep 29 '24 09:09 satyadwivedi

Hi @satyadwivedi, can you check if the npm install in your local directory of the generator-ui5-project was successful - do the node_modules exist?

nicoschoenteich avatar Sep 30 '24 11:09 nicoschoenteich

yes, node_modules exist image

satyadwivedi avatar Sep 30 '24 15:09 satyadwivedi

Hi @satyadwivedi, sorry, I should have been more clear. I meant in the /Users/satyadwivedi/.npm/_generator-easy-ui5/plugin-generators/generator-easy-ui5/ directory, not the newly created project directory.

nicoschoenteich avatar Sep 30 '24 15:09 nicoschoenteich

image

generator-easy-ui5 dosen't exist

satyadwivedi avatar Oct 01 '24 06:10 satyadwivedi

Whoops, the generator-ui5-project/ I mean (inside plugin-generators/).

nicoschoenteich avatar Oct 01 '24 10:10 nicoschoenteich

generator-ui5-projec exist inside plugin-generators/

image

satyadwivedi avatar Oct 01 '24 16:10 satyadwivedi

Does it contain node_modules?

nicoschoenteich avatar Oct 02 '24 09:10 nicoschoenteich

I can't node_modules inside generator-ui5-project folder.

Image

satyadwivedi avatar Oct 03 '24 06:10 satyadwivedi

Can you run npm install in .../generator-ui5-project and see if that fixes the issue?

nicoschoenteich avatar Oct 06 '24 09:10 nicoschoenteich

now I can see the node_modules Image

but different error this time - Image

satyadwivedi avatar Oct 07 '24 16:10 satyadwivedi

Can you try to delete the /Users/satyadwivedi/.npm/_generator-easy-ui5/plugin-generators/generator-ui5-project/ and run the initial command again?

nicoschoenteich avatar Oct 14 '24 09:10 nicoschoenteich