edict icon indicating copy to clipboard operation
edict copied to clipboard

openclaw更新3.31之后,为什么只能使用太子,其他部门使用不了,已经配置了API-key

Open TimeQ-coder opened this issue 8 months ago • 7 comments

问题描述

为什么只能使用太子,其他部门使用不了,已经配置了API-key

Image

相关环境

  • OpenClaw 版本:OpenClaw 2026.3.31 (213a704)
  • 操作系统:wsl2
  • Python 版本:Python 3.12.3

TimeQ-coder avatar Apr 01 '26 15:04 TimeQ-coder

更新到了31之后对命令的权限更加的严格了

Vip4pt avatar Apr 02 '26 08:04 Vip4pt

OpenClaw 3.31 反复授权问题 OpenClaw 2026.3.31 版本中,收紧了exec命令执行的权限,导致每次要执行命令,都要求授权,这在安全层面是好事。

如果要禁用每次授权,默认允许,只需要修改 openclaw.json 配置文件的 tools 模块的代码,安全设置为 full 即可,代码参考如下:

... "tools": { "profile": "coding", "exec": { "security": "full" }, } ...

也可以直接执行命令完成修改 openclaw config set tools.exec.security full

Vip4pt avatar Apr 02 '26 08:04 Vip4pt

sessions_send — 往已有 session 塞消息 目标 session 必须已经存在且活跃 就像微信发消息给一个在线的人 对方不在线 → 消息丢失,没人处理 适合:主 agent 与已唤醒的 subagent 之间通信 **openclaw agent --agent xxx -m "..." ** — 唤起 agent 并交任务 会新建一个 session,无论对方是否在线 就像打电话叫醒一个人,确保他起来干活 对方"睡着"也没关系,命令会把他启动 适合:跨 agent 派发任务,确保对方一定收到并执行 为什么中书省会"不在线"? edict 的各省 agent 不是常驻进程,平时不运行,只有被调用时才启动。太子用 sessions_send 找中书省,发现没有活跃 session,就认为"中书省不在线",然后绕过了。 改成 openclaw agent 命令后,太子会主动"敲中书省的门把他叫起来",流转就不会断

CattleZ avatar Apr 02 '26 08:04 CattleZ

这个问题大概率是 OpenClaw 3.31 版本的 Agent 激活方式有变化导致的。

请尝试以下排查步骤:

  1. 确认所有 Agent 已激活:openclaw agent list — 检查各省部是否显示为 active
  2. 检查 API Key 配置:确保每个 Agent 使用的模型都有对应的 API Key(在 ~/.openclaw/openclaw.json 的 models 配置中)
  3. 检查 Agent 间通信:确认 agentToAgent.enabled 为 true
  4. 重新安装 Agent:cd 到三省六部项目目录,运行 bash install.sh,这会重新注册所有 Agent

如果 openclaw agent list 只显示太子而看不到其他 Agent,说明安装脚本可能没有成功注册全部 12 个 Agent,需要重新执行安装。

cft0808 avatar Apr 05 '26 14:04 cft0808

$ openclaw agent list
error: required option '-m, --message <text>' not specified

看不出agent 有沒有 active 耶

$ openclaw agents list

🦞 OpenClaw 2026.4.5 (3e72c03) — The only open-source project where the mascot could eat the competition.

Agents:
- taizi
  Workspace: ~/.openclaw/workspace-taizi
  Agent dir: ~/.openclaw/agents/taizi/agent
  Model: cowbay/gpt-5.4
  Routing rules: 0
- zhongshu
  Workspace: ~/.openclaw/workspace-zhongshu
  Agent dir: ~/.openclaw/agents/zhongshu/agent
  Model: cowbay/gpt-5.4
  Routing rules: 0
- menxia
  Workspace: ~/.openclaw/workspace-menxia
  Agent dir: ~/.openclaw/agents/menxia/agent
  Model: cowbay/gpt-5.4
  Routing rules: 0
- shangshu
  Workspace: ~/.openclaw/workspace-shangshu
  Agent dir: ~/.openclaw/agents/shangshu/agent
  Model: cowbay/gpt-5.4
  Routing rules: 0
- hubu
  Workspace: ~/.openclaw/workspace-hubu
  Agent dir: ~/.openclaw/agents/hubu/agent
  Model: cowbay/gpt-5.4
  Routing rules: 0
- libu
  Workspace: ~/.openclaw/workspace-libu
  Agent dir: ~/.openclaw/agents/libu/agent
  Model: cowbay/gpt-5.4
  Routing rules: 0
- bingbu
  Workspace: ~/.openclaw/workspace-bingbu
  Agent dir: ~/.openclaw/agents/bingbu/agent
  Model: cowbay/gpt-5.4
  Routing rules: 0
- xingbu
  Workspace: ~/.openclaw/workspace-xingbu
  Agent dir: ~/.openclaw/agents/xingbu/agent
  Model: cowbay/gpt-5.4
  Routing rules: 0
- gongbu
  Workspace: ~/.openclaw/workspace-gongbu
  Agent dir: ~/.openclaw/agents/gongbu/agent
  Model: cowbay/gpt-5.4
  Routing rules: 0
- libu_hr
  Workspace: ~/.openclaw/workspace-libu_hr
  Agent dir: ~/.openclaw/agents/libu_hr/agent
  Model: cowbay/gpt-5.4
  Routing rules: 0
- zaochao
  Workspace: ~/.openclaw/workspace-zaochao
  Agent dir: ~/.openclaw/agents/zaochao/agent
  Model: cowbay/gpt-5.4
  Routing rules: 0

changchichung avatar Apr 07 '26 11:04 changchichung

📜 此 Issue 已超过 60 天没有活动。 如果问题仍然存在,请回复更新状态;否则此 Issue 将在 30 天后自动关闭。 感谢你的贡献!

github-actions[bot] avatar Jun 08 '26 03:06 github-actions[bot]

🏛️ 此 Issue 因长期无活动已自动关闭。 如需重新讨论,欢迎随时重新打开或创建新 Issue。

github-actions[bot] avatar Aug 31 '26 02:08 github-actions[bot]