@sjawhar/claude-envoy 2.6.0 → 2.7.1

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.
Files changed (28) hide show
  1. package/.claude-plugin/plugin.json +1 -1
  2. package/.omp-plugin/plugin.json +1 -1
  3. package/AGENTS.md +13 -3
  4. package/dist/dispatch.js +7498 -6764
  5. package/dist/envoy-channel.js +4998 -4223
  6. package/dist/session-hook.js +7523 -6789
  7. package/legion/skills/legion-architect/SKILL.md +1 -1
  8. package/legion/skills/legion-architect/references/acceptance.md +49 -52
  9. package/legion/skills/legion-architect/references/design-gate.md +4 -5
  10. package/legion/skills/legion-architect/references/wake-routing.md +7 -16
  11. package/legion/skills/legion-controller/SKILL.md +2 -2
  12. package/legion/skills/legion-controller/references/admission.md +4 -5
  13. package/legion/skills/legion-controller/references/backlog-stewardship.md +3 -4
  14. package/legion/skills/legion-controller/references/escalation.md +8 -7
  15. package/legion/skills/legion-controller/references/finding-asks.md +1 -1
  16. package/legion/skills/legion-controller/references/session.md +1 -1
  17. package/legion/skills/legion-controller/references/slack-mentions.md +1 -1
  18. package/legion/skills/legion-controller/references/triage.md +1 -1
  19. package/legion/skills/legion-controller/references/wakes.md +6 -4
  20. package/legion/skills/legion-retro/SKILL.md +13 -19
  21. package/legion/skills/legion-worker/SKILL.md +12 -8
  22. package/legion/skills/legion-worker/references/conflicts-and-rewrites.md +3 -3
  23. package/legion/skills/legion-worker/references/merge-gate.md +110 -151
  24. package/legion/skills/legion-worker/references/pr-body.md +15 -14
  25. package/legion/skills/legion-worker/references/review-threads.md +4 -4
  26. package/package.json +2 -2
  27. package/src/legion-phase-hook.ts +25 -11
  28. package/legion/skills/legion-architect/references/merge-notices.md +0 -104
@@ -2,5 +2,5 @@
2
2
  "name": "claude-envoy",
3
3
  "description": "Put Envoy events into the Claude Code session's own conversation and expose Envoy MCP tools.",
4
4
  "mcpServers": "./.mcp.json",
5
- "version": "2.6.0"
5
+ "version": "2.7.1"
6
6
  }
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "claude-envoy",
3
- "version": "2.6.0",
3
+ "version": "2.7.1",
4
4
  "description": "Put Envoy events into the Claude Code session's own conversation and expose Envoy MCP tools.",
5
5
  "mcpServers": {}
6
6
  }
package/AGENTS.md CHANGED
@@ -171,9 +171,19 @@ settles the machine: the first reminder of a run comes back as
171
171
  `{"decision":"block","reason":<the reminder>}`, which Claude Code turns into one more turn of the
172
172
  same session, and it is the only one of that run; every later one is written into the session over
173
173
  the bridge's inbox from a timer, because a line written while a turn runs is appended to that turn
174
- and the run would never settle for the daemon. `StopFailure` (the turn ended on an API error, and
175
- Claude Code ignores whatever the hook returns) settles with `canContinue: false`, so the machine
176
- arms that timer for the reminder instead. `PostToolUse` and `PostToolUseFailure` are the worker
174
+ and the run would never settle for the daemon. `StopFailure` runs instead of `Stop` when the turn
175
+ ended on an API error ("Hooks reference", code.claude.com/docs/en/hooks), and its
176
+ `${last_assistant_message}` is then the error text itself, not what the worker said: that is the
177
+ provider refusing the turn, so the machine takes it as `refused`: it earns no continuation, since
178
+ continuing into another turn at once would only buy another refusal, which is what left
179
+ dispatch://INFRA-264's implementer reminded for ever.
180
+ It does arm one timer, because the task that refused turn carried ended with it and nothing else
181
+ would wake this worker, so one transient refusal would leave the issue idle.
182
+ Claude Code ignores whatever this hook returns, which now costs nothing. What ends a session the provider keeps refusing is the daemon: the bridge reports each
183
+ turn's outcome to `POST /legion/v1/claims/turn-outcome` and the daemon fails the claim once the
184
+ trailing run of refusals reaches `launch_failure_limit`, and the runner's record check then drops
185
+ every reminder, since a failed claim is replaced by a retry in a session of its own.
186
+ `PostToolUse` and `PostToolUseFailure` are the worker
177
187
  working, which puts the count back to zero; a non-empty `${agent_id}` is a subagent's
178
188
  call and is ignored. `UserPromptSubmit` is this server's only sight of an inbound turn — the
179
189
  daemon's task reaches Claude Code's stdin from the bridge, never this process — so it declares the