You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Bug arises on M3 Pro max mac - during installation of Chainlit project following first step of CONTRIBUTING.md
poetry install --with tests --with mypy --with dev
Installing dependencies from lock file
No dependencies to install or update
Installing the current project: chainlit (2.0.3)Preparing build environment with build-system requirements poetry-core==1.9.1
-- Building frontend, this might take a while!
If you don't need to build the frontend and just want dependencies installed, use:
`poetry install --no-root`
-- Running: /Users/ishaansehgal/Library/pnpm/pnpm install --frozen-lockfile
Scope: all 4 workspace projects
Already up to date
Done in 60ms
-- Running: /Users/ishaansehgal/Library/pnpm/pnpm buildUi
> @ buildUi /Users/ishaansehgal/Documents/chainlit
> cd libs/react-client && pnpm run build && cd ../copilot && pnpm run build && cd ../../frontend && pnpm run build
> @chainlit/[email protected] build /Users/ishaansehgal/Documents/chainlit/libs/react-client
> tsup src/index.ts --clean --format esm,cjs --dts --external react --external recoil --minify --sourcemap --treeshake
Error: Cannot find module @rollup/rollup-darwin-x64. npm has a bug related to optional dependencies (https://github.com/npm/cli/issues/4828). Please try `npm i` again after removing both package-lock.json and node_modules directory.
at requireWithFriendlyError (/Users/ishaansehgal/Documents/chainlit/libs/react-client/node_modules/.pnpm/[email protected]/node_modules/rollup/dist/native.js:59:9)
at Object.<anonymous> (/Users/ishaansehgal/Documents/chainlit/libs/react-client/node_modules/.pnpm/[email protected]/node_modules/rollup/dist/native.js:68:76)
at Module._compile (node:internal/modules/cjs/loader:1364:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1422:10)
at Module.load (node:internal/modules/cjs/loader:1203:32)
at Module._load (node:internal/modules/cjs/loader:1019:12)
at Module.require (node:internal/modules/cjs/loader:1231:19)
at require (node:internal/modules/helpers:177:18)
at Object.<anonymous> (/Users/ishaansehgal/Documents/chainlit/libs/react-client/node_modules/.pnpm/[email protected]/node_modules/rollup/dist/shared/parseAst.js:12:19)
at Module._compile (node:internal/modules/cjs/loader:1364:14)
ELIFECYCLE Command failed with exit code 1.
ELIFECYCLE Command failed with exit code 1.
Solution is after cloning to do
rm -rf node_modules
rm -rf libs/*/node_modules
rm -rf frontend/node_modules
# Remove lock files
rm -rf pnpm-lock.yaml
rm -rf package-lock.json
rm -rf yarn.lock
pnpm store prune
pnpm cache delete
Install a specific version of Rollup that's known to work with M1/M2 Macs:
pnpm add -D [email protected]
# Try building again
pnpm install
pnpm buildUi
Screenshots
The text was updated successfully, but these errors were encountered:
Thanks for the feedback @ishaansehgal99. Could you provide a reference to which version(s) of rollup will or will not work? We can upgrade the deps and/or are happy to accept a PR.
Describe the bug
Bug arises on M3 Pro max mac - during installation of Chainlit project following first step of
CONTRIBUTING.md
Screenshots
The text was updated successfully, but these errors were encountered: