Skip to content

Commit 527fb81

Browse files
author
Vitaliy Zakaznikov
committed
Fixing imports.
1 parent ea66f3b commit 527fb81

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

testflows/github/hetzner/runners/metrics.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,8 @@
1717
import logging
1818
from datetime import datetime
1919

20-
from github.WorkflowRun import WorkflowRun, WorkflowRunJob
20+
from github.WorkflowRun import WorkflowRun
21+
from github.WorkflowJob import WorkflowJob
2122
from prometheus_client import Counter, Gauge, Histogram, Info
2223
from .estimate import get_server_price
2324
from .constants import standby_server_name_prefix, recycle_server_name_prefix
@@ -657,7 +658,7 @@ def update_runners(
657658
).set(count)
658659

659660

660-
def update_jobs(run_jobs: list[(WorkflowRun, WorkflowRunJob)]):
661+
def update_jobs(run_jobs: list[(WorkflowRun, WorkflowJob)]):
661662
"""Update all job-related metrics."""
662663
queued_count = 0
663664
running_count = 0

testflows/github/hetzner/runners/scale_up.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -370,7 +370,7 @@ def job_matches_labels(job_labels, with_label):
370370
return True
371371

372372

373-
def filtered_run_jobs(workflow_runs, with_label):
373+
def filtered_run_jobs(workflow_runs: list[WorkflowRun], with_label: list[str]):
374374
"""Filter jobs to select only queued or in progress and match with_label criteria."""
375375
run_jobs = []
376376
for run in workflow_runs:

0 commit comments

Comments
 (0)