next-issue 7.8.9 → 7.8.10
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 +4 -1
- package/dist/local-checks.mjs +3 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -161,7 +161,10 @@ the run handles one issue. For each issue:
|
|
|
161
161
|
`merge conflict`. When `checks` lists commands, the harness then runs
|
|
162
162
|
each one in the worktree, in order, with `bash -c` and stderr merged
|
|
163
163
|
into stdout, each for at most `checksTimeoutMinutes`. Their output goes
|
|
164
|
-
to the run log (`check.output`, and `check.fail` for a failure).
|
|
164
|
+
to the run log (`check.output`, and `check.fail` for a failure). After
|
|
165
|
+
each command, the harness resets the worktree to the commit it checked
|
|
166
|
+
and removes untracked files that git does not ignore, so a file that a
|
|
167
|
+
command writes never lands on the base. A
|
|
165
168
|
command that fails or does not finish stops the landing before the push:
|
|
166
169
|
the fixer gets the command and the tail of its output (at most
|
|
167
170
|
`logMaxChars`) from the check budget, `maxCiFixes`, and its fix is
|
package/dist/local-checks.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { budgetUse, refundBudget, refundOnKill } from './budget.mjs';
|
|
2
|
-
import { refuseWhenStopped, runStopped } from './children.mjs';
|
|
2
|
+
import { evenWhenStopped, refuseWhenStopped, runStopped } from './children.mjs';
|
|
3
3
|
import { minutesToMs } from './durations.mjs';
|
|
4
4
|
import { succeeded } from './exec.mjs';
|
|
5
5
|
import { escalateCheckFix, fixRound } from './fix.mjs';
|
|
@@ -15,8 +15,10 @@ const COMMENT_OUTPUT_CHARS = 3000;
|
|
|
15
15
|
export async function localChecks(job) {
|
|
16
16
|
const { context, log, worktree } = job;
|
|
17
17
|
const { config, ports } = context;
|
|
18
|
+
const head = await ports.revision(worktree);
|
|
18
19
|
for (const command of config.checks) {
|
|
19
20
|
const result = await log.step('check', { cmd: command }, () => ports.runCheck(command, worktree, minutesToMs(config.checksTimeoutMinutes), config.logMaxChars));
|
|
21
|
+
await evenWhenStopped(() => ports.discardChanges(worktree, head));
|
|
20
22
|
// A stop kills the command, so its failure is no finding: the next run checks again.
|
|
21
23
|
refuseWhenStopped();
|
|
22
24
|
log.event('check.output', { cmd: command, code: result.code, timedOut: result.timedOut, output: result.output }, 'verbose');
|