Skip to content

Shared task board where people and AI coding agents work as teammates. Source-available, self-hostable.

Go

MUL-8897: docs(config): document zero-duration watchdog overrides (#10234)

Zain Qureshi06ca0bfe16f3
diff --git a/apps/docs/content/docs/environment-variables.fr.mdx b/apps/docs/content/docs/environment-variables.fr.mdx
index d9e67e1138..a5457cd778 100644
--- a/apps/docs/content/docs/environment-variables.fr.mdx
+++ b/apps/docs/content/docs/environment-variables.fr.mdx
@@ -382,6 +382,8 @@ Clés prises en charge :
| `ws_claim_poll_interval` | `3m` | Borne supérieure des interrogations de sécurité de la prise en charge via WebSocket lorsque celle-ci est saine, indépendante de `poll_interval` ; le daemon applique une gigue uniquement à la baisse |
| `heartbeat_interval` | `15s` | Intervalle des signaux de vie (heartbeat) |
| `agent_timeout` | illimité | Durée maximale absolue par exécution |
+| `agent_idle_watchdog` | `2h` | Durée maximale de silence lorsqu'aucun appel d'outil n'est en cours ; `0s` désactive entièrement le watchdog du daemon, y compris `agent_tool_watchdog` |
+| `agent_tool_watchdog` | identique à `agent_idle_watchdog` | Durée maximale de silence pendant un appel d'outil ; avec `0s`, le watchdog du daemon n'arrête jamais une exécution à cause d'un appel d'outil silencieux, et l'exécution n'est plus bornée que par `agent_timeout`, illimité par défaut |
| `codex_semantic_inactivity_timeout` | dérivée | Seuil de silence sémantique de Codex. Si rien n'est défini, il prend le plus grand des budgets des watchdogs d'inactivité et d'outil ; un budget d'outil de `0` se rabat sur le budget d'inactivité, et ce n'est que lorsque l'ensemble des watchdogs est désactivé que Codex conserve son propre `10m` |
| `codex_handshake_timeout` | `30s` ; `thread/start`, `thread/resume` : `60s` | Plafonds de la poignée de main au démarrage du Codex app-server. Une valeur explicite remplace globalement les deux budgets |
| `disable_auto_update` | suit l'environnement | `true` désactive la mise à jour automatique ; `false` efface la surcharge locale et revient à la variable d'environnement ou à la valeur par défaut |
@@ -390,7 +392,7 @@ Clés prises en charge :
Quelques règles concernant les valeurs :
-- Les clés de durée acceptent des durées Go positives (comme `10s`, `2h`) ; `0s` et les valeurs négatives sont refusées. La seule exception est `agent_timeout` : `0s` est valide et désactive explicitement la limite de durée des exécutions.
+- Les clés de durée acceptent des durées Go positives (comme `10s`, `2h`) ; les valeurs négatives sont toujours refusées. Seules `agent_timeout`, `agent_idle_watchdog` et `agent_tool_watchdog` acceptent aussi `0s` : pour `agent_timeout`, cela désactive explicitement la limite de durée des exécutions ; pour les deux clés de watchdog, le tableau indique ce que `0s` désactive.
- Passer une chaîne vide efface une valeur persistée et revient à la variable d'environnement ou à la valeur par défaut intégrée, par exemple `multica config set poll_interval ""`.
- `max_concurrent_tasks` exige un entier positif ou nul.
- Les valeurs relatives de `workspaces_root` sont converties en chemins absolus lors de l'enregistrement.
diff --git a/apps/docs/content/docs/environment-variables.ja.mdx b/apps/docs/content/docs/environment-variables.ja.mdx
index 05a74dcdae..dc9e3d9e8a 100644
--- a/apps/docs/content/docs/environment-variables.ja.mdx
+++ b/apps/docs/content/docs/environment-variables.ja.mdx
@@ -385,6 +385,8 @@ multica config show
| `ws_claim_poll_interval` | `3m` | 正常な WebSocket での claim 安全ポーリング上限。`poll_interval` とは独立して設定され、Daemon は下方向のジッターを適用します |
| `heartbeat_interval` | `15s` | ハートビート間隔 |
| `agent_timeout` | 無制限 | 1 回の実行の絶対時間上限 |
+| `agent_idle_watchdog` | `2h` | ツール実行中でないときの静穏上限。`0s` でデーモンの watchdog 全体を無効化し、`agent_tool_watchdog` も効かなくなります |
+| `agent_tool_watchdog` | `agent_idle_watchdog` と同じ | ツール実行中の静穏上限。`0s` にするとデーモンの watchdog は静穏なツール呼び出しを理由に実行を停止しなくなり、実行の上限は `agent_timeout`(デフォルトは無制限)だけになります |
| `codex_semantic_inactivity_timeout` | 派生値 | Codex のセマンティック静穏しきい値。未設定なら idle と tool の watchdog 予算のうち大きい方を採用し、tool 予算が `0` の場合は idle 予算に回帰します。Codex 自身の `10m` が残るのは watchdog 一式を無効化したときだけです |
| `codex_handshake_timeout` | `30s`、`thread/start`・`thread/resume`:`60s` | Codex app-server 起動ハンドシェイクの上限。明示的な値は両方の予算を一括で上書きします |
| `disable_auto_update` | 環境に従う | `true` で自動更新を無効化。`false` はローカルの上書きをクリアし、環境変数またはデフォルトに戻します |
@@ -393,7 +395,7 @@ multica config show
値のルール:
-- duration 系のキーは正の Go duration(`10s`、`2h` など)を受け付け、`0s` と負の値は拒否されます。唯一の例外は `agent_timeout` で、`0s` は有効な値として実行時間上限を明示的に無効化します。
+- duration 系のキーは正の Go duration(`10s`、`2h` など)を受け付け、負の値は常に拒否されます。`0s` も受け付けるのは `agent_timeout`、`agent_idle_watchdog`、`agent_tool_watchdog` だけです。`agent_timeout` の `0s` は実行時間上限を明示的に無効化します。watchdog の 2 キーで `0s` が何を無効にするかは表を参照してください。
- 空文字列を渡すと永続化された値がクリアされ、環境変数または組み込みデフォルトに戻ります。例: `multica config set poll_interval ""`。
- `max_concurrent_tasks` には非負の整数が必要です。
- 相対パスの `workspaces_root` は保存時に絶対パスへ変換されます。
diff --git a/apps/docs/content/docs/environment-variables.ko.mdx b/apps/docs/content/docs/environment-variables.ko.mdx
index af4d60378c..ae2db23dc7 100644
--- a/apps/docs/content/docs/environment-variables.ko.mdx
+++ b/apps/docs/content/docs/environment-variables.ko.mdx
@@ -385,6 +385,8 @@ multica config show
| `ws_claim_poll_interval` | `3m` | 정상 WebSocket에서 claim 안전 polling의 상한. `poll_interval`과 독립적으로 설정되며 Daemon은 하향 jitter를 적용합니다 |
| `heartbeat_interval` | `15s` | heartbeat 간격 |
| `agent_timeout` | 제한 없음 | 단일 실행의 절대 시간 제한 |
+| `agent_idle_watchdog` | `2h` | 실행 중인 도구 호출이 없을 때의 무응답 상한. `0s`이면 데몬 watchdog 전체가 꺼지며 `agent_tool_watchdog`도 적용되지 않습니다 |
+| `agent_tool_watchdog` | `agent_idle_watchdog`와 동일 | 도구 호출이 실행 중일 때의 무응답 상한. `0s`이면 데몬 watchdog이 무응답 도구 호출 때문에 실행을 멈추지 않으며, 실행은 `agent_timeout`(기본값은 제한 없음)으로만 제한됩니다 |
| `codex_semantic_inactivity_timeout` | 파생 | Codex 의미 활동 없음 기준값. 설정하지 않으면 idle과 tool watchdog 예산 중 큰 값을 따르고, tool 예산이 `0`이면 idle 예산으로 되돌아갑니다. Codex 자체의 `10m`은 watchdog 전체를 비활성화했을 때만 유지됩니다 |
| `codex_handshake_timeout` | `30s`, `thread/start`·`thread/resume`: `60s` | Codex app-server 시작 handshake 상한. 명시적으로 설정한 값은 두 예산을 모두 일괄 재정의합니다 |
| `disable_auto_update` | 환경을 따름 | `true`는 자동 업데이트를 끔. `false`는 로컬 덮어쓰기를 지우고 환경 변수 또는 기본값으로 복귀 |
@@ -393,7 +395,7 @@ multica config show
값에는 다음 규칙이 적용됩니다.
-- duration key는 양의 Go duration(예: `10s`, `2h`)을 허용하며 `0s`와 음수는 거부합니다. 유일한 예외는 `agent_timeout`입니다. `0s`가 유효하며 실행 시간 제한을 명시적으로 끕니다.
+- duration key는 양의 Go duration(예: `10s`, `2h`)을 허용하며 음수는 항상 거부합니다. `0s`까지 허용하는 key는 `agent_timeout`, `agent_idle_watchdog`, `agent_tool_watchdog`뿐입니다. `agent_timeout`의 `0s`는 실행 시간 제한을 명시적으로 끄고, 두 watchdog key에서 `0s`가 무엇을 끄는지는 표를 참고하세요.
- 빈 문자열을 전달하면 저장된 값을 지우고 환경 변수 또는 내장 기본값으로 돌아갑니다. 예: `multica config set poll_interval ""`
- `max_concurrent_tasks`는 0 이상의 정수여야 합니다.
- 상대 `workspaces_root` 값은 저장할 때 절대 경로로 변환됩니다.
diff --git a/apps/docs/content/docs/environment-variables.mdx b/apps/docs/content/docs/environment-variables.mdx
index 9cd36bae15..9303c5ee66 100644
--- a/apps/docs/content/docs/environment-variables.mdx
+++ b/apps/docs/content/docs/environment-variables.mdx
@@ -391,6 +391,8 @@ Supported keys:
| `ws_claim_poll_interval` | `3m` | Upper bound for healthy WebSocket claim safety polls, independent of `poll_interval`; the daemon applies downward-only jitter |
| `heartbeat_interval` | `15s` | Heartbeat interval |
| `agent_timeout` | unlimited | Absolute time limit per run |
+| `agent_idle_watchdog` | `2h` | Silence ceiling when no tool call is in flight; `0s` turns off the daemon watchdog entirely, including `agent_tool_watchdog` |
+| `agent_tool_watchdog` | same as `agent_idle_watchdog` | Silence ceiling while a tool call is in flight; `0s` means the daemon watchdog never stops a run over a silent tool call, so the run is bounded only by `agent_timeout`, which is unlimited by default |
| `codex_semantic_inactivity_timeout` | derived | Codex semantic-silence threshold. With nothing set it takes the larger of the idle and tool watchdog budgets; a tool budget of `0` falls back to the idle budget, and only when the whole watchdog suite is disabled does Codex keep its own `10m` |
| `codex_handshake_timeout` | `30s`; `thread/start`, `thread/resume`: `60s` | Codex app-server startup handshake ceilings. An explicit value overrides both budgets globally |
| `disable_auto_update` | follows environment | `true` turns auto-update off; `false` clears the local override and returns to the env var or default |
@@ -399,7 +401,7 @@ Supported keys:
A few value rules:
-- Duration keys accept positive Go durations (such as `10s`, `2h`); `0s` and negative values are rejected. The one exception is `agent_timeout`: `0s` is valid and explicitly disables the run time limit.
+- Duration keys take a positive Go duration such as `10s` or `2h`; negative values are always rejected. Only `agent_timeout`, `agent_idle_watchdog`, and `agent_tool_watchdog` also accept `0s`: for `agent_timeout` it removes the run time limit, and for the two watchdog keys the table says what it turns off.
- Passing an empty string clears a persisted value and falls back to the env var or built-in default, for example `multica config set poll_interval ""`.
- `max_concurrent_tasks` requires a non-negative integer.
- Relative `workspaces_root` values are converted to absolute paths when saved.
diff --git a/apps/docs/content/docs/environment-variables.zh-Hant.mdx b/apps/docs/content/docs/environment-variables.zh-Hant.mdx
index b18c41d872..edfb847a26 100644
--- a/apps/docs/content/docs/environment-variables.zh-Hant.mdx
+++ b/apps/docs/content/docs/environment-variables.zh-Hant.mdx
@@ -381,6 +381,8 @@ multica config show
| `ws_claim_poll_interval` | `3m` | 健康 WebSocket 下 claim 安全輪詢的上限,與 `poll_interval` 獨立配置;Daemon 會應用向下抖動 |
| `heartbeat_interval` | `15s` | 心跳間隔 |
| `agent_timeout` | 不限制 | 單次執行的絕對時限 |
+| `agent_idle_watchdog` | `2h` | 沒有工具執行時的靜默上限;`0s` 關閉守護程序的整套 watchdog,`agent_tool_watchdog` 也隨之失效 |
+| `agent_tool_watchdog` | 同 `agent_idle_watchdog` | 工具執行期間的靜默上限;`0s` 表示守護程序的 watchdog 不會因工具靜默而停止執行,此時執行只受 `agent_timeout` 限制,而它預設不限制 |
| `codex_semantic_inactivity_timeout` | 派生 | Codex 語義靜默閾值。未設定時取 idle 與 tool watchdog 預算中較大的那個;tool 預算為 `0` 時回落到 idle 預算;只有整套 watchdog 關閉時才保留 Codex 自己的 `10m` |
| `codex_handshake_timeout` | `30s`;`thread/start`、`thread/resume`:`60s` | Codex app-server 啟動握手上限;顯式設定後會統一覆蓋兩類預算 |
| `disable_auto_update` | 跟隨環境 | `true` 關閉自動更新;`false` 清除本地覆蓋,回到環境變數或預設 |
@@ -389,7 +391,7 @@ multica config show
幾條取值規則:
-- duration 類鍵接受正的 Go duration(如 `10s`、`2h`),`0s` 和負值會被拒絕。唯一例外是 `agent_timeout`:`0s` 合法,表示明確關閉執行時限。
+- duration 類鍵接受正的 Go duration(如 `10s`、`2h`),負值一律拒絕。只有 `agent_timeout`、`agent_idle_watchdog`、`agent_tool_watchdog` 還接受 `0s`:`agent_timeout` 設為 `0s` 表示明確關閉執行時限,兩個 watchdog 鍵設為 `0s` 關閉什麼見上表。
- 傳空字串清除已持久化的值,回到環境變數或內建預設,例如 `multica config set poll_interval ""`。
- `max_concurrent_tasks` 要求非負整數。
- 相對的 `workspaces_root` 值在儲存時會轉換為絕對路徑。
diff --git a/apps/docs/content/docs/environment-variables.zh.mdx b/apps/docs/content/docs/environment-variables.zh.mdx
index afa7862d57..84c046536e 100644
--- a/apps/docs/content/docs/environment-variables.zh.mdx
+++ b/apps/docs/content/docs/environment-variables.zh.mdx
@@ -385,6 +385,8 @@ multica config show
| `ws_claim_poll_interval` | `3m` | 健康 WebSocket 下 claim 安全轮询的上限,与 `poll_interval` 独立配置;Daemon 会应用向下抖动 |
| `heartbeat_interval` | `15s` | 心跳间隔 |
| `agent_timeout` | 不限制 | 单次执行的绝对时限 |
+| `agent_idle_watchdog` | `2h` | 没有工具执行时的静默上限;`0s` 关闭守护进程的整套 watchdog,`agent_tool_watchdog` 也随之失效 |
+| `agent_tool_watchdog` | 同 `agent_idle_watchdog` | 工具执行期间的静默上限;`0s` 表示守护进程的 watchdog 不会因工具静默而停止执行,此时执行只受 `agent_timeout` 限制,而它默认不限制 |
| `codex_semantic_inactivity_timeout` | 派生 | Codex 语义静默阈值。未设置时取 idle 与 tool watchdog 预算中较大的那个;tool 预算为 `0` 时回落到 idle 预算;只有整套 watchdog 关闭时才保留 Codex 自己的 `10m` |
| `codex_handshake_timeout` | `30s`;`thread/start`、`thread/resume`:`60s` | Codex app-server 启动握手上限;显式设置后会统一覆盖两类预算 |
| `disable_auto_update` | 跟随环境 | `true` 关闭自动更新;`false` 清除本地覆盖,回到环境变量或默认 |
@@ -393,7 +395,7 @@ multica config show
几条取值规则:
-- duration 类键接受正的 Go duration(如 `10s`、`2h`),`0s` 和负值会被拒绝。唯一例外是 `agent_timeout`:`0s` 合法,表示明确关闭执行时限。
+- duration 类键接受正的 Go duration(如 `10s`、`2h`),负值一律拒绝。只有 `agent_timeout`、`agent_idle_watchdog`、`agent_tool_watchdog` 还接受 `0s`:`agent_timeout` 设为 `0s` 表示明确关闭执行时限,两个 watchdog 键设为 `0s` 关闭什么见上表。
- 传空字符串清除已持久化的值,回到环境变量或内置默认,例如 `multica config set poll_interval ""`。
- `max_concurrent_tasks` 要求非负整数。
- 相对的 `workspaces_root` 值在保存时会转换为绝对路径。
diff --git a/server/cmd/multica/cmd_config.go b/server/cmd/multica/cmd_config.go
index 9a30b3316f..00a09c224c 100644
--- a/server/cmd/multica/cmd_config.go
+++ b/server/cmd/multica/cmd_config.go
@@ -220,9 +220,8 @@ func applyConfigSet(cfg *cli.CLIConfig, key, value string) error {
return err
}
case "agent_timeout":
- // agent_timeout is the one duration knob where "0s" is a
- // meaningful persisted value (it explicitly disables the
- // wall-clock cap; see cli.CLIConfig.AgentTimeout). Store the raw
+ // agent_timeout accepts "0s" to explicitly disable the
+ // wall-clock cap (see cli.CLIConfig.AgentTimeout). Store the raw
// string via a pointer so we can distinguish "not set" (nil)
// from "disabled" (non-nil, "0s") and any positive value.
if value == "" {
@@ -288,8 +287,9 @@ func assignBool(dst *bool, key, value string) error {
}
// assignPositiveDuration parses value as a strictly-positive Go duration
-// and writes the raw string into dst. Shared by every persisted daemon
-// duration knob except agent_timeout, whose zero value is meaningful.
+// and writes the raw string into dst. Not used by agent_timeout,
+// agent_idle_watchdog, or agent_tool_watchdog, whose zero values are
+// meaningful.
// Empty string clears the field.
func assignPositiveDuration(dst *string, key, value string) error {
if value == "" {