File tree Expand file tree Collapse file tree 1 file changed +10
-8
lines changed
Expand file tree Collapse file tree 1 file changed +10
-8
lines changed Original file line number Diff line number Diff line change @@ -468,14 +468,16 @@ async def handle_pull_request_event(self, event: dict):
468468 return
469469
470470 if action == "labeled" :
471- if event ["label" ]["name" ] != CI_CONFIG .ready_label :
472- return
473- # Skip already queued jobs
474- if event ["label" ][
475- "name"
476- ] == CI_CONFIG .ready_label and self .queued .search_by_pr_number (
477- pull_request .number
478- ):
471+ # return if the ready label was set for an already queued job,
472+ # or if the label wouldn't change the job's priority (and thus
473+ # queue position).
474+ # otherwise, fall through to re-scheduling the job.
475+ label_name = event ["label" ]["name" ]
476+ if label_name == CI_CONFIG .ready_label :
477+ # Skip already queued jobs for ready label
478+ if self .queued .search_by_pr_number (pull_request .number ):
479+ return
480+ elif label_name not in config .priorities .labels .keys ():
479481 return
480482
481483 await self .schedule_job (job )
You can’t perform that action at this time.
0 commit comments