next-issue 7.8.2 → 7.8.3

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 CHANGED
@@ -105,6 +105,9 @@ the run handles one issue. For each issue:
105
105
  questions in order, numbered by the harness. The harness reads the issue
106
106
  again and adds the questions after any text under its `Open questions`
107
107
  heading, or adds that heading at the end of the body when it has none.
108
+ When that body edit fails, the harness records a `questions.body-failed`
109
+ event in the run log and still hands the issue over with the questions in
110
+ the comment.
108
111
  5. Let the reviewer agent judge the diff, at most `diffMaxChars` of it. The
109
112
  reviewer reads files and runs commands in the worktree, so it can prove a
110
113
  finding with the tests or the type check. The harness then throws away every
@@ -1,5 +1,6 @@
1
1
  import { parseCommitSubject, parseQuestions } from './agent-reply.mjs';
2
2
  import { CODING } from './agents.mjs';
3
+ import { message } from './errors.mjs';
3
4
  import { commitWork } from './fix.mjs';
4
5
  import { escalateAndFinish } from './handover.mjs';
5
6
  import { numbered, withOpenQuestions } from './issue-format.mjs';
@@ -27,11 +28,16 @@ export async function implement(job) {
27
28
  return ROUND_CONTINUE;
28
29
  }
29
30
  async function askQuestions(job, before, questions) {
30
- const { context, issue, worktree, branch } = job;
31
+ const { context, issue, log, worktree, branch } = job;
31
32
  const { repo, ports } = context;
32
33
  await ports.discardChanges(worktree, before, branch);
33
34
  const fresh = await ports.viewIssue(repo, issue.number);
34
- await ports.editIssueBody(repo, issue.number, withOpenQuestions(fresh.body, questions));
35
+ try {
36
+ await ports.editIssueBody(repo, issue.number, withOpenQuestions(fresh.body, questions));
37
+ }
38
+ catch (error) {
39
+ log.event('questions.body-failed', { error: message(error) }, 'quiet');
40
+ }
35
41
  return escalateAndFinish(job, `The implementer has questions about the issue.\n\n${numbered(questions)}`, 'questions');
36
42
  }
37
43
  async function useEarlierCommit(job) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "next-issue",
3
- "version": "7.8.2",
3
+ "version": "7.8.3",
4
4
  "description": "Autonomous issue harness driven by the pi SDK",
5
5
  "keywords": [
6
6
  "github",