mirror of
https://github.com/sunnypilot/sunnypilot.git
synced 2026-09-15 04:23:43 +08:00
model_replay: skip report if no PR associated with the branch (#33866)
* no pr number * better * test * cleanup
This commit is contained in:
@@ -82,6 +82,12 @@ def comment_replay_report(proposed, master, full_logs):
|
||||
PR_BRANCH = os.getenv("GIT_BRANCH","")
|
||||
DATA_BUCKET = f"model_replay_{PR_BRANCH}"
|
||||
|
||||
try:
|
||||
GITHUB.get_pr_number(PR_BRANCH)
|
||||
except Exception:
|
||||
print("No PR associated with this branch. Skipping report.")
|
||||
return
|
||||
|
||||
files = generate_report(proposed, master, tmp)
|
||||
|
||||
GITHUB.upload_files(DATA_BUCKET, [(x[0], tmp + '/' + x[0]) for x in files])
|
||||
|
||||
Reference in New Issue
Block a user