Build fails due to ESM require error in rollup-plugin-visualizer #7572
-
What happened?I'm trying to Install LibreChat Locally Using npm and I’m encountering an error during the build step. Version InformationSteps to Reproduce
Output:During the
What browsers are you seeing the problem on?No response Relevant log outputNo logs are available since it failed at build step ScreenshotsCode of Conduct
|
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 1 reply
-
Make sure you are using node ^20.19.0 |
Beta Was this translation helpful? Give feedback.
-
@danny-avila Thanks for the response! Just to clarify, I’m using Node.js version 22.2.0. |
Beta Was this translation helpful? Give feedback.
-
@danny-avila Thank you! I switched to Node.js v20.19.2 using nvm, and it's working now. Really appreciate your work wishing you all the best! |
Beta Was this translation helpful? Give feedback.
I can't speak to that version of node. You can try using
nvm
to manage different node versions, then try the recommended one. I'm not having issues with node v20.19.0 locally and the container image build is succeeding:https://github.com/danny-avila/LibreChat/actions/runs/15245697300/job/42872086848
also, try
npm run reinstall
when using node ^20.19.0