mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-09-20 00:30:49 +00:00
Fix link to failed check report in status commit
This commit is contained in:
parent
f1c7665feb
commit
9021667f82
@ -242,12 +242,12 @@ def generate_status_comment(pr_info: PRInfo, statuses: CommitStatuses) -> str:
|
||||
for desc, gs in grouped_statuses.items():
|
||||
state = get_worst_state(gs)
|
||||
state_text = f"{STATUS_ICON_MAP[state]} {state}"
|
||||
# take the first target_url
|
||||
target_url = next(
|
||||
(status.target_url for status in gs if status.target_url), None
|
||||
)
|
||||
if target_url:
|
||||
state_text = f'<a href="{target_url}">{state_text}</a>'
|
||||
# take the first target_url with the worst state
|
||||
for status in gs:
|
||||
if status.target_url and status.state == state:
|
||||
state_text = f'<a href="{status.target_url}">{state_text}</a>'
|
||||
break
|
||||
|
||||
table_row = (
|
||||
f"<tr><td>{desc.name}</td><td>{desc.description}</td>"
|
||||
f"<td>{state_text}</td></tr>\n"
|
||||
|
Loading…
Reference in New Issue
Block a user