File tree Expand file tree Collapse file tree 1 file changed +2
-15
lines changed Expand file tree Collapse file tree 1 file changed +2
-15
lines changed Original file line number Diff line number Diff line change 6868 EOF
6969
7070 read-events :
71+ name : read-events-${{ matrix.worker }}
7172 needs : process-events
7273 runs-on : ubuntu-latest
7374 environment : nemo-ci
@@ -134,25 +135,11 @@ jobs:
134135 response = requests.get(url, headers=headers)
135136 if response.status_code == 200:
136137 jobs = response.json()['jobs']
137- current_job = None
138-
139- # Find current job by matrix variables
140- for job in jobs:
141- if (job['name'].startswith('read-events') and
142- 'matrix' in job and
143- 'worker' in job['matrix'] and
144- str(job['matrix']['worker']) == current_worker):
145- current_job = job
146- break
147-
148- if not current_job:
149- print(f"Could not find current job for worker {current_worker}")
150- return
151138
152139 # Cancel other read-events jobs
153140 for job in jobs:
154141 if (job['name'].startswith('read-events') and
155- job['id '] != current_job['id'] and
142+ job['name '] != f"read-events-{current_worker}" and
156143 job['status'] in ['queued', 'in_progress']):
157144 cancel_url = f"{url}/{job['id']}/cancel"
158145 cancel_response = requests.post(cancel_url, headers=headers)
You can’t perform that action at this time.
0 commit comments