feat: hide empty stages (#44)

Co-authored-by: BoYanZh <boyanzh233@gmail.com>
This commit is contained in:
mQzLjP 2024-10-10 15:24:18 +08:00 committed by GitHub
parent 6888ce51d9
commit bc73b17abd
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -197,6 +197,11 @@ def generate_title_and_comment(
) )
for stage in stages: for stage in stages:
comment += f"## {stage['name']}" comment += f"## {stage['name']}"
if all(
result["score"] == 0 and result["comment"].strip() == ""
for result in stage["results"]
):
continue
force_quit = stage["force_quit"] force_quit = stage["force_quit"]
if force_quit: if force_quit:
comment += " - Failed" comment += " - Failed"