next-issue 6.6.44 → 6.6.45
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +14 -11
- package/dist/base-checks.mjs +2 -2
- package/dist/watch.mjs +3 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -134,17 +134,20 @@ the run handles one issue. For each issue:
|
|
|
134
134
|
holds the commit during the push, so a run stopped meanwhile, or the
|
|
135
135
|
next run after that hand-over, checks the base on resume and waits for
|
|
136
136
|
the checks of the commit when it landed. The harness then waits for the
|
|
137
|
-
checks of the pushed commit on the base branch:
|
|
138
|
-
workflow runs
|
|
139
|
-
GitHub App, so checks from another CI
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
that
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
137
|
+
checks of the pushed commit on the base branch: the GitHub Actions
|
|
138
|
+
workflow runs that a `push` event started on it, its commit statuses
|
|
139
|
+
and the check runs of every other GitHub App, so checks from another CI
|
|
140
|
+
service count too. It leaves out the check runs of the GitHub Actions
|
|
141
|
+
app, since it judges GitHub Actions by its workflow runs. It leaves out
|
|
142
|
+
workflow runs that any other event (such as `issues`, `issue_comment` or
|
|
143
|
+
`schedule`) started, since GitHub gives such a run the tip of the
|
|
144
|
+
default branch as its commit. A failed or errored commit status, or a
|
|
145
|
+
check run that ends with `failure`, `timed_out` or `action_required`,
|
|
146
|
+
fails the checks. When any check ends `cancelled`, for example because
|
|
147
|
+
a later push cancelled the workflow run, that check never finished,
|
|
148
|
+
even when another check (such as a release workflow) ends `success`:
|
|
149
|
+
the harness hands the issue to a person with the reason
|
|
150
|
+
`main checks cancelled` and halts, and the issue stays open. A repository
|
|
148
151
|
that reports no check keeps asking for `checkGraceSeconds`. A pending state
|
|
149
152
|
waits again, up to `checkTimeoutMinutes`. A read that fails is tried three
|
|
150
153
|
times. When the checks pass, the harness closes the issue and sets
|
package/dist/base-checks.mjs
CHANGED
|
@@ -14,8 +14,8 @@ function jsonLines(raw) {
|
|
|
14
14
|
.map((line) => JSON.parse(line));
|
|
15
15
|
}
|
|
16
16
|
async function baseRuns(repo, sha) {
|
|
17
|
-
const runs = await ghApi(repo, `actions/runs?head_sha=${sha}&per_page=100`, '.workflow_runs[] | {databaseId: .id, name, status, conclusion: (.conclusion // ""), attempt: .run_attempt} | @json', { paginate: true });
|
|
18
|
-
return jsonLines(runs);
|
|
17
|
+
const runs = await ghApi(repo, `actions/runs?head_sha=${sha}&per_page=100`, '.workflow_runs[] | {databaseId: .id, name, status, conclusion: (.conclusion // ""), attempt: .run_attempt, event} | @json', { paginate: true });
|
|
18
|
+
return jsonLines(runs).filter((entry) => entry.event === 'push');
|
|
19
19
|
}
|
|
20
20
|
async function externalChecks(repo, sha) {
|
|
21
21
|
const [runs, statuses] = await Promise.all([
|
package/dist/watch.mjs
CHANGED
|
@@ -50,6 +50,9 @@ async function huntIssues(hunter, running, failed, claims, stopped, signal) {
|
|
|
50
50
|
let step = 0;
|
|
51
51
|
while (!stopped()) {
|
|
52
52
|
const ready = await hunter.ready(running, failed).catch(() => undefined);
|
|
53
|
+
if (stopped()) {
|
|
54
|
+
return;
|
|
55
|
+
}
|
|
53
56
|
claims.take();
|
|
54
57
|
const waiting = ready?.filter((issue) => !running.has(issue.number)).length;
|
|
55
58
|
if (waiting !== undefined && waiting < hunter.cap) {
|