Skip to content

fix(handler): restore usable configurable command deadlines - #349

Merged
devth merged 1 commit into
masterfrom
fix/configurable-command-deadline
Nov 12, 2026
Merged

devth merged 1 commit into
masterfrom
fix/configurable-command-deadline

Conversation

@devth

@devth devth commented Nov 12, 2026

Copy link
Copy Markdown
Member

Summary

Restore usable timing for longer commands after #347 made evaluation eager. The old lazy path did not apply its nominal five-second limit to full evaluation; eager evaluation began cutting off ordinary model and other longer-running commands.

The operator explicitly selected a configurable five-minute default, separately from #348's shared-dispatcher starvation repair.

  • Load the startup deadline from command.timeout.ms / YETIBOT_COMMAND_TIMEOUT_MS, defaulting to 300,000 ms.
  • Accept positive integer or numeric-string milliseconds through 2,147,483,647; missing/invalid values fall back safely without exposing their contents.
  • Document startup/restart behavior and the fact that timeout does not prove an external effect was cancelled.
  • Retain existing shorter explicit deadlines, late-derived-effect prevention, eager evaluation and the blocking-worker fix.

Verification

Boundaries

No production config/credentials, permissions, provider/model selection, provider/tool socket timeouts, generation limits, call budgets, schema or updater changes. This is an overall evaluation deadline, not a spending cap or automatic retry. The original inherited-execution app feature is still unreleased.

Eager evaluation in #347 accidentally made a five-second deadline cut off normal longer commands. The operator chose a configurable five-minute default. Read validated startup command.timeout.ms, retain shorter explicit limits and unchanged late-effect scope closure, and cover an actual command exceeding five seconds plus numeric/string configuration boundaries.
@devth
devth merged commit 5b28e88 into master Nov 12, 2026
1 check passed
@devth
devth deleted the fix/configurable-command-deadline branch November 12, 2026 15:22
@devth

devth commented Nov 12, 2026

Copy link
Copy Markdown
Member Author

Production repair verified — 2026-11-12 UTC

PR #347 caused two separate regressions: eager blocking/recursive evaluation inside go exhausted the finite dispatcher pool, and eagerness activated a five-second full-evaluation deadline that the old lazy path did not enforce.

  • fix(handler): prevent command dispatcher starvation #348 moves both blocking handler entrypoints to worker threads; eight concurrent real nested aliases are covered through raw and delivery routes, including a subsequent command.
  • fix(handler): restore usable configurable command deadlines #349 implements the operator-selected configurable five-minute default. Provider/tool timeouts, generation/call budgets, permissions and retry rules are unchanged. The existing explicit-short-deadline/late-effect guard remains.
  • Both had fresh independent ready/zero-finding reviews. Exact-head full core CI: fix(handler): prevent command dispatcher starvation #348 2,726, fix(handler): restore usable configurable command deadlines #349 2,738 checks; both tested/merged full trees match. Counts are separate, nonadditive.
  • Final automatic app dependency bump #1339 passed 5,852 Midje checks, 34 tests/311 assertions, and separate catalog 32 tests/311 assertions, then merged 2042a1c7e84f61b780bf83a6f9f03c6662d1d3bd. Completed predecessor bumps were preserved, not replayed.
  • Genuine published core 20261112.152303.5b28e88 / commit 5b28e882ab597aefe10cecda7cef02931d9d4e06: all 118 source resources and concrete POM qualified. Genuine app 20261112.152704.2042a1c: all 147 source resources/POM/manifest qualified. Release workflows, including final Docker publication, succeeded.
  • Benson normal updater performed one service start, 15:31:45 UTC. Main PID 3613, application JVM 3653. All 147 app + 118 core + 2 plugin first-resolved sources match the qualified release sources; no implementation overlay.
  • Runtime core is the normal updater's source-built core-20261112.153123.5b28e882.jar, not a claim of published-JAR byte identity. Source identity is verified. Kroki pin/artifact unchanged.
  • Read-only observation of the actual application JVM confirms deadline-ms=300000, no timeout override, and the unreleased app host bridge inactive. A pure in-memory task on the actual live async dispatcher completed within its one-second probe window.
  • Installed-classpath separate-JVM smoke: 105 checks passed, including both concurrent routes, actual >5-second command and late-effect guard, with external HTTP/JDBC blocked. This is not a natural Discord/model request.
  • Health HTTP 200; configuration/credentials, operational files, updater REQUIRE_CI=0, unrelated files and lock inode 539834 preserved. Temporary updater lease expired naturally and its owner was verified absent; no signal sent to an expired/reused PID. No duplicate restart request was issued while normal updater was already activating.

No failed meme/model/account request was automatically replayed. Fresh natural Discord behavior remains for operator feedback. The original app command-to-chart/inherited-agent feature is still unreleased; its retained U3 work was paused and preserved during this incident.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant