pnpm install + pnpm dev fails out of the box on Linux (esbuild + lightningcss)

Đang mở
#394 1 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
35/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Ít trao đổi
Công nghệ
linux, node.js, react, typescript

Hướng nghiên cứu

Bắt đầu bằng cách tái hiện lệnh scaffold được ghi trong tài liệu trên Linux với các phiên bản Node và pnpm được liệt kê, sau đó kiểm tra các dependency của project được tạo và entry point của dev-server. So sánh quy trình cài đặt bằng pnpm với workaround bằng npm đã được báo cáo, đồng thời xác minh rằng một scaffold mới có thể được cài đặt và khởi động bằng pnpm mà không gặp bất kỳ lỗi native-module nào trong hai lỗi đó.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Which project does this relate to?

Create Tanstack App

Describe the bug

A freshly scaffolded TanStack Start project fails immediately with two consecutive
errors when using pnpm on Linux. No modifications were made to the project.

Your Example Website or App

Fresh scaffold via: pnpm create @tanstack/start@latest No modifications made. Reproducible on any Linux x64 machine with pnpm.

Steps to Reproduce the Bug or Issue
  1. pnpm create @tanstack/start@latest
  2. cd
  3. pnpm install
  4. pnpm dev
Expected behavior

The dev server starts successfully after a fresh install.

Screenshots or Videos

No response

Platform
  • OS: Linux x64 (Ubuntu)
  • Node: v22.22.0
  • pnpm: v10.30.1
  • @tanstack/react-start: 1.162.4
Additional context

Two errors occur in sequence:

Error 1 — esbuild postinstall fails:
The scaffold pins esbuild@0.27.3 directly in dependencies. This version has a
broken postinstall script that fails with:
Error: Expected "0.27.3" but got ""

Error 2 — lightningcss native binary missing (after removing esbuild from
dependencies):
pnpm's strict symlinking means lightningcss-linux-x64-gnu binary never gets
linked into lightningcss's node/ directory:
Error: Cannot find module '../lightningcss.linux-x64-gnu.node'

Workaround: using npm install instead of pnpm works without issues.

Ngôn ngữ chính
TypeScript
Star
1.3k
Fork
185
Merge trung bình
18 giờ 45 phút
Pull request đã merge (30 ngày)
2

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của TanStack/cli

Tất cả issue của TanStack/cli

Issue tương tự

Thêm issue về TypeScript

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.