You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Consensus mode: a no-op transaction on a ledger with no commits yet is poisoned as WorkerPanic (standalone returns t=0, 0 flakes) #2465
P2Scheduled: real but not urgentarea:serverHTTP surface, routes, error mapping, swagger, timeouts/admission, config graphbugSomething isn't working as expected
We ran into this on a multi-node (raft) deployment: a transaction that changes nothing, sent to a ledger that has been created but has no commits yet, comes back as a poisoned submission rather than a no-op:
Transaction error: Update failed: submission poisoned: WorkerPanic { message: "no-op transaction on a ledger without a head commit" }
It showed up when a pipeline created a fresh ledger and then wrote an empty result set to it (an update whose where matched nothing). That's a perfectly normal thing for a caller to do. Standalone handles the same sequence fine. With the CLI (4.2.4, embedded): fluree create noopt, then fluree update noopt with {"where": {"@id": "?s", "ex:p": "?o"}, "delete": {"@id": "?s", "ex:p": "?o"}} → Committed t=0, 0 flakes, and the ledger stays commit-less.
Where it comes from (main at b5aee2c0f): fluree-db-consensus/src/raft/commit_worker.rs:709-733. When build_commit() returns None (no change), the worker mirrors the revert no-op path by republishing the current head, and the comment says "A no-op requires an already-registered graph, hence an existing head". On a just-created ledger snap.head_commit_id is None, so the ok_or_else turns it into PoisonReason::WorkerPanic (:719-722), which surfaces through the queued transactor as submission poisoned (queued_transactor.rs:946 / :1247).
So the assumption in that comment doesn't hold for a ledger that exists but hasn't committed yet, and the result is a "panic"-classified poison for what's really a successful no-op. I don't think anything is corrupted (the queue entry just fails), but the caller sees an error, and anything that counts poisoned submissions as worker faults will count this one.
Possible fix: when there's no head, complete the entry the way standalone does: a no-op receipt at t = 0 with flake_count: 0 and install: None. Or, if a receipt really needs a commit id there, a typed "nothing to commit" outcome rather than WorkerPanic. Either way, a consensus-mode test of "create, then no-op update" would pin it, since today only the standalone path seems to cover that sequence.
P2Scheduled: real but not urgentarea:serverHTTP surface, routes, error mapping, swagger, timeouts/admission, config graphbugSomething isn't working as expected
Activity