Skip to content

Fix pairing loop after 2026.2.19: operator.admin satisfies operator.write#23125

Merged
vignesh07 merged 2 commits intomainfrom
fix/pairing-admin-satisfies-write
Feb 22, 2026
Merged

Fix pairing loop after 2026.2.19: operator.admin satisfies operator.write#23125
vignesh07 merged 2 commits intomainfrom
fix/pairing-admin-satisfies-write

Conversation

@vignesh07
Copy link
Contributor

@vignesh07 vignesh07 commented Feb 22, 2026

Fixes #23006.

Regression:

  • In 2026.2.19+ we introduced operator.read/operator.write scopes.
  • Legacy paired devices may have operator.admin but not operator.write.
  • Gateways treat operator.admin as satisfying operator.read, but not operator.write, so operator.write requests trigger repeated scope-upgrade pairing loops.

Fix:

  • Update operator scope compatibility so operator.write is satisfied by operator.write OR operator.admin.

Tests:

  • Update unit tests for roleScopesAllow
  • Add/adjust device-pairing verifyDeviceToken test to ensure operator.admin allows operator.write

Greptile Summary

Fixes pairing loop regression from 2026.2.19 where legacy devices with operator.admin scope triggered repeated pairing when requesting operator.write access. The change adds scope compatibility logic in operatorScopeSatisfied() at src/shared/operator-scope-compat.ts:25-26 so operator.admin satisfies operator.write requests, mirroring the existing behavior for operator.read.

The fix is minimal and correct:

  • Logic change is 2 lines in the core compatibility function
  • Tests verify both operator.read and operator.write are satisfied by operator.admin tokens
  • Device pairing test confirms the end-to-end flow works correctly

Issue: Missing CHANGELOG entry. This is a user-facing bug fix (resolves #23006 pairing loop) and per repository guidelines should have a changelog entry in the Fixes section. The CHANGELOG only has an unrelated attribution update on line 19.

Confidence Score: 5/5

Last reviewed commit: e99592d

@openclaw-barnacle openclaw-barnacle bot added size: XS maintainer Maintainer-authored PR labels Feb 22, 2026
Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

4 files reviewed, 1 comment

Edit Code Review Agent Settings | Greptile

### Fixes

- Memory/QMD: add optional `memory.qmd.mcporter` search routing so QMD `query/search/vsearch` can run through mcporter keep-alive flows (including multi-collection paths) to reduce cold starts, while keeping searches on agent-scoped QMD state for consistent recall. (#19617) Thanks @vignesh07.
- Memory/QMD: add optional `memory.qmd.mcporter` search routing so QMD `query/search/vsearch` can run through mcporter keep-alive flows (including multi-collection paths) to reduce cold starts, while keeping searches on agent-scoped QMD state for consistent recall. (#19617) Thanks @nicole-luxe and @vignesh07.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add a changelog entry for the pairing loop fix (the main purpose of this PR). user-facing bug fixes should be documented in the changelog per AGENTS.md guidelines.

Suggested change
- Memory/QMD: add optional `memory.qmd.mcporter` search routing so QMD `query/search/vsearch` can run through mcporter keep-alive flows (including multi-collection paths) to reduce cold starts, while keeping searches on agent-scoped QMD state for consistent recall. (#19617) Thanks @nicole-luxe and @vignesh07.
- Device pairing: treat `operator.admin` scope as satisfying `operator.write` requests to prevent pairing loops for legacy devices upgraded from pre-2026.2.19 releases. (#23006)
- Memory/QMD: add optional `memory.qmd.mcporter` search routing so QMD `query/search/vsearch` can run through mcporter keep-alive flows (including multi-collection paths) to reduce cold starts, while keeping searches on agent-scoped QMD state for consistent recall. (#19617) Thanks @nicole-luxe and @vignesh07.
Prompt To Fix With AI
This is a comment left during a code review.
Path: CHANGELOG.md
Line: 19

Comment:
add a changelog entry for the pairing loop fix (the main purpose of this PR). user-facing bug fixes should be documented in the changelog per `AGENTS.md` guidelines.

```suggestion
- Device pairing: treat `operator.admin` scope as satisfying `operator.write` requests to prevent pairing loops for legacy devices upgraded from pre-2026.2.19 releases. (#23006)
- Memory/QMD: add optional `memory.qmd.mcporter` search routing so QMD `query/search/vsearch` can run through mcporter keep-alive flows (including multi-collection paths) to reduce cold starts, while keeping searches on agent-scoped QMD state for consistent recall. (#19617) Thanks @nicole-luxe and @vignesh07.
```

How can I resolve this? If you propose a fix, please make it concise.

@vignesh07 vignesh07 force-pushed the fix/pairing-admin-satisfies-write branch from e99592d to c3b5c95 Compare February 22, 2026 01:58
@vignesh07 vignesh07 merged commit 5b4409d into main Feb 22, 2026
10 checks passed
@vignesh07 vignesh07 deleted the fix/pairing-admin-satisfies-write branch February 22, 2026 02:25
@vignesh07
Copy link
Contributor Author

Landed via temp rebase onto main.

  • Gate: pnpm lint && pnpm build (local) + pnpm test (user-run)
  • Land commit: 5b4409d
  • Merge commit: 5b4409d

Thanks @vignesh07!

ahdernasr pushed a commit to ahdernasr/openclaw that referenced this pull request Feb 22, 2026
obviyus pushed a commit to guirguispierre/openclaw that referenced this pull request Feb 22, 2026
00xglitch pushed a commit to 00xglitch/openclaw that referenced this pull request Feb 22, 2026
00xglitch pushed a commit to 00xglitch/openclaw that referenced this pull request Feb 23, 2026
7Sageer pushed a commit to 7Sageer/openclaw that referenced this pull request Feb 23, 2026
gabrielkoo pushed a commit to gabrielkoo/openclaw that referenced this pull request Feb 23, 2026
mreedr pushed a commit to mreedr/openclaw-custom that referenced this pull request Feb 24, 2026
00xglitch pushed a commit to 00xglitch/openclaw that referenced this pull request Feb 24, 2026
00xglitch pushed a commit to 00xglitch/openclaw that referenced this pull request Feb 24, 2026
00xglitch pushed a commit to 00xglitch/openclaw that referenced this pull request Feb 24, 2026
hughdidit pushed a commit to hughdidit/DAISy-Agency that referenced this pull request Mar 1, 2026
(cherry picked from commit 5b4409d)

# Conflicts:
#	CHANGELOG.md
#	src/infra/gateway-lock.test.ts
#	src/memory/qmd-manager.test.ts
hughdidit pushed a commit to hughdidit/DAISy-Agency that referenced this pull request Mar 3, 2026
(cherry picked from commit 5b4409d)

# Conflicts:
#	CHANGELOG.md
#	src/infra/gateway-lock.test.ts
#	src/memory/qmd-manager.test.ts
zooqueen pushed a commit to hanzoai/bot that referenced this pull request Mar 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maintainer Maintainer-authored PR size: S

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] 2026.2.19 upgrade breaks tool connections — missing operator.write and operator.read scopes on existing paired devices

1 participant