Skip to content

fix(install): openclaw.json 被极简化自愈(健康检查 + 更新路线也调) - #450

Merged
bigbrother666sh merged 1 commit into
TeamWiseFlow:masterfrom
bigbrother666sh:master
Jul 21, 2026
Merged

fix(install): openclaw.json 被极简化自愈(健康检查 + 更新路线也调)#450
bigbrother666sh merged 1 commit into
TeamWiseFlow:masterfrom
bigbrother666sh:master

Conversation

@bigbrother666sh

Copy link
Copy Markdown
Member

根因

重跑时 ~/.openclaw/openclaw.json 已存在(openclaw 首启自动生成的极简 config,缺 models/agents.defaults)→ is_update=true → 更新路线不调 place_config_template → 极简 config 永远留着,agent 没有模型,半残。

.bak 环里最老那版就已经是极简的,说明完整 template 从没落过盘。tarball 里的 template 是完整的(已验:13 个顶层 key、有 models、3 agent)。

  • place_config_template 加健康判定:现有 config 必须同时有 models + agents.defaults 才算健康;不健康 / 不存在 / --force → 用 template 覆盖(旧文件备份到 .bak.<ts>)。template 缺失改报错(原来静默 no-op)。
  • 更新路线开头也调 place_config_template(新增 'Checking config health' stage),被极简化的 config 重跑就自愈;健康则保留不动。
  • 更新步数 9→10。README step 8 同步改描述。

合后请触发 build-dist 重建 v5.6.0(Auto Release 已临时禁用)。

根因:重跑时 ~/.openclaw/openclaw.json 已存在(openclaw 首启自动生成的极简
config,缺 models/agents.defaults)→ is_update=true → 更新路线不调
place_config_template → 极简 config 永远留着,agent 没有模型,半残。
.bak 环里最老那版就已经是极简的,说明完整 template 从没落过盘。

修:
- place_config_template 加健康判定:现有 config 必须同时有 models +
  agents.defaults 才算健康;不健康 / 不存在 / --force → 用 template 覆盖
  (旧文件备份到 .bak.<ts>)。template 缺失改报错(原来静默 no-op)。
- 更新路线开头也调 place_config_template(新增 'Checking config health'
  stage),这样被极简化的 config 重跑就能自愈;健康则保留不动。
- 更新步数 9→10。README step 8 同步改描述(去掉已删的运行时预填,加自愈说明)。
@bigbrother666sh
bigbrother666sh merged commit 9140266 into TeamWiseFlow:master Jul 21, 2026
2 checks passed
@CLAassistant

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


codes-factory-of-bg seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

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.

2 participants