Skip to content

fix(id): serve caps + execution-profile frames in query sessions (#6802) - #6837

Merged
developing-today[bot] merged 1 commit into
mainfrom
queue/fallback-6802-stats-session
Nov 7, 2026
Merged

developing-today[bot] merged 1 commit into
mainfrom
queue/fallback-6802-stats-session

Conversation

@developing-today

@developing-today developing-today Bot commented Nov 7, 2026 •

Copy link
Copy Markdown
Contributor

Fixes #6802.

Problem

id world stats chains four queries over ONE connection (info_details → caps → execution_profile → metrics), but the host's query_session only served Join/Info/Metrics/Records/RecordsTicket/DownloadModule — Caps and ExecutionProfileInfo were handled only as first-frame one-shots, so the second stats query was refused with expected a query frame and the verb could never succeed against a live host.

Fix (Option 1 from the issue — the protocol-level fix)

query_session (pkgs/id/src/world_session/mod.rs) now serves both read-only frames with exactly the first-frame authorization:

  • Caps { capability }: participant-capability check (join denied), mark_authorized, caps_report() → ServerFrame::Caps (capability report unavailable on error).
  • ExecutionProfileInfo { admin_token, capability }: admin token if present, else participant capability (what the stats verb sends), else access denied; replies with the same ServerFrame::ExecutionProfile payload as the first-frame handler.

On success the session keeps looping (like Info/Metrics); on denial/error it ends the session, matching the existing query arms. The malformed-reply validation from #6624/#6636 is untouched — the client's reply decoding did not change.

Also: the #5238 stats execution test is un-ignored (with its doc comment updated), and the query_session doc comment now lists the full frame set.

Verification (laptop)

  • cargo test --test cli_integration test_world_stats_executes_against_a_live_world — passes (was #[ignore]d; spawns a live host, one committed input event).
  • cargo test --test cli_integration test_world_logs_caps_ceiling_and_profile_execute — passes (adjacent verbs unchanged).
  • cargo test --lib world_session — 62 passed.

Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

@developing-today
developing-today Bot requested review from a team and dezren39 as code owners November 7, 2026 06:31
@coderabbitai

coderabbitai Bot commented Nov 7, 2026

Copy link
Copy Markdown

Important

Review skipped

Bot user detected.

To trigger a single review, invoke the @coderabbitai review command.

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 74f4fce8-319f-4d84-ba6e-6c2aa582a035

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@developing-today
developing-today Bot merged commit afa224f into main Nov 7, 2026
8 checks passed
@developing-today
developing-today Bot deleted the queue/fallback-6802-stats-session branch November 7, 2026 06:35
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.

id world stats fails against a live host: "expected a query frame" (caps/profile frames refused mid-session)

0 participants