Repository navigation
subagent-model-selection-settings: allowedModels 改动对运行中的 Session 不生效,报错也无补救提示 / changes do not apply to a running Session, error gives no remedy #9087
Replies: 2 comments
|
The first thing I'd check is whether the session's model allowlist is captured when the session starts or read again for every subagent invocation. If the allowlist is intentionally captured during session initialization, editing the configuration afterward won't necessarily affect the existing session. In that case, starting a new session with the updated configuration is a useful diagnostic step. I'd test the following:
If the second model works only in the fresh session, that supports the session-initialization explanation. For the longer-term fix, the error message could explicitly state that the allowlist was captured when the session started and recommend creating a new session. A diagnostic command showing the effective session-level allowlist would also make this easier to troubleshoot. I would verify this against the implementation and documentation before treating it as the confirmed root cause. |
|
I think the behavior itself is probably intentional, but the error message is missing an important piece of context. If For your current setup, I'd save the configuration and start a new session. That should load the updated allowlist. If the new session still rejects the model, then I'd investigate the resolved profile and provider configuration. For the implementation, I'd keep the session-level allowlist immutable and improve the diagnostics rather than hot-reloading permissions. A useful error would distinguish three cases:
The third case could return something like:
I'd also expose the session's effective model list separately from the global provider catalog. Otherwise, users are comparing two different sources of truth without realizing it. For regression coverage, I'd test this exact sequence: start with model A allowed, add model B while the session is running, verify that B remains blocked in the existing session with a useful explanation, then verify that B works in a newly created session. That would preserve the existing security behavior while making the failure much easier to understand. |
Uh oh!
There was an error while loading. Please reload this page.
现象
subagent-model-selection-settings里allowedModels的改动对正在运行的 Session 不生效,而且报错信息没有给出可操作的补救方式。复现(本机 DSH Desktop,profile
desktop):subagent,provider: openai-codex、model: gpt-6-astra:改回、再改、反复调用都一样。该模型本身在 provider 目录里是存在的(
llm-openai-codex的models列表含gpt-6-astra),所以不是模型 id 写错。期望
三选一即可:
list_subagent_models反映 Session 级的 effective 白名单)现状是:设置静默不生效,报错只说 "not allowed for this Session",用户无法区分「模型 id 写错了」「provider 不允许」「需要开新会话」。
影响
list_subagent_models返回的是 provider 目录而不是 Session 生效集合,两者不一致会误导。环境
desktopsubagent-model-selection-settings@deepseek-ai/dsh-tool-subagent说明
我理解这可能是有意设计——
@deepseek-ai/dsh-tool-subagent的 README 提到策略在会话组装时采样、"unchanged by later settings edits"。这个取舍本身可以理解(避免在途会话权限漂移),但当前的失败模式(静默无效 + 无补救提示)建议至少按上面 B 改一下报错文案。English
Symptom
Changes to
allowedModelsinsubagent-model-selection-settingshave no effect on a running Session, and the error offers no remedy.Reproduction (local DSH Desktop, profile
desktop):allowedModels: [openai-codex/gpt-6.1-sol].openai-codex/gpt-6-astra.subagentwithprovider: openai-codex,model: gpt-6-astrafails:Re-editing and retrying makes no difference. The model itself is present in the provider catalog (
llm-openai-codex.modelsincludesgpt-6-astra), so this is not a typo in the model id.Expected
Any one of:
list_subagent_modelsreflecting the session-level effective set)Today the setting silently does not apply, and the message does not distinguish "wrong model id" from "provider not allowed" from "new session required".
Impact
list_subagent_modelsreports the provider catalog rather than the effective session set, so the two disagree.Environment
desktopsubagent-model-selection-settings@deepseek-ai/dsh-tool-subagentNote
This may well be intentional: the
@deepseek-ai/dsh-tool-subagentREADME says the policy is sampled at session assembly and is "unchanged by later settings edits". That trade-off is understandable (it avoids mid-session permission drift). The request is mainly about the failure mode: at minimum, option B in the error text.All reactions