farm-fe / farm

Extremely fast Vite-compatible web build tool written in Rust
https://farmfe.org
MIT License
4.9k stars 161 forks source link

[Bug Report]: pnpm install fails to download @farmfe/core-linux-x64-musl in linux x64 #1514

Closed aha2mao closed 2 months ago

aha2mao commented 3 months ago

Steps to reproduce

  1. 使用一台 intel 架构 macbook (arm 没问题)
  2. 执行 docker build --progress=plain -t farm-linux --no-cache .

Reproduce link

https://github.com/aha2mao/Farm-x-linux/tree/0b362ef2518955a5fcfa7572b9cfab1ad96670fc

What is actually happening?

@farmfe/core-linux-x64-musl 没有被正常下载导致 farm build 报错: Error: Cannot find module 'afarmfe/core-linux-x64-musl'

System Info

System:
    OS: Linux 6.9 Alpine Linux
    CPU: (10) x64 unknown
    Memory: 6.66 GB / 7.75 GB
    Container: Yes
    Shell: 5.9 - /nix/orb/sys/bin/zsh
  Binaries:
    Node: 20.15.0 - /usr/local/bin/node
    npm: 10.7.0 - /usr/local/bin/npm
    pnpm: 8.15.5 - /usr/local/bin/pnpm
aha2mao commented 3 months ago

https://github.com/farm-fe/farm/blob/e5868afccd29e1a24ea5fd31d5f9e37c8bcac6bb/packages/core/npm/linux-x64-musl/package.json#L12

本地验证,上诉文件 libc 字段调整为 ["musl"] 即可正常下载,但不太明白具体原因

ErKeLost commented 2 months ago

fixed in 1.3.0