Skip to content

Commit c34443b

Browse files
committed
#98: Pending status is not recognised
- added pending status
1 parent d7cc806 commit c34443b

File tree

3 files changed

+4
-3
lines changed

3 files changed

+4
-3
lines changed

dist/index.js

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/jsMain/kotlin/model/WorkflowRun.kt

+2-1
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ data class WorkflowRun(
1212

1313
enum class RunStatus(val value: String) {
1414
QUEUED("queued"),
15+
PENDING("pending"),
1516
IN_PROGRESS("in_progress"),
1617
COMPLETED("completed"),
1718
REQUESTED("requested"),
@@ -43,4 +44,4 @@ enum class RunConclusion(val value: String) {
4344
} ?: throw IllegalArgumentException("Cannot map unknown value '$v' to RunConclusion!")
4445
}
4546
}
46-
}
47+
}

src/jsMain/kotlin/usecases/WorkflowRuns.kt

+1-1
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ class WorkflowRuns(
106106
// if we have an external ref id we only can consider runs that have jobs (in_progress or completed)
107107
when (it.status) {
108108
RunStatus.IN_PROGRESS, RunStatus.COMPLETED -> true
109-
RunStatus.QUEUED, RunStatus.REQUESTED, RunStatus.WAITING -> false
109+
RunStatus.QUEUED, RunStatus.PENDING, RunStatus.REQUESTED, RunStatus.WAITING -> false
110110
}
111111
}.firstOrNull { run ->
112112
// normally here the job should never be null (ensured by updateRunDetails)

0 commit comments

Comments
 (0)