ER: Blank PRs get commented on for formatting issues too

Đang mở Phù hợp với người mới
#8,871 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
67/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-actions, javascript
Lĩnh vực
ci-cd, tooling

Hướng nghiên cứu

Đọc ~/github-actions/trigger-pr/check-linked-issue.js, đặc biệt là dòng 105, nơi issue chỉ ra lỗi xảy ra khi pr.body để trống. Trước tiên, hãy kiểm tra cách action xử lý nội dung pull request và xem báo cáo lỗi được liên kết trong PR #8815; sử dụng các hướng dẫn kiểm thử GitHub Actions được cung cấp để chạy action trong môi trường cá nhân. Hoàn tất khi action xử lý được phần nội dung PR để trống và để lại bình luận như mong đợi.

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

Mô tả

Complexity: Small ER Feature: Refactor GHA Issue Making: Level 2 ready for merge team role: back end/devOps size: 0.25pt
Emergent Requirement - Problem

We should make sure that check-linked-issue.js can handle blank PRs as well. That code currently helps to check PRs for proper formatting to make sure an issue is linked, but it fails if the PR it is checking is blank.

Issue you discovered this emergent requirement in
  • #8815
Date discovered

10-24-2026

Did you have to do something temporarily
  • YES
  • NO
Who was involved

@castillios
@daras-cu

What happens if this is not addressed

If a blank PR get published, the PR to check for a a properly linked issue does not leave any comment on the PR to notify the author of an issue.

Resources
Recommended Action Items
  • Make a new issue
  • Discuss with team
  • Let a Team Lead know
Potential solutions [draft]

Issue:

  • Complexity: Small (While the suggested change here only requires changing one line of code, I gave it the Complexity: Small label because it requires testing GitHub Actions.)
  • Relationships: None
  • Size: 0.25pt
  • Fix:
    in ~/github-actions/trigger-pr/check-linked-issue.js (line 105), change:
const match = pr.body.match(regex); 

... to:

const match = (pr.body ?? '').match(regex);
Ngôn ngữ chính
JavaScript
Star
365
Fork
872
Merge trung bình
8 ngày 19 giờ
Pull request đã merge (30 ngày)
2

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 hackforla/website

Tất cả issue của hackforla/website

Issue tương tự

Thêm issue về JavaScript

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.