next-issue 6.6.105 → 6.6.107
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 +1 -1
- package/dist/gate.mjs +13 -1
- package/dist/run-logs.mjs +2 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -573,7 +573,7 @@ because no pull request is opened.
|
|
|
573
573
|
| `agentTimeoutMinutes` | `30` | The limit for one agent call, at most `35791` |
|
|
574
574
|
| `setupTimeoutMinutes` | `15` | The limit for the setup command, at most `35791` |
|
|
575
575
|
| `commandTimeoutMinutes` | `10` | The limit for one `git` or `gh` command, at most `35791` |
|
|
576
|
-
| `logMaxChars` | `20000` | The maximum length of the failed job logs, shared between the failed
|
|
576
|
+
| `logMaxChars` | `20000` | The maximum length of the failed job logs, shared between the failed GitHub Actions runs (failed external checks are listed by name and link only) |
|
|
577
577
|
| `diffMaxChars` | `60000` | The maximum length of the diff that the reviewer reads |
|
|
578
578
|
| `keepRunDays` | `7` | The number of days to keep the run files; `0` keeps them all |
|
|
579
579
|
| `setupCommand` | from the lock file | A shell command to run in a new worktree, before the implementer |
|
package/dist/gate.mjs
CHANGED
|
@@ -16,7 +16,7 @@ export async function checkGate(job, sha) {
|
|
|
16
16
|
}
|
|
17
17
|
catch (error) {
|
|
18
18
|
if (job.mainBroken) {
|
|
19
|
-
return
|
|
19
|
+
return unreadFixChecks(job, error);
|
|
20
20
|
}
|
|
21
21
|
return unreadChecks(job, error);
|
|
22
22
|
}
|
|
@@ -141,6 +141,18 @@ async function unreadChecks(job, error) {
|
|
|
141
141
|
job.state.halted = true;
|
|
142
142
|
return escalateAndFinish(job, `The read of the checks on ${base} failed: ${sentence(message(error))} The landed commit is on \`${base}\`, and its checks were not awaited. ${HALT_NOTE}`, 'checks error');
|
|
143
143
|
}
|
|
144
|
+
/** A broken base whose checks cannot be read is reverted; while the revert fails, the halt stays saved. */
|
|
145
|
+
async function unreadFixChecks(job, error) {
|
|
146
|
+
if (runStopped()) {
|
|
147
|
+
throw error;
|
|
148
|
+
}
|
|
149
|
+
const { context, state } = job;
|
|
150
|
+
state.halted = true;
|
|
151
|
+
await writeState(context.repo, state);
|
|
152
|
+
const reverted = await revertOrReport(job);
|
|
153
|
+
const halt = state.halted === true ? ` ${HALT_NOTE}` : '';
|
|
154
|
+
return escalateAndFinish(job, `The read of the checks on ${context.base} failed: ${sentence(message(error))}${reverted}${halt}`, 'checks error');
|
|
155
|
+
}
|
|
144
156
|
export async function escalateError(job, error, note, reason) {
|
|
145
157
|
if (runStopped()) {
|
|
146
158
|
throw error;
|
package/dist/run-logs.mjs
CHANGED
|
@@ -2,7 +2,8 @@ import { succeeded } from './exec.mjs';
|
|
|
2
2
|
import { ghRun } from './gh.mjs';
|
|
3
3
|
import { joinFilled } from './text.mjs';
|
|
4
4
|
export async function runLogs(repo, failed, maxChars) {
|
|
5
|
-
const
|
|
5
|
+
const withLog = failed.filter(({ runId }) => runId !== undefined).length;
|
|
6
|
+
const share = Math.max(1, Math.floor(maxChars / Math.max(1, withLog)));
|
|
6
7
|
const parts = [];
|
|
7
8
|
for (const { heading, runId } of failed) {
|
|
8
9
|
parts.push(heading);
|