Giter VIP home page Giter VIP logo

Comments (8)

lukastaegert avatar lukastaegert commented on June 21, 2024

That platform is well-supported, as a matter of fact I am using this platform right now. The error looks weird, however. Maybe your optional dependencies were not installed correctly. Try to delete your lock file and node_modules and try again. It could also be a problem with Nuxt.
The error looks like it installed the Intel binary instead of the Mac binary. If you recently migrated from an Intel Mac, again please delete node_modules and try again.

from rollup.

984035589 avatar 984035589 commented on June 21, 2024

I encountered a similar problem

from rollup.

sapphi-red avatar sapphi-red commented on June 21, 2024

I guess you are running Rosetta for npm and not using Rosetta for node.
FWIW esbuild has a specific error message for that.
https://github.com/evanw/esbuild/blob/109449e5b80886f7bc7fc7e0cee745a0221eef8d/lib/npm/node-platform.ts#L168-L192

from rollup.

PieterT2000 avatar PieterT2000 commented on June 21, 2024

To completely get rid of platform-dependencies for running rollup, install @rollup/wasm-node instead of @rollup/rollup-platform-X. This is also related to an npm bug with optionalDepedencies.

from rollup.

curran avatar curran commented on June 21, 2024

I'm working on a project that uses Rollup where different developers have different operating systems. I personally work on Linux, but other contributors work on OSX and Windows. In order for them to get the build to work, they need to install their OS-specific packages such as https://www.npmjs.com/package/@rollup/rollup-darwin-arm64, but if that gets added to package.json it breaks npm install for me on Linux.

What is the best practice to support a project that has Rollup as a dependency, and make it work without this friction for developers that have different operating systems?

I was hoping this information would be listed on this page, but unfortunately it is not:

https://www.npmjs.com/package/@rollup/rollup-darwin-arm64

Should it go in optionalDependencies?

https://docs.npmjs.com/cli/v10/configuring-npm/package-json#optionaldependencies

That's what I plan to try next.

from rollup.

lukastaegert avatar lukastaegert commented on June 21, 2024

They are optional dependencies of Rollup, so if things do not work without manual installation, it might be some bugginess in npm.

from rollup.

curran avatar curran commented on June 21, 2024

Interesting... Thanks for your thoughts on it! I wonder if a minimal reproduction would be useful to demonstrate this.

FWIW this is the package.json of the project where I'm experiencing this issue:

https://github.com/vizhub-core/vzcode/blob/main/package.json

I think rollup here is a transitive dependency of vite only. It's not a direct dependency.

I wonder if adding rollup as a direct dependency may solve the issue... Something to try!

from rollup.

curran avatar curran commented on June 21, 2024

I wonder if this may be an issue for Vite actually, not Rollup.

https://github.com/vitejs/vite/blob/main/packages/vite/package.json#L163

This is the sort of PRs I get, with additions for ESBuild and Rollup OS-specific packages.

image

from rollup.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.