Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

maintainer review: a source matches no file when the node_modules exclude comes after it

Đã đóng Phù hợp với người mới
#301 1 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

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

Đánh giá

Độ khó
2/5
Thời gian dự kiến
1-3 giờ
Mức phù hợp với người mới
88/100
Loại issue
Lỗi
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
git, typescript
Lĩnh vực
cli, tooling

Hướng nghiên cứu

Bắt đầu trong phần triển khai review list(), nơi skill sources và dependencyExclude được truyền vào git ls-files. Chạy reproduction và maintainer check được cung cấp, sau đó xác minh rằng một source dưới packages/hooks/src vẫn khớp mặc dù node_modules bị loại trừ và hành vi của git diff không thay đổi.

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

Mô tả

In review, list() passes the skill sources before dependencyExclude. In that order, git ls-files returns nothing for most sources, so a valid source matches no file and maintainer check cannot pass.

git init -q repro && cd repro
mkdir -p packages/hooks/src packages/hooks/node_modules/dep
echo x > packages/hooks/src/index.ts
echo x > packages/hooks/node_modules/dep/index.js
echo node_modules > .gitignore
git add -A && git commit -qm init

X=':(top,exclude,glob)**/node_modules/**'
git ls-files -- ':(top,glob)packages/hooks/src/**' "$X"   # nothing
git ls-files -- "$X" ':(top,glob)packages/hooks/src/**'   # packages/hooks/src/index.ts

Same result on Git 2.43 (Ubuntu 24.04), 2.49 and 2.54, with @tanstack/intent 0.5.0. git diff is not affected.

Fix: pass dependencyExclude before the patterns in list().

Ngôn ngữ chính
TypeScript
Star
334
Fork
25
Merge trung bình
1 ngày 8 giờ
Pull request đã merge (30 ngày)
57

Chuẩn bị môi trường

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/intent

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

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.