GitHub release can attach to an existing tag on another commit

Đang mở Phù hợp với người mới
#94 0 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
72/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ệ
github, typescript
Lĩnh vực
devops, release

Hướng nghiên cứu

Đọc src/lib/github.ts để so sánh bước kiểm tra ref và SHA hiện có của createTag với createRelease, sau đó lần theo đường đi mặc định githubRelease: true trong src/release/index.ts. Xác nhận cách xử lý tag hiện có trỏ đến một commit khác và thêm bước kiểm tra hoặc tạo tag trước khi tạo release. Hoàn thành khi release thất bại hoặc dùng SHA mong đợi nếu tag đã trỏ đến commit khác.

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

Mô tả

bug
Issue description

createRelease (src/lib/github.ts) sends tag_name + target_commitish. When the tag already exists on another commit, GitHub ignores target_commitish and attaches the release to the existing tag, so the release silently points at the wrong commit. createTag checks that an existing tag is on the expected sha, but the default path (githubRelease: true, src/release/index.ts) never calls it.

Expected: before createRelease, check the tag like createTag does (getRef, compare the sha) and fail when it points elsewhere, or create the tag through createTag first.

Likelihood is low: the config checks prevent tag collisions between groups. A stale or hand-made tag still triggers it.

Found by the quality gate of the v3 rework, branch feat/v3-shared-workflows (commit 4617e86, not pushed yet when this was filed).

Code sample
_No response_
Versions
  • @nanoforge-dev/actions v3 (branch feat/v3-shared-workflows)
Issue priority

Low (slightly annoying)

I have tested this issue on a development release

No response

Ngôn ngữ chính
TypeScript
Star
0
Fork
0
Merge trung bình
15 giờ 51 phút
Pull request đã merge (30 ngày)
21

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 NanoForge-dev/actions

Tất cả issue của NanoForge-dev/actions

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.