openclaw / openclaw/openclaw-windows-node

[Bug]: usage.cost / commands.list / sessions.create fail with "session key 'main' has no explicit owner" on multi-agent gateways

Open
#1,345 1 comment 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

clawsweeper:needs-live-repro clawsweeper:needs-maintainer-review clawsweeper:needs-product-decision clawsweeper:no-new-fix-pr impact:ux-friction issue-rating: 🐚 platinum hermit P1
Dominant language
C#
Stars
2.1k
Forks
295
Avg merge
1d 6h
Merged PRs (30d)
99

Description

Bug type: Behavior bug
Beta release blocker: No

Summary
Windows Companion v2026.7.1-4 paired to a multi-agent gateway (core 2026.9.x,
agents.ownership: "explicit") sends bare session key "main" (no agent
prefix) on several RPCs. Since the Aug-2026 multi-agent ownership change in
core, the gateway fail-closes ownerless requests with "no explicit owner".

Steps to reproduce

  1. Configure a gateway with multiple agents and agents.ownership: "explicit".
  2. Pair Windows Companion v2026.7.1-4 (stable, build 2026-09-03).
  3. Open Usage, Command Center, or create a new session (triggers
    usage.cost, commands.list, sessions.create).

Expected behavior
RPCs resolve the current agent from context and send an agent-prefixed session
key (agent:<id>:...), or expose an agent picker when ambiguous.

Actual behavior
usage.cost, commands.list, and sessions.create all fail with
INVALID_REQUEST / "session key "main" has no explicit owner". sessions.list,
models.list, health succeed; chatting in an existing agent-prefixed session
from the list works.

Environment

  • OpenClaw version: Companion v2026.7.1-4 (stable) / core 2026.9.x
  • Operating system: Windows 10.0.26200.0 (x64)
  • Install method: Windows Companion stable (unpackaged)
  • Provider/routing chain: local gateway via wss:// (nginx TLS termination)

Logs

⇄ res ✗ usage.cost 40ms errorCode=INVALID_REQUEST
  errorMessage=Multiple agents are configured, but session key "main" has no explicit owner. Pass agentId or use an agent-prefixed session key.
⇄ res ✗ sessions.create 12ms errorCode=INVALID_REQUEST
  errorMessage=Multiple agents are configured, but session key "main" has no explicit owner. Pass agentId or use an agent-prefixed session key.
⇄ res ✗ commands.list 6ms errorCode=INVALID_REQUEST
  errorMessage=Multiple agents are configured, but this Gateway request has no explicit owner. Set agentId to one of the configured agents.

Likely cause (source, v2026.7.1-4)

  • Windows/HubWindow.xaml.cs:37_currentAgentId = "main"
  • A2UI/Actions/GatewayActionTransport.cs:100-102 — bare "main" session-key fallback
  • Services/NodeService.cs:1768-1773_sessionKey = "main" default
  • Chat/ChatSnapshotProjector.cs:39, Services/AppState.cs:243"main" fallbacks
  • New-session path sends only ParentSessionKey, no AgentId

Impact and severity

  • Affected: Windows Companion users with multi-agent gateways
  • Severity: Medium (blocks Usage / Command Center / New Session; chat unaffected)
  • Frequency: always
  • Consequence: those surfaces are unusable on multi-agent gateways

Additional information

  • Same ownerless-request class is being fixed in core: openclaw/openclaw #138369, #138341, #139222
  • Adjacent: openclaw/openclaw-windows-node #1271 (no "New Session"/agent picker)
  • The Control UI GitHub-connections page shows the same class of error ("this operation has no explicit owner") on this gateway

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with Windows/HubWindow.xaml.cs, A2UI/Actions/GatewayActionTransport.cs, Services/NodeService.cs, Chat/ChatSnapshotProjector.cs, and Services/AppState.cs to trace how the current agent and session key are selected. Reproduce the Usage, Command Center, and New Session RPCs against a multi-agent gateway, then verify each request carries an explicit owner or presents an agent choice and no longer returns the reported INVALID_REQUEST errors.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
desktop
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
58/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.