@volter/supercode-orchestrator 0.4.41 → 0.4.43

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.
@@ -94,7 +94,7 @@ export function scopeOf(db, board, task, { params, event = {}, extra = {} } = {}
94
94
  goal_mode: Boolean(task.goal_mode),
95
95
  implementer: asked.implementer ?? task.assignee,
96
96
  last_reviewer: changes.reviewer ?? null,
97
- arc: task.subtask_of ? one(db, 'SELECT id, status, title, assignee FROM tasks WHERE id = ?', task.subtask_of) ?? null : null,
97
+ arc: task.subtask_of ? one(db, 'SELECT id, status, title, body, assignee FROM tasks WHERE id = ?', task.subtask_of) ?? null : null,
98
98
  // the cards filed as its subtasks (`create --subtask-of`), in the order they were filed
99
99
  subtasks: all(db, 'SELECT t.id, t.status, t.title, t.assignee FROM tasks t JOIN supercode_cards c ON c.task_id = t.id WHERE c.subtask_of = ? ORDER BY t.created_at', task.id),
100
100
  queue_reason: json(one(db, "SELECT payload FROM task_events WHERE task_id = ? AND kind = 'respawn_guarded' AND created_at >= ? ORDER BY id DESC LIMIT 1",
package/loop.mjs CHANGED
@@ -586,6 +586,14 @@ export class Orchestrator {
586
586
  try {
587
587
  await runtime.sendInput(input);
588
588
  } catch (error) {
589
+ // A turn the harness is still running (one this loop did not start, or whose end it has not heard yet) is not a
590
+ // dead session: the line waits for that turn's end, as a refused steer does. Ending the binding on it killed a
591
+ // live lobby manager on the first message that reached it mid-turn.
592
+ if (/already in progress/.test(error.message)) {
593
+ this.log('info', `send ${keyString}: a turn is in progress; the line waits for its end`);
594
+ this.enqueue(events.worker({ profile, keyString, runtime_id: runtime.handle.runtime_id, ev: { kind: 'steer_refused', text: input }, at: this.clock() }));
595
+ return;
596
+ }
589
597
  this.enqueue(events.worker({ profile, keyString, runtime_id: runtime.handle.runtime_id, ev: { kind: 'error', message: `send failed: ${error.message}` }, at: this.clock() }));
590
598
  }
591
599
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@volter/supercode-orchestrator",
3
- "version": "0.4.41",
3
+ "version": "0.4.43",
4
4
  "type": "module",
5
5
  "description": "The orchestrator runtime over the Volter Harness ontology: one typed operational model whose folder is its serialization, read and written through the harness orchestration doors (docs/ORCHESTRATOR-IR.md)",
6
6
  "exports": {