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

Effective coverage gate compares a floored percentage instead of the unrounded value

Đang mở
#17 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ó
3/5
Thời gian dự kiến
1-2 ngày
Mức phù hợp với người mới
78/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ệ
python
Lĩnh vực
testing-qa

Hướng nghiên cứu

Start with score_coverage/effective_coverage.py around the flooring logic and score_coverage/generate_coverage_html.py around the gate’s use of report.json. Reproduce the 99,999/100,000 case through the real generate_coverage_html CLI with and without the empty YAML, then add coverage for a threshold between the displayed and actual percentages. Done means both paths compare the unrounded value while displayed values remain floored.

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

Mô tả

bug

Found while reviewing the architecture documentation. Verified against upstream HEAD d99515b87bbe1dde89984403e9c330d640fc5d33 using synthetic report archives and the real generate_coverage_html CLI (no gate/justification mocks).

The effective gate reads summary.effective_line_coverage_pct from report.json, but that field is already floored to two decimal places. This can reject coverage that meets the configured threshold and makes an empty justification YAML change the gate verdict.

Reproduction

Use a report zip whose LLVM HTML Totals row and LCOV both contain 99,999 covered lines out of 100,000. Set COVERAGE_THRESHOLD=99.995.

  • Without YAML: raw 99.999%, exit 0.
  • With a valid YAML containing version: 1 and justifications: []: effective value stored as 99.99%, exit 1.

Both results were reproduced through the real CLI and effective coverage calculation with synthetic report inputs.

Expected

Both paths compare the unrounded percentage against the threshold. Display values may remain floored as required by the effective-report requirement. The gate should reconstruct its value from validated counts or receive a separate full-precision value.

This violates tool_req__coverage_gate_unrounded. Add coverage for a fractional threshold between the displayed and actual value, using an empty YAML to prove raw/effective parity.

Relevant code
Ngôn ngữ chính
Python
Star
0
Fork
3
Merge trung bình
18 giờ 24 phút
Pull request đã merge (30 ngày)
16

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

Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.

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 eclipse-score/coverage_tool

Tất cả issue của eclipse-score/coverage_tool

Issue tương tự

Thêm issue về Python

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.