Improve error message when Milestone does not exist in redmine.
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
- 45/100
Hướng nghiên cứu
Start in .github/workflows/scripts/release.py, especially validate_and_update_redmine_data at lines 61-66, and read the traceback to understand the missing-milestone path. Confirm the behavior when redmine_issue.fixed_version is unavailable. Done means the script reports "Couldn't find milestone x.y.z" instead of producing the ResourceAttrError and UnboundLocalError traceback.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Instead of producing a traceback like below, a proper error message should state "Couldn't find milestone x.y.z".
Repo path: /home/runner/work/pulp-certguard/pulp-certguard
Traceback (most recent call last):
File ".github/workflows/scripts/release.py", line 61, in validate_and_update_redmine_data
issue_milestone = redmine_issue.fixed_version
File "/opt/hostedtoolcache/Python/3.7.10/x64/lib/python3.7/site-packages/redminelib/resources/standard.py", line 152, in __getattr__
return super(Issue, self).__getattr__(attr)
File "/opt/hostedtoolcache/Python/3.7.10/x64/lib/python3.7/site-packages/redminelib/resources/base.py", line 197, in __getattr__
raise exceptions.ResourceAttrError
redminelib.exceptions.ResourceAttrError: Resource doesn't have the requested attribute
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File ".github/workflows/scripts/release.py", line 288, in <module>
release_commit_sha = create_release_commits(repo, release_version, plugin_path)
File ".github/workflows/scripts/release.py", line 132, in create_release_commits
redmine_final_query, issues_to_close, release_version
File ".github/workflows/scripts/release.py", line 66, in validate_and_update_redmine_data
redmine.issue.update(redmine_issue.id, fixed_version_id=milestone.id)
UnboundLocalError: local variable 'milestone' referenced before assignment```
- Ngôn ngữ chính
- Python
- Star
- 10
- Fork
- 40
- Merge trung bình
- 8 giờ 59 phút
- Pull request đã merge (30 ngày)
- 5
Chuẩn bị môi trường
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- 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.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của pulp/plugin_template
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
pulp/plugin_template#724 · 1 bình luận ·
-
stale
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
pulp/plugin_template#444 · 1 bình luận · 1 reaction ·
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 45/100
pulp/plugin_template#1040 · 1 bình luận ·
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 45/100
pulp/plugin_template#1027 · 4 bình luận ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 55/100
pulp/plugin_template#973 ·
Tất cả issue của pulp/plugin_template
Issue tương tự
-
bug status/needs-triage
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 86/100
prowler-cloud/prowler#12887 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
area: desktop platform: macos priority: p3 status: ready type: enhancement
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 92/100
use-agent-os/agent-os#3484 ·
Maintainer thường phản hồi trong vòng 2 ngày
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 86/100
open-telemetry/opentelemetry-python-contrib#5113 · 2 bình luận · 2 reaction ·
Maintainer thường phản hồi trong vòng 1 ngày
-
external
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
langchain-ai/docs#6255 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
Maintainer thường phản hồi trong vòng 1 ngày