Repository navigation
Description
Bug Description
A kanban task created with --initial-status blocked is automatically promoted to
ready roughly 1 second after creation, with no actor recorded on the
transition and no operator action. The task is then claimed and executed by the
default worker.
In our deployment, blocked is used as a human approval gate: an automated
maintenance pipeline files recommended mutations as blocked tasks, and a human is
supposed to be the only thing that moves them to ready (authorization = execution).
Because blocked tasks self-promote, that gate is bypassed entirely. On 2026-06-04 this
caused un-reviewed mutations to execute on a production host with no human in the
loop. The concrete damage: a task body ran uv pip install pytest==2.7.0, which
downgraded pytest to 2.7.0 in the live service venv at 23:32:52 and left it unable
to import (py 1.11.0 too old). A second un-reviewed task ran a Hermes "promotion"
against the live install. Neither was ever authorized.
This appears related to the guarantee in #24699 (closing comment / PR #28712),
which states that worker-initiated blocks are NOT auto-promoted and remain blocked
until an operator moves them. That guarantee appears to hold for worker-initiated
blocks, but is bypassed for tasks created directly in the blocked state via
--initial-status blocked: those are auto-promoted within ~1s.
Steps to Reproduce
- Ensure the dashboard service is running (
hermes dashboard), gateway dispatch may
be off (kanban.dispatch_in_gateway: false). - Create a task already in the blocked state:
hermes kanban create "ASSENT: example gated action" --initial-status blocked - Immediately watch the task's events:
hermes kanban show <task_id> # or: hermes kanban tail <task_id> - Observe a
promotedevent ~1 second aftercreated, with no operator unblock and
no actor in the event payload, followed by the worker claiming and running the task.
Expected Behavior
A task created with --initial-status blocked stays blocked until an explicit,
attributed operator action (dashboard unblock / kanban unblock) moves it to
ready — matching the #24699 / PR #28712 guarantee for worker-initiated blocks. Every
status transition should record the actor that performed it.
Actual Behavior
The task is auto-promoted blocked → ready ~1s after creation, with an empty event
payload (no actor), then claimed and run by the default worker. The run completes in 0s
with no claim/started lifecycle event and no command log, marking the task done
(including one whose own summary reports the action failed).
Affected Component
Other
Messaging Platform (if gateway-related)
No response
Debug Report
⚠️ This will upload the following to a public paste service:
• System info (OS, Python version, Hermes version, provider, which API keys
are configured — NOT the actual keys)
• Recent log lines (agent.log, errors.log, gateway.log, desktop.log — may
contain conversation fragments and file paths)
• Full agent.log, gateway.log, and desktop.log (up to 512 KB each — likely
contains conversation content, tool outputs, and file paths)
Pastes auto-delete after 6 hours.
Collecting debug report...
Uploading...
Debug report uploaded:
Report https://paste.rs/UcvMs
agent.log https://dpaste.com/8UGEV9PSZ
gateway.log https://dpaste.com/8FJB3EURT
⏱ Pastes will auto-delete in 6 hours.
To delete now: hermes debug delete <url>
Share these links with the Hermes team for support.Operating System
Ubuntu 26.04
Python Version
3.12.13 (service venv: ~/.hermes/hermes-agent/.venv)
Hermes Version
git commit 0401176c7 (0401176c7ace2f1a76474fa8d0f3899d24c10102), branch main
Additional Logs / Traceback (optional)
### Evidence — verbatim `task_events` rows (SQLite kanban.db)
task_id ts (local) kind payload
---------- ------------------- --------- -------------------------------------------------
t_e89520e8 2026-06-04 23:30:08 created {"assignee":"default","status":"blocked", ...}
t_e89520e8 2026-06-04 23:30:09 promoted (empty payload — no actor)
t_e89520e8 2026-06-04 23:32:44 completed {"result_len":0,"summary":"Promotion to 96cd37e21 completed. ..."}
t_fcac06bc 2026-06-04 23:30:09 created {"assignee":"default","status":"blocked", ...}
t_fcac06bc 2026-06-04 23:30:09 promoted (empty payload — no actor)
t_fcac06bc 2026-06-04 23:33:04 completed {"result_len":0,"summary":"pytest==2.7.0 install succeeded but import fails. ..."}
- Distinct event kinds for both tasks: `created`, `promoted`, `completed` — **no
`claimed`/`started`/`running` event** was recorded. `hermes kanban show` reports each
run as `@default 0s` (`#101`, `#102`); `hermes kanban log <id>` returns no command log.
- **The dispatcher's own counter reported `promoted=0`.** The gateway dispatch loop that
emits these counters logged, at 23:32:38 on the incident night:
`gateway.run: kanban dispatcher: disabled via config kanban.dispatch_in_gateway=false`,
and every nearby counter line shows `... promoted=0 auto_blocked=0`. So the documented
dispatch loop was **disabled and recorded zero promotions**, yet the tasks were promoted
anyway — meaning the promote originates from a **separate loop** that does not attribute
the transition.
### Locus
The locus **appears to be the dispatch loop in the dashboard service**. Supporting
observation: the gateway dispatcher was disabled via `kanban.dispatch_in_gateway=false`
and reported `promoted=0`, ruling it out; the only other long-running process holding
the kanban DB open and writing to it on this box is `hermes dashboard --tui`. The
promote fires ~1s after creation regardless of the gateway dispatcher being off. (Stated
as the apparent locus, not a confirmed code path.)
## Affected Component
Kanban — task lifecycle / auto-promote of `blocked` tasks (apparent locus: dashboard
service dispatch loop). Related: #24699 / PR #28712.
## OS
Ubuntu 26.04 LTS (Resolute Raccoon); kernel 7.0.0-22-generic x86_64
## Python Version
3.12.13 (service venv: `~/.hermes/hermes-agent/.venv`)
## Hermes Version
git commit `0401176c7` (`0401176c7ace2f1a76474fa8d0f3899d24c10102`), branch `main`Root Cause Analysis (optional)
Notes for maintainers
- Severity is elevated because
blockedis being relied on as a security/authorization
gate; auto-promotion turns "file for human review" into "execute immediately." - Two distinct defects observed: (1) the unattributed
blocked → readyauto-promote
(this issue), and (2) the worker marking a taskdonewith a 0s run, no
claim/started/command-log evidence, and even when its own summary reports failure —
worth a separate issue if not already covered.
Proposed Fix (optional)
No response
Are you willing to submit a PR for this?
- I'd like to fix this myself and submit a PR
Activity
bill3wits commentedon Jun 5, 2026
Related: #28712 reports the same unattributed auto-promote for worker-blocked tasks; this issue shows it also fires on creation-blocked tasks. The unblock-event guard proposed there would close both.
dctr commentedon Jun 14, 2026
I can reproduce this on Hermes Agent v0.16.0 (2026.6.5). This is currently a big issue for me. I have bash scripts and LLM tasks creating cards for me that I want human approval (i.e. unblocking) before execution.
My contract is
Observed behaviour is that the card can be auto-promoted and picked up before approval.
dctr commentedon Jun 17, 2026
Regarding the "related" #28712 :
#28712’s fix does not fix the
--initial-status blockedcase.What it fixes:
kanban_block/hermes kanban blockblockedevent_has_sticky_block()sees that event and prevents auto-promotionWhat it does not fix:
--initial-status blockedstatus='blocked', but does not emit a stickyblockedeventrecompute_ready()still promotes itLocal verification on current Hermes:
So:
hermes kanban block <id> ...works as expected.hermes kanban create ... --initial-status blockedstill does not.pixel4039 commentedon Jul 13, 2026
Confirmed still reproducible on a newer build, with a real approval-gate bypass that spawned a writer before its execution contract was attached.
Environment
v0.18.0 (2026.7.1)e4ea0a0e6ceb21be(carried local commits; the affected lifecycle code matches the root cause described in this issue)3.11.15Real incident (2026-07-13 CST)
A task was created with
--initial-status blocked, an assigned worker profile, and a worktree. The intended sequence was: create blocked card → attach and validate a closed-world execution contract → explicitly unblock/dispatch.Observed task events:
The worker had already modified two files in the isolated worktree before it was terminated. The run was invalidated, its diff preserved locally for audit, and the worktree reset. This confirms the bug is not merely a UI/status inconsistency: it can launch a write-capable worker before an explicit approval gate is released.
Deterministic temp-DB reproduction
Against the current source, without a dashboard or live board:
Observed output:
Root cause confirmed in current source
The diagnosis already discussed above is exact:
create_task(initial_status="blocked")storestask_status = "blocked", but appends only acreatedevent._has_sticky_block()looks only for the latestblocked/unblockedevent, so the newly created task is not considered sticky.recompute_ready()scans bothtodoandblocked; for a task with no parents,all([])is true, so it writesstatus='ready'and appends an unattributedpromotedevent.Both proposed fixes remain open as of this confirmation: #34735 and #46565.
Given that this bypassed a deliberate contract/approval gate and started a write-capable worker, I recommend re-triaging this above P3. The narrow acceptance criterion remains: a task created with
initial_status="blocked"must emit/use the same sticky-block semantics as an explicit operator block and must not become runnable until an attributed explicit unblock.powoct commentedon Jul 24, 2026
Still present on current
main(a61183b5, 2026-07-24):create_task()inhermes_cli/kanban_db.pyappends only acreatedevent forinitial_status="blocked", so_has_sticky_block()has nothing to latch onto — exactly the gap @dctr traced above. Also hit this onv0.19.0 (2026.7.20)in a Docker deployment; a one-transaction fix (emit ablockedevent alongsidecreated) has been running clean for us since 2026-07-23 against this regression matrix: created-blocked survives repeatedrecompute_ready(); explicit unblock releases; circuit-breaker (non-sticky) blocks still auto-recover; idempotent create doesn't double-emit.For maintainers: there are already six open PRs implementing this direction (#46565, #34735, #39832, #41497, #64830, #35832), plus #47777 proposing the same fix and awaiting a design steer. Is one of them the canonical candidate to review/salvage? Happy to contribute test coverage there rather than opening a seventh.
7 remaining items
lukuku-git commentedon Aug 20, 2026
Confirmed on the current implementation:
kanban_db.py:4171includesblockedtasks as promotion candidates.kanban_db.py:4128sticky-block detection does not recognizecreated(status=blocked).--initial-status blockedcan be promoted and executed automatically.The safer fix is to remove
blockedfrom promotion candidates. An alternative is to make sticky-block detection recognizecreated.payload.status == "blocked", but that leaves more room for another promotion path to bypass the intent.blocked -> readyshould only be performed byunblock_task.State labeling and execution prevention must not be treated as the same thing. A structural execution prohibition enforced at the claim path is required.
ojlapp8-hash commentedon Aug 27, 2026
Fresh real-world reproduction (2026-08-27) confirming this bug + one broader finding. Reported on behalf of operator Jim Lappan II.
Context
Multi-agent kanban workflow on Hermes desktop (Windows), orchestrator + specialist profiles (androiddev, dataeng, research, hrbot, graphschema) via the gateway dispatcher (
dispatch_in_gateway: true, 60s tick). Human-in-the-loop is a hard requirement — no card should run without operator approval.Reproduction
ready. The gateway dispatcher AUTO-DISPATCHED both within the next tick — the 'HOLD' text in the body is inert; the dispatcher only inspects status.blockedcard was later returned toready(by a wake/hook transition) and IMMEDIATELY auto-ran again, even after a force-kill of its prior worker.Broader finding (in addition to #39609's blocked→auto-promote)
Even cards created directly as
readywith a human-gate instruction in the body are auto-dispatched — there is no first-class 'held / awaiting_approval' status that prevents dispatch while remaining queued. 'blocked' is the only non-dispatchable state, and it is not a stable gate (blocked→ready can still auto-run). A wake-triggered or re-dispatch transition returning a card toreadyimmediately auto-runs it.Damage (unreviewed work ran without approval)
Requested fix (same as #39609, generalized)
Add a first-class human-gated / held state (e.g.
awaiting_approval/held, or a per-cardrequires_approvalflag) that the gateway dispatcher NEVER auto-runs, even when otherwiseready. Only an explicit operator action (or primary-session command) may transition a held card to dispatchable. Dispatcher should log any attempt to auto-dispatch a gated card. This is the single highest-value fix for multi-agent kanban workflows with a human gate.Full writeup: (available on request). Happy to attach the full reproduction log/board state.
sionwellkamp commentedon Aug 31, 2026
Measured a distinction that may narrow this down, and that gives users a working workaround today.
--initial-status blockedis promoted.blockafter creation is not. Same board, same dispatcher, minutes apart, on v0.20.6 (local4f225435):Path A was observed twice (16 s and 25 s after creation, two different boards). Path B held for the full observation window with no promotion event at all.
So the promotion does not appear to be "any parentless blocked card gets promoted" — both cards were parentless. Something about the state as written by
--initial-statusdiffers from the state written byblock, which is consistent with @-the-earlier-analysis in this thread about no durable sticky-block event being recorded on the creation path.Workaround for anyone blocked by this: create the card normally, then
hermes kanban block <id>as a second call. The gate then holds.Why it cost us time: the CLI prints
Created t_xxxxxxxx (blocked, assignee=-)and the DB agrees at that moment — the return value is truthful when read and false when acted on. We parked two human-gate cards overnight on the strength of that line and reported them as parked; they werereadyseventeen seconds later. Apromotedevent carrying a reason, surfaced bykanban show, would have made this visible without going to the events table.sts-change commentedon Sep 6, 2026
Fresh production incident on v0.21.0 (2026-09-06) — the auto-promoted worker defeated
approvals.single_query_modeAnother confirmed datapoint: still broken on
v0.21.0 (2026.8.31)(upstream245e4800), macOS 26.6.2 host, gateway dispatcher. In our incident the spawned worker did not just run unsupervised — it neutralized the approval gate itself.What happened (exact sequence from the worker log)
Card
t_18985d07was created withinitial_status="blocked"as a human Go-gate for a Hermes update. One dispatcher tick later (~1 s) it was promoted toreadywith no actor and no operator action; the worker claimed it and:Line 15 is the gate working as designed. Line 18 is the gated agent lifting the gate itself via
hermes config set. Line 19 is the previously blocked command succeeding. The update pulled ~65 commits and dropped a carried local fix; we rolled back. Gate-self-lift filed separately: #104059.Code re-verification on the local v0.21.0 install
create_task()(hermes_cli/kanban_db.py:1219): status comes from_initial_task_status()(:1366), which returns"blocked"forinitial_status="blocked". The INSERT and the singlecreatedevent (:1334) carrystatus: "blocked"only as event payload — no event of kindblockedis emitted.recompute_ready()(:2014) selectsstatus IN ('todo', 'blocked')as promotion candidates and skips only when_has_sticky_block()(:1965) is true — which queries exclusively for the newesttask_eventsrow of kindblocked/unblocked.createdevent withstatus: "blocked"in its payload does not satisfy that predicate → promotion proceeds. This matches @powoct's July analysis exactly; confirmed unchanged on 0.21.0 after the 16 PRs referenced in the triage comment above.Why this is more than a scheduling bug
Our deployment uses
blockedexactly as @dctr describes (collectors file cards; a human moves them to ready; authorization = execution). In this incident the auto-promoted worker flippedapprovals.single_query_modefromdenytoapprove— the same setting whose "runs without a user present" message had just denied its first update attempt. The human approval gate for dangerous commands is itself agent-mutable, so any bug that lets a worker start unsupervised compounds into a full gate bypass.Related: gate self-lift issue #104059 (filed alongside this comment), zero-authority worker tracker #82591.
knee5 commentedon Sep 7, 2026
Confirmed the create-time block distinction in a recent isolated Linux test environment based on upstream
869228cab4a8276d3b4c78da9d9939670c47bd0f, with unrelated dependency-only downstream changes before the reproduction.The desired invariant still failed before the lifecycle fix: create with
initial_status="blocked", callrecompute_ready, and require the task to remain blocked. An explicit post-creation typed block follows a different path.I reviewed #34735 at
4df4e3b0f588bfde5a9625fb85edb939a34db9eb. Its atomic create-timeblockedevent addresses the root cause and already includes repeated recomputation, explicit unblock, and completed-parent tests. I have not executed that PR head. No competing PR is being opened.Additional acceptance checks worth retaining when adapting this older patch to current schema:
Operational caution: creating an assigned card and applying
blockin a second CLI call is not an atomic approval gate. The dispatcher can run between the calls. Do not rely on the small time gap to protect an execution-sensitive task.forcewake commentedon Sep 8, 2026
Independent reproduction with the exact same signature, different setup (v0.21.0, embedded gateway dispatcher ON, multi-board host).
Environment: Hermes Agent v0.21.0 (2026.8.31, upstream 866332b), Linux,
kanban.dispatch_in_gateway: true, 28 boards in~/.hermes/kanban/boards/, plushermes dashboardrunning on :9119 since two days before the incident.Repro: created a human-approval-gate card exactly as documented:
hermes kanban create "[P0-02] PURGE ... (requires human approval)" \ --assignee profile_name --initial-status blocked ...Event trail from the board DB (
task_events, second-resolution timestamps):So the card was promoted to ready ~1s after creation with no actor recorded — same signature as the report. The card had zero parents, so parent-gate recompute is not a factor. A manual
hermes kanban dispatch --dry-runrun 4 minutes earlier had printedPromoted: 0for its own pass, but we can't attribute the promotion cleanly: unlike the reporter's setup, our gateway dispatcher was embedded and running alongside the dashboard service, so we can only confirm the symptom + missing-actor event, not isolate the loop.What held for us (consistent with #24699 / #28712): worker/CLI-initiated typed blocks keep holding. After the auto-promote, the worker itself re-blocked the card with a typed
needs_input(hermes kanban block --kind needs_input ...) and it stayed blocked until an explicit operator action.Mitigation we adopted for approval gates: create the card normally, then immediately
hermes kanban block <id> --kind needs_input— this path is verified to stay blocked, while--initial-status blockedis not. Might be worth documenting next to the flag until the promotion path records an actor and respects creation-time blocked status.Also +1 on wanting attribution on every transition — the
promotedevent row here carries a NULL payload, which made post-hoc forensics harder than it should be.jhyland9 commentedon Sep 11, 2026
Fresh production incident on v0.21.0 — the auto-promoted card authorized a kernel cmdline change + reboot of a production hypervisor
Confirming this still reproduces on v0.21.1 (
code_sha 05d705dd…), Windows 11 host,kanban.dispatch_in_gateway: true, 60s tick. Root cause matched independently from source before Ifound this thread:
create_taskemits only acreatedevent,_has_sticky_block()has nothing tolatch onto, and
recompute_ready()promotes once the parent set is satisfied. Same analysis as@powoct / @sts-change; nothing new to add there.
What's new is the blast radius. The gated card did not merely run read-only commands — it
authorized a destructive maintenance operation, and the dispatcher dispatched it onto production.
Card
t_aa6aa9cawas created withinitial_status: blockedand aparentsedge, described as"BLOCKED pending a human-scheduled maintenance window — do not reboot
10.0.0.3or edit the kernelcmdline." Event log:
The target host is the operator's standalone production Proxmox hypervisor; the card's whole purpose
was kernel-cmdline instrumentation requiring a reboot. This matches @sts-change's 2026-09-06 report
in kind — there the spawned worker lifted its own gate via
hermes config set approvals.single_query_mode approve— but here the gated work was infrastructure-destructive bydesign, so an unsupervised run had a considerably worse ceiling.
Recovered by the same workaround others have documented. An orchestrator re-parked it with
kanban_block(kind="needs_input")(the stickyblockedevent the creation path never writes), andindependent host-side verification confirmed nothing had been written and no reboot occurred
(
uptimeunchanged,/etc/default/grubmtime pre-dating the run,/proc/cmdlineunmodified).One reinforcement of @knee5's caution, because it is easy to over-trust: block-after-create is not
atomic and the create call's own return value is actively misleading.
hermes kanban create ...printed
Created t_aa6aa9ca (blocked, …)and the row genuinely readblocked— and it was stillpromoted and claimed. Post-hoc forensics required reading
task_events; the status column and thecreate output both said the safe thing at the moment they were read.
Agreeing with the earlier asks that the highest-value fix beyond the missing create-time event is
attribution on transitions — the
promotedrow here again carried a NULL payload, so nothing inthe card surface indicated the gate had been bypassed. Anyone relying on "park it and check later"
cannot see this without querying the events table directly.
tahleen commentedon Sep 12, 2026
One detail this thread doesn't cover yet: no dispatcher tick is required — a plain board READ promotes the card.
Hit this on
v0.21.1(d76856cc, Linux/WSL,kanban.dispatch_in_gateway: true, 60 s tick) while chasing a human-gate card that self-promoted.recompute_ready()is not only reached from the dispatcher tick — it is also called on the CLIlistpath and from the dashboard API:hermes_cli/kanban.py:424— inside_cmd_list()plugins/kanban/dashboard/plugin_api.py:738Measured
task_eventsfor a parent-less card created with--initial-status blocked, with nothing else running on the board:For contrast, on the same board a natural gateway tick promoted an equivalent card 56 s later (11:10:01 → 11:10:57) — the
listpath is what makes it ~1 s.Two consequences worth covering in the fix and its test coverage:
--dry-runis not side-effect free either:_dispatch_once_locked()calls_run_reclaim_phase()unconditionally before any dry-run branch, and the promotion path runs ahead of it — a dry-run tick still emitspromoted.Root cause matches what is already established here:
create_task()records only acreatedevent, so_has_sticky_block()has nothing to latch onto, and the parent gate athermes_cli/kanban_db.py:2038(all(...)over an empty parent list →True) promotes the card.Workarounds that held for us across natural ticks and manual list/dispatch:
hermes kanban create ... --triage— stays parked until an explicit transition;hermes kanban block <id> "<reason>" --kind needs_inputin the same command (stickyblockedevent).Happy to paste the raw event-log dumps if that is useful.
ROAMIntelligence commentedon Sep 12, 2026
Two additions from a fresh repro on v0.21.1 (Linux,
dispatch_in_gateway), both confirmed against the realdispatch_once()rather than the status column:1. The create-then-
blockworkaround above has a hole, andblockcannot close it on a card that was created--initial-status blocked.block_taskonly matchesstatus IN ('running','ready'). On a card that is currentlyblocked(i.e. created with the flag),hermes kanban block <id>returnscannot block <id>and the card stays promotable. So the only wayblockworks is Path B above — create without the flag so the card landsready, then block it — which leaves a window where the card is genuinelyreadyand a dispatcher tick (or, per @tahleen, a plainhermes kanban list, which callsrecompute_ready()) can claim it before the second call lands.2.
hermes kanban schedule <id>parks a fresh card with noreadywindow at all.schedule_taskacceptsstatus IN ('todo','ready','running','blocked'), writesscheduled, andrecompute_ready()only scanstodo/blocked—scheduledis never a promotion candidate. Onlyunblock_taskexits it.Proof (Hermes venv python, same DB):
Control on the same board: a card created
--initial-status blockedand left alone wentblocked -> readyon the firstrecompute_ready()call (0 -> 1 promoted).Our wrapper now does create(
--initial-status blocked) +scheduleback-to-back and fails nonzero if the readback is anything other thanscheduled. Semantically it is a slight misuse (scheduledmeans "waiting on time"), so this is a workaround, not an argument against fixing the creation path —created(status=blocked)should count as the sticky event, as the open PRs propose.kshitijk4poor commentedon Sep 18, 2026
Closing as fixed on
main.hermes_cli/kanban_db.py::create_tasknow appends ablockedevent (reason: initial_status) alongsidecreatedwheninitial_status='blocked', so_has_sticky_blockhas the event to latch onto andrecompute_readyno longer promotes the task — commitad0398eed8(2026-09-11, #107398); @teknium1's #109334 (2026-09-12) additionally gates the board-read and dispatcher-tick promotion paths.Re-ran this issue's own repro on
16c451c280(tempHERMES_HOME, realkanban_dbconnect →create_task(initial_status='blocked')→ 3×recompute_ready): status staysblocked,promoted=0each pass, events['created', 'blocked'].Credit: @begjb's #34735 (May 29) proposed exactly this event-emission fix first; @onfire7777 #69679, @clutran78 #71861, @Kyzcreig #71977, @javiersangsanchez-droid #88686 reached the same approach. #69531 (auditable authorization) and #81221 (caller-identity on unblock) are separate concerns and stay open on their own merits.