Repository navigation
Conversation
Read agent.identity.get through the authenticated production client with method, read-scope, epoch and selected-agent ownership guards. Keep welcome identity independent of placement discovery and retain explicit catalog fallback. Add focused parsing, authenticated loopback, lifecycle and production bridge/provider/composer coverage. agent.wait remains out of scope; native visible proof and full validation await shared-host leases. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: needs changes before merge. What this changesThis PR resolves the selected agent’s welcome name, emoji, and avatar through the authenticated Gateway, retaining catalog identity as fallback. Example: Select the research agent whose catalog name is Fixture Research and resolved name is Resolved Research.
Review scores
ProductKind: Feature · Worth it: Yes · Fix scope: Complete Merge readiness⛔ Needs changes before merge - 1 item remains Keep this collaborator-authored draft open: it adds useful selected-agent identity behavior absent from main, and review found no concrete introduced defect. Priority: P2 Before merge
FindingsNone. Tests
Agent review detailsHow this fits togetherThe mounted chat composer passes selected-agent and connection state to a lifetime controller, which reads Gateway display metadata and supplies it to the native welcome presentation. flowchart LR
A[Selected chat agent] --> B[Composer session]
B --> C[Identity controller]
C --> D[Authenticated Gateway client]
D --> E[Gateway identity RPC]
E --> C
C --> F[Welcome presentation]
G[Placement catalog fallback] --> F
Technical reviewBest possible solution: Land the focused display-identity lookup with its existing catalog fallback and mount-local lifetime after the outstanding gates are satisfied. Do we have a high-confidence way to reproduce the issue? Current-main source directly shows catalog-only welcome identity; the supplied loopback scenario distinguishes Fixture Research from Resolved Research, but no native reproduction was independently run. Is this the best way to solve the issue? The implementation uses the existing authenticated client and composer lifetime while preserving placement and native-copy ownership, with no demonstrated need for a smaller alternative. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against e5122db3c943. Provenance checked
TestingProof path: in-process harness. SecurityNone. EvidenceWhat I checked:
Review metrics
LabelsLabel changes:
Label justifications:
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment Reviewed October 23, 2026, 6:33 PM ET / 22:33 UTC. |
Fix the task-owned architecture ledger row to use the validator-required single Type.Method reference. The selected-agent switch test remains the behavioral guard; reconnect coverage remains in the socket tests. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
|
This pull request has been automatically marked as stale due to inactivity. |
PR cleanup reviewReviewed head: The visible identity goal now substantially overlaps #2044 (2812fe5): current main already uses agent.identity.get, shows Gateway names/avatars in the welcome and transcript, and shares the current roster presentation. This PR still has distinct advertised-method/scope/epoch fencing and stricter malformed-field tests, so it is not a complete hunk-for-hunk supersession. I recommend reconciling those remaining protections into the current identity owner rather than adding a second composer-owned loader. Any closure should explicitly preserve or disposition that residual work. Action in this cleanup pass: leaving this PR open. No branch changes or runtime-proof waiver. The findings above come from source, discussion and recorded-CI review; Windows validation was not rerun in this pass. |
What Problem This Solves
The native chat welcome header uses only placement-catalog identity instead of the selected agent's resolved Gateway identity.
User Impact
User impact: the welcome header can show the selected agent's resolved name, emoji and avatar without waiting for project/environment discovery. Existing matching-agent catalog identity remains the fallback when lookup is unavailable or fails.
Draft, not ready to merge: local ARM64 build and native UI-test compilation passed, but full local suites retain one symlink-privilege failure and four ARM64 prerequisite-test failures. The first native-proof launch failed on an unsupported helper theme-setting call. After correcting that helper contract, the second launch reached readiness but its first UI command failed the owned-window foreground guard. Neither attempt produced a screenshot or visible identity proof.
Why This Change Was Made
The selected-agent read follows the pinned Apple shared request's explicit trimmed
agentIdand 10-second timeout. Windows requires an advertisedagent.identity.get, grantedoperator.readoroperator.admin, and the originating authenticated connection epoch. A mount-local controller clears identity on agent/connection changes and rejects canceled, late, foreign-agent and disposed-host results. Identity is display data, never routing or authorization authority, and does not block sends.Old owner: placement catalog as the only welcome identity source. New owner:
ChatAgentIdentityControllerplus the typed production client read;ChatComposerSessionowns lifetime, andChatWelcomePresentationapplies the resolved identity or existing fallback. Native badge geometry, Windows resources and welcome copy in all six locales are unchanged.Scope is one of two methods in the original
agentcategory:agent.identity.gethas production wiring and focused unit/authenticated-loopback evidence; native proof is still outstanding, so this PR does not make a broad verified-parity claim.agent.waitremains unimplemented/unverified. The separateagentscategory and scanner/support policy are untouched.Pinned source references, not upstream runtime proof:
Evidence
Focused checks passed: 26 Shared identity/ledger cases, 23 identity/welcome/composer Tray cases, and 54 adjacent placement/authenticated-chat Tray cases, zero failures/skips in the final focused runs. The authenticated production WebSocket client covers explicit agent parameters, capability/scope denial without dispatch, null/malformed/foreign/error replies, in-flight cancellation with a late reply, and reconnect epoch fencing. A separate non-native integration drives the actual bridge, provider, factory, composer session and welcome projection with
Resolved Research, distinct from the catalog'sFixture Research, without placement requests.Automatic CI attempt 1 failed on one task-caused architecture-ledger metadata error: two guard references had been concatenated where one
Type.Methodis required. The exact test was reproduced locally (1 failure), the ledger-only repair was pushed in080d9666, and all 26 focused Shared identity/ledger cases then passed. No guard or test was weakened. That CI attempt's successful native/MSIX/UI/Tray jobs tested merge commite6e4242e1b5dee24476df85f75bd149f18ba803d, not the new head; they do not satisfy current-head local or visible proof.Repaired-head automatic CI passed: run 40035280316, attempt 1 reports success for head
080d9666c0fb64d1f9b3e0aa61dc73668d49ad4b. Its actual checkout was PR mergea94b03e516e9572b13edb36f70a6847be27760c0(head merged intode162ba66028681700b61b5cd106323ad78aa6e8), not the later live merge ref. Shared: 4,681 passed, 8 skipped, 0 failed; Tray: 4,515 passed, 0 skipped/failed. Native x64 publish, x64/ARM64 MSIX, hosted UI/functional/accessibility, setup/connect and recovery jobs, and CI Gate all succeeded. Ordinary hosted skips do not count as custom proof. CI does not replace the expressly gated local closeout or active-state native identity screenshots.Independent narrative source/rubber-duck review covered the original
4aaa3d90implementation, transport/pending-request fault paths, tests and proof plan: no P0-P3 defects were identified in that review. The later CI-discovered ledger metadata defect above was fixed and directly checked against the existing ledger validator. One non-blocking review suggestion concerned incidental whitespace in an internal selected-agent ID; no demonstrated production path supplies such IDs, so normalization behavior was not broadened.Review limitations: the
tasktool's rubber-duck role was instructed to use source-read tools only, with no shell/build/test/app execution, edits or nested agents. It self-reported one prohibitedpowershellinvocation (git status --porcelain) that failed with a pipeline-binding error, then returned to source reads; no build/test/app execution was reported. This process deviation is disclosed, not described as a fully source-only or isolated review. Reviewer model identity was not independently verified. Canonical shared autoreview/Codex is unavailable; no installation attempted and no helper-clean stamp claimed.Change Type
Scope
winnodeRequired proof pools
windows-winui-interactive: inspect the active welcome header showing the selected agent's resolved identity, agent-switch invalidation, and fallback on the current binary. Blocked: the original Light/resolved launch failed before UI commands; the corrected helper reached readiness, but its first wrapper-driven inspect failed the foreground guard before semantic inspection, selection or capture. Compilation, configuration readback and MCP discovery are not visible proof. No Dark, fallback or research-empty native state was exercised.Validation
All local build/test checks set
$env:OPENCLAW_REPO_ROOT=(Get-Location).Path. The Oct 26 full runs also setOPENCLAW_TRAY_DATA_DIRto the task-ownedartifacts\identity-validation-080d9666\settings, align both local-data overrides to itslocalappdata, disable build-server reuse, and unset integration/GPU/E2E opt-ins. Build, Shared and Tray ran sequentially under the explicitly granted priority-13 slot; that slot was released to Usage14 after all owned commands exited and the worktree-command-line process scan returned zero.dotnet test .\tests\OpenClaw.Shared.Tests\OpenClaw.Shared.Tests.csproj --filter 'FullyQualifiedName~AgentDisplayIdentityTests|FullyQualifiedName~GatewayFixtureProtocolTests.AgentIdentity' --logger 'trx;LogFileName=agent-identity-shared.trx' --verbosity quietdotnet test .\tests\OpenClaw.Shared.Tests\OpenClaw.Shared.Tests.csproj --no-build --no-restore --filter 'FullyQualifiedName~ArchitectureLedgerConsistencyTests.Authoritative_and_closed_rows_are_guarded_or_review_only' --logger 'trx;LogFileName=agent-identity-ledger-before.trx' --verbosity quietdotnet test .\tests\OpenClaw.Shared.Tests\OpenClaw.Shared.Tests.csproj --no-build --no-restore --filter 'FullyQualifiedName~ArchitectureLedgerConsistencyTests|FullyQualifiedName~AgentDisplayIdentityTests|FullyQualifiedName~GatewayFixtureProtocolTests.AgentIdentity' --logger 'trx;LogFileName=agent-identity-shared-ledger-after.trx' --verbosity quietdotnet test .\tests\OpenClaw.Tray.Tests\OpenClaw.Tray.Tests.csproj --filter 'FullyQualifiedName~ChatAgentIdentityControllerTests|FullyQualifiedName~ChatWelcomePresentationTests|FullyQualifiedName~ChatComposerSessionTests' --logger 'trx;LogFileName=agent-identity-tray.trx' --verbosity quietdotnet test .\tests\OpenClaw.Tray.Tests\OpenClaw.Tray.Tests.csproj --no-restore --filter 'FullyQualifiedName~ChatPlacementControllerTests|FullyQualifiedName~InteractiveGatewayChatTests' --logger 'trx;LogFileName=agent-identity-related-tray.trx' --verbosity quiet.\scripts\validate-docs.ps1git --no-pager diff --checka94b03e516e9572b13edb36f70a6847be27760c0.\build.ps1080d9666: full Debug build, native Windows ARM64 outputdotnet test .\tests\OpenClaw.Shared.Tests\OpenClaw.Shared.Tests.csproj --no-restore --logger 'trx;LogFileName=identity-shared-full.trx' --results-directory (Join-Path $root 'shared') --verbosity quiet$rootis the absolute worktree-localartifacts\identity-validation-080d9666.dotnet test .\tests\OpenClaw.Tray.Tests\OpenClaw.Tray.Tests.csproj --no-restore --logger 'trx;LogFileName=identity-tray-full.trx' --results-directory (Join-Path $root 'tray') --verbosity quietdotnet build .\tests\OpenClaw.Tray.UITests\OpenClaw.Tray.UITests.csproj --no-restore -r win-arm64 -p:Platform=ARM64 --verbosity quietdotnet build .\tests\OpenClaw.Tray.UITests\OpenClaw.Tray.UITests.csproj -r win-arm64 -p:Platform=ARM64 --verbosity quietIconAPI warning in generated XAML code. Compilation only; no native tests/app launched.dotnet build $HelperProject "-p:FixtureDirectory=$FixtureBinaries" "-p:RestoreSources=$EmptyLocalRestoreSource" -p:UseSharedCompilation=false -nodeReuse:false --verbosity minimaldotnet $Helper --desktop-authorized $FixtureBinaries $FrozenApp $Artifacts Light resolved 600app.settings.setrejectedAppThemebefore identity-ready, UI commands or capture. Zero wrapper UI commands and zero PNGs; this was not a TRX native-test case. Variables replace only private absolute paths from the retained exact launcher argument array.dotnet $CorrectedHelper --desktop-authorized $FixtureBinaries $FrozenApp $FreshArtifacts Light resolved 600, then& $UiWrapper -ReadyFile $Ready -WindowHandle $OwnedHwnd -Operation inspect -ExpectedState main -TimeoutSeconds 60 -StopGraceSeconds 10 -DesktopAuthorizedForeground is not the bound task-owned window family. No activation/input attempted.One wrapper command, zero successful UI commands/selections/captures/PNGs. Inspect helper exited -532462766; after the exact printed stop file was created, normal fixture cleanup exited 0. Launcher exit 0 is not a proof pass. Variables redact only private paths and the actual run-bound HWND from the retained argument arrays.Fresh full-suite failures were inspected, not inferred from other lanes. Shared
MxcFolderAdmissionTests.OwnedJunctionAndSymbolicLinkAreRejectedWithoutFollowingTheirChildren(symbolic: True)fails at line 230 while creating its symbolic-link fixture:A required privilege is not held by the client. All fourBuildPrerequisiteTests.CheckOnly_UsesTheAppLocalRuntimeResolvercases fail at lines 85/90: the child reportsArchitecture: ARM64, sobuild.ps1bypasses the x64 resolver and emits neither expected resolver message despite the fixture'sAMD64environment override. The four cases cover absent/old/current x64 runtime versions and an arm64 runtime fixture. No privilege, runtime, prerequisite guard or test was changed. These failures remain explicit local blockers, not baseline-equivalence or all-green claims.Initial focused test compilation exposed fixture-exception visibility, an xUnit assertion analyzer rule and missing required test-fixture titles. These test-authoring errors were corrected before the successful runs above. No test was weakened or skipped.
Real Behavior Proof
080d9666c0fb64d1f9b3e0aa61dc73668d49ad4b, based one5122db3c9433f6281025f4149420183f94c71f1. Production/test sources are unchanged from4aaa3d90; only the executable ledger guard reference was corrected. The 26-case rerun used the existing non-native test binary and read the repaired ledger at runtime before commit. Source hashes are manually recorded, not a signed runner receipt or native binary binding. Earlier 23/54-case Tray runs remain associated by unchanged source, not claimed as freshly rerun.dotnet testcommands above, includingProductionBridgeProviderAndFactory_ProjectResolvedSelectedAgentFromAuthenticatedSocket.Passed! - Failed: 0, Passed: 26, Skipped: 0, Total: 26(Shared identity/ledger), andPassed! - Failed: 0, Passed: 23, Skipped: 0, Total: 23(Tray).Resolved Researchand its emoji for the explicit research agent; noprojects.list/environments.listis dispatched. Disconnect clears resolved metadata. Unit checks independently reject queued foreign/stale/disposed results and preserve matching-agent fallback.Yes/No/N/A): N/A. No screenshot or externally uploaded artifact is claimed.080d9666and worktree clean after validation. Full-buildwin-arm64\OpenClaw.Tray.WinUI.exeSHA256D979A2FB9ACFAF8152CC02997F66D1231E741434B948642C6387F9CD618FE36A, DLL5CE5B1296617AD4D33D9D28B825C1730EAFEFC90CC333B159A400F83378BAAFF, PRI84BCB5868FCA7E06B3977B5B8C9B0156AE02E90BB701342F19FD79F27DC3FD89. Product version includes full080d9666; files were produced Oct 26 at 16:37 UTC. The separate ARM64 UI-test build produced test DLL4A09A14B8664A41640229BFFAABCFB4BA547B1C82D46EDAABF3A20DD3FCB2E45and its referenced app DLLF0E50799ABC07D2014F3F9DBD6CC5B7E6E2AE588C62A36050E6E150A393A3C75at 16:46 UTC. Distinct app DLL outputs are recorded separately, not conflated. Local receipts/TRX are retained but are not public artifact links.078DD2A2723CA826931206DD371EFC76B883A892DA0BFB473473FF7C2583C5E1launched the frozen app on October 26, thenapp.settings.setreturnedSetting 'AppTheme' is not accessibleat helperProgram.cs:86. The same unsupportedsettings.getcall at line 88 was not reached. The production safe-settings allowlist deliberately excludesAppTheme; this is a helper contract error, not a demonstratedagent.identity.getfailure. No identity-ready/HWND/stop-file receipt, wrapper UI command or PNG was produced. The helper'sawait usingdisposal ran; the owner recorded both processes, listeners and isolated profile roots drained before releasing the desktop lease. That cleanup is an author observation, not independent process attestation.AppTheme = "Light"before startup. The session-helper-only correction removes the unsupported MCP calls, rejects non-Light before startup, and requires explicit Light from read-only post-start profile configuration. Only its path/hash/theme are emitted, not raw settings. The product allowlist and fixture remain unchanged. Persisted configuration is neither a launch-time byte snapshot nor rendered Light proof. Its first compilation failed because exported review copies were recursively included; byte-preserving relocation outside the helper project resolved that build-input error without source/project edits. Successful attempt 3 binds corrected helper source SHA2565C6FC31133960F593BFD6C7A6A593A2B62F3ECB848DC30313ACA53A01BEF874Cto DLLA20E8DE2A10527B0812DE6201652CCED6FD544FF1B695AD6C1B6EC7BF38691FE.NativeProof.Guard:132because the foreground window was outside the bound owned window family. No activation, global input, retry, backend substitution, selection or capture was attempted. Exactly one wrapper command ran and failed. The actual run's printed stop file was created; the launcher disposed normally. The owner recorded the app, fixture and UI-helper processes, both listeners and all four isolated profile roots absent before explicitly releasing the desktop lease. These are author-recorded drain observations, not independent process attestation.Security Impact
Yes/No): No.Yes/No): No.Yes/No): Yes.Yes/No): No.Yes/No): No.Yes, explain the risk and mitigation: adds one display-identity read per selected agent/connection lifetime through the existing authenticated transport, gated by actual advertised method and read/admin authority. Metadata cannot change routing or credentials. Avatar display reuses the existing bounded native image resolver;avatarSourceis never treated as a local path. Failure diagnostics record only the exception category, not identity payloads or credentials.Compatibility and Migration
Yes/No): Yes.Yes/No): No.Yes/No): No.Review Conversations