Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@Glucksberg
Copy link
Contributor

Summary

  • Exposes the existing config.patch server method to agents via the gateway tool
  • Allows safe partial config updates that merge with existing config instead of replacing it entirely
  • Adds restart + sentinel logic to config.patch server method (matching config.apply behavior)
  • Extends ConfigPatchParamsSchema with sessionKey, note, restartDelayMs parameters

This prevents agents from accidentally wiping user configurations when they only intend to make partial updates.

Closes #1617

Test plan

  • Build passes (pnpm build)
  • Lint passes (pnpm lint)
  • Gateway tool unit tests pass (4/4 including new config.patch test)
  • Manual testing of config.patch via gateway tool

🤖 Generated with Claude Code

Glucksberg and others added 2 commits January 24, 2026 18:57
The save button in the Control UI config editor was not properly gating
on whether actual changes were made. This adds:
- `configRawOriginal` state to track the original raw config for comparison
- Change detection for both form mode (via computeDiff) and raw mode
- `hasChanges` check in canSave/canApply logic
- Set `configFormDirty` when raw mode edits occur
- Handle raw mode UI correctly (badge shows "Unsaved changes", no diff panel)

Fixes openclaw#1609

Co-Authored-By: Claude Opus 4.5 <[email protected]>
…pdates

Exposes the existing config.patch server method to agents, allowing safe
partial config updates that merge with existing config instead of replacing it.

- Add config.patch to GATEWAY_ACTIONS in gateway tool
- Add restart + sentinel logic to config.patch server method
- Extend ConfigPatchParamsSchema with sessionKey, note, restartDelayMs
- Add unit test for config.patch gateway tool action

Closes clawdbot#1617
@steipete steipete merged commit 6066144 into openclaw:main Jan 24, 2026
19 of 22 checks passed
steipete added a commit that referenced this pull request Jan 24, 2026
* fix: land config.patch restarts/docs/tests (#1624) (thanks @Glucksberg)

* docs: update changelog entry for config.patch follow-up (#1653) (thanks @Glucksberg)
@steipete
Copy link
Contributor

Landed via temp rebase onto main.

Thanks @Glucksberg!

mcinteerj pushed a commit to mcinteerj/moltbot that referenced this pull request Jan 25, 2026
…pdates (openclaw#1624)

* fix(ui): enable save button only when config has changes

The save button in the Control UI config editor was not properly gating
on whether actual changes were made. This adds:
- `configRawOriginal` state to track the original raw config for comparison
- Change detection for both form mode (via computeDiff) and raw mode
- `hasChanges` check in canSave/canApply logic
- Set `configFormDirty` when raw mode edits occur
- Handle raw mode UI correctly (badge shows "Unsaved changes", no diff panel)

Fixes openclaw#1609

Co-Authored-By: Claude Opus 4.5 <[email protected]>

* feat(gateway-tool): add config.patch action for safe partial config updates

Exposes the existing config.patch server method to agents, allowing safe
partial config updates that merge with existing config instead of replacing it.

- Add config.patch to GATEWAY_ACTIONS in gateway tool
- Add restart + sentinel logic to config.patch server method
- Extend ConfigPatchParamsSchema with sessionKey, note, restartDelayMs
- Add unit test for config.patch gateway tool action

Closes openclaw#1617

---------

Co-authored-by: Claude Opus 4.5 <[email protected]>
mcinteerj pushed a commit to mcinteerj/moltbot that referenced this pull request Jan 25, 2026
* fix: land config.patch restarts/docs/tests (openclaw#1624) (thanks @Glucksberg)

* docs: update changelog entry for config.patch follow-up (openclaw#1653) (thanks @Glucksberg)
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.

feat(gateway-tool): Add config.patch action for safe partial config updates

2 participants