Skip to content

Commit 2d45baa

Browse files
committed
More formatting fixes.
1 parent 15654cc commit 2d45baa

File tree

2 files changed

+18
-17
lines changed

2 files changed

+18
-17
lines changed

.ci/metrics/metrics.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,10 +150,11 @@ def _construct_aggregate(ag_name: str, job_list: list[JobMetrics]) -> AggregateM
150150
# Compute aggregate queue time (in seconds, not ns)
151151
ag_queue_time = (latest_start - earliest_create) / 1000000000
152152
# Append the aggregate metrics to the workflow metrics list.
153-
return AggregateMetric(
153+
return AggregateMetric(
154154
ag_name, ag_queue_time, ag_run_time, ag_status, latest_complete, ag_workflow_id
155155
)
156156

157+
157158
def create_and_append_libcxx_aggregates(workflow_metrics: list[JobMetrics]):
158159
"""Find libc++ JobMetric entries and create aggregate metrics for them.
159160

.ci/metrics/metrics_test.py

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ def test_create_and_append_aggregate_metric_1_stage(self):
100100
started_at_ns=1755697961000000000,
101101
completed_at_ns=1755698349000000000,
102102
workflow_id=3,
103-
workflow_name="Build and Test libc++"
103+
workflow_name="Build and Test libc++",
104104
),
105105
metrics.JobMetrics(
106106
"libcxx_stage1_test2",
@@ -111,7 +111,7 @@ def test_create_and_append_aggregate_metric_1_stage(self):
111111
started_at_ns=1755698060000000000,
112112
completed_at_ns=1755698417000000000,
113113
workflow_id=3,
114-
workflow_name="Build and Test libc++"
114+
workflow_name="Build and Test libc++",
115115
),
116116
metrics.JobMetrics(
117117
"libcxx_stage1_test3",
@@ -122,7 +122,7 @@ def test_create_and_append_aggregate_metric_1_stage(self):
122122
started_at_ns=1755697961000000000,
123123
completed_at_ns=1755698785000000000,
124124
workflow_id=3,
125-
workflow_name="Build and Test libc++"
125+
workflow_name="Build and Test libc++",
126126
),
127127
]
128128
metrics.create_and_append_libcxx_aggregates(test_metrics)
@@ -150,7 +150,7 @@ def test_create_and_append_aggregate_metric_multiple_workflow_ids(self):
150150
started_at_ns=1755697961000000000,
151151
completed_at_ns=1755698349000000000,
152152
workflow_id=3,
153-
workflow_name="Build and Test libc++"
153+
workflow_name="Build and Test libc++",
154154
),
155155
metrics.JobMetrics(
156156
"libcxx_stage1_test2",
@@ -161,7 +161,7 @@ def test_create_and_append_aggregate_metric_multiple_workflow_ids(self):
161161
started_at_ns=1755698060000000000,
162162
completed_at_ns=1755698417000000000,
163163
workflow_id=3,
164-
workflow_name="Build and Test libc++"
164+
workflow_name="Build and Test libc++",
165165
),
166166
metrics.JobMetrics(
167167
"libcxx_stage1_test3",
@@ -172,7 +172,7 @@ def test_create_and_append_aggregate_metric_multiple_workflow_ids(self):
172172
started_at_ns=1755697961000000000,
173173
completed_at_ns=1755698785000000000,
174174
workflow_id=25,
175-
workflow_name="Build and Test libc++"
175+
workflow_name="Build and Test libc++",
176176
),
177177
]
178178
metrics.create_and_append_libcxx_aggregates(test_metrics)
@@ -211,7 +211,7 @@ def test_create_and_append_aggregate_metric_3_stages(self):
211211
started_at_ns=1755697053000000000,
212212
completed_at_ns=1755698507000000000,
213213
workflow_id=17,
214-
workflow_name="Build and Test libc++"
214+
workflow_name="Build and Test libc++",
215215
),
216216
metrics.JobMetrics(
217217
"libcxx_stage1_test2",
@@ -222,7 +222,7 @@ def test_create_and_append_aggregate_metric_3_stages(self):
222222
started_at_ns=1755697058000000000,
223223
completed_at_ns=1755697885000000000,
224224
workflow_id=17,
225-
workflow_name="Build and Test libc++"
225+
workflow_name="Build and Test libc++",
226226
),
227227
metrics.JobMetrics(
228228
"libcxx_stage2_test1",
@@ -233,7 +233,7 @@ def test_create_and_append_aggregate_metric_3_stages(self):
233233
started_at_ns=1755698513000000000,
234234
completed_at_ns=1755699093000000000,
235235
workflow_id=17,
236-
workflow_name="Build and Test libc++"
236+
workflow_name="Build and Test libc++",
237237
),
238238
metrics.JobMetrics(
239239
"libcxx_stage2_test2",
@@ -244,7 +244,7 @@ def test_create_and_append_aggregate_metric_3_stages(self):
244244
started_at_ns=1755698514000000000,
245245
completed_at_ns=1755698987000000000,
246246
workflow_id=17,
247-
workflow_name="Build and Test libc++"
247+
workflow_name="Build and Test libc++",
248248
),
249249
metrics.JobMetrics(
250250
"libcxx_stage2_test3",
@@ -255,7 +255,7 @@ def test_create_and_append_aggregate_metric_3_stages(self):
255255
started_at_ns=1755698514000000000,
256256
completed_at_ns=1755699334000000000,
257257
workflow_id=17,
258-
workflow_name="Build and Test libc++"
258+
workflow_name="Build and Test libc++",
259259
),
260260
metrics.JobMetrics(
261261
"libcxx_stage3_test1",
@@ -266,7 +266,7 @@ def test_create_and_append_aggregate_metric_3_stages(self):
266266
started_at_ns=1755709012000000000,
267267
completed_at_ns=1755709931000000000,
268268
workflow_id=17,
269-
workflow_name="Build and Test libc++"
269+
workflow_name="Build and Test libc++",
270270
),
271271
metrics.JobMetrics(
272272
"libcxx_stage3_test2",
@@ -277,7 +277,7 @@ def test_create_and_append_aggregate_metric_3_stages(self):
277277
started_at_ns=1755709146000000000,
278278
completed_at_ns=1755709980000000000,
279279
workflow_id=17,
280-
workflow_name="Build and Test libc++"
280+
workflow_name="Build and Test libc++",
281281
),
282282
metrics.JobMetrics(
283283
"libcxx_stage3_test3",
@@ -288,7 +288,7 @@ def test_create_and_append_aggregate_metric_3_stages(self):
288288
started_at_ns=1755709136000000000,
289289
completed_at_ns=1755709514000000000,
290290
workflow_id=17,
291-
workflow_name="Build and Test libc++"
291+
workflow_name="Build and Test libc++",
292292
),
293293
]
294294
metrics.create_and_append_libcxx_aggregates(test_metrics)
@@ -341,7 +341,7 @@ def test_create_and_append_aggregate_metric_mixed_job_types(self):
341341
started_at_ns=1755697961000000000,
342342
completed_at_ns=1755698349000000000,
343343
workflow_id=3,
344-
workflow_name="Build and Test libc++"
344+
workflow_name="Build and Test libc++",
345345
),
346346
metrics.JobMetrics(
347347
"ci_test2", 3, 20, 1, 2000, 2200, 2400, 37, "premerge_test"
@@ -355,7 +355,7 @@ def test_create_and_append_aggregate_metric_mixed_job_types(self):
355355
started_at_ns=1755698060000000000,
356356
completed_at_ns=1755698417000000000,
357357
workflow_id=3,
358-
workflow_name="Build and Test libc++"
358+
workflow_name="Build and Test libc++",
359359
),
360360
metrics.JobMetrics(
361361
"ci_test3", 7, 35, 1, 3000, 3200, 3400, 85, "premerge_test"

0 commit comments

Comments
 (0)