Repository navigation
fix(activity): histogram≙log parity, status-aware tray grouping, code-exec sub-call transparency - #1016
Merged
Conversation
…-exec sub-call transparency - Histogram now counts internal tool calls (retrieve_tools/describe_tool/code_execution/…) and blocked policy decisions, matching the tray glance population; call_tool_* variant echoes excluded everywhere (list + histogram) since every one pairs with a canonical record - Usage aggregate replays activity records newer than the persisted snapshot on startup (no more permanent drift after unclean shutdown); internal calls now reach the live aggregate - /activity/summary computes over the full period, not the newest 50 records - code_execution: ExecutionID pass-by-value bug fixed; every sandbox sub-call now emits a first-class tool_call activity record with fresh request_id + parent_id linkage - parent_id: new ActivityRecord field, list/export filter, swagger, SSE passthrough - Web UI: parent/child badges, View sub-calls / View parent navigation in Activity drawer - CLI: activity list/export --parent-id, child markers in table+watch, show hints, docs - Tray: run grouping key now includes status class — ok and errored calls never merge; spec 090 FR-002/FR-004 amended; parent_id decoded Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…der count countsTowardUsageTimeline still counted only tool_call records, so internal calls (code_execution, retrieve_tools) and blocked policy decisions moved the bars at the next poll but not the header — the header lagged the rows by up to 30s. Now mirrors UsageAggregate.Apply case-for-case (internal non-call_tool_* count, rejected tool_call sheds and call_tool_* echoes stay out, blocked and rejected policy decisions count). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Deploying mcpproxy-docs with
|
| Latest commit: |
862f3d2
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://837edecb.mcpproxy-docs.pages.dev |
| Branch Preview URL: | https://fix-activity-transparency.mcpproxy-docs.pages.dev |
|
Codecov Report❌ Patch coverage is 📢 Thoughts on this report? Let us know! |
…lance-set parity, sandbox shed/refusal records Opencode cross-review of #1016 surfaced four genuine defects: - Snapshots built under the old admission rule (no internal calls) were carried forward after upgrade; aggregates now stamp an AdmissionVersion and a mismatched snapshot is rebuilt from a full activity scan (decode clears the constructor default so legacy snapshots can't masquerade as current; clone() now carries the stamp). - Successful management built-ins (upstream_servers, quarantine_security, …) entered the timeline but are not glance rows; admission now counts internal successes only for retrieve_tools/describe_tool/code_execution, failures always. Swift live-count mirror updated in lockstep. - A concurrency shed inside a sandbox sub-call was double-recorded: the limiter's origin-independent observer already emits the canonical rejected record, so emitSubCallActivity now skips limiter sheds. - A sandbox policy refusal was recorded as an executed error call; it is now status=blocked, and blocked tool_calls route like blocked policy decisions (Blocked counter + failed timeline bar, no Calls/latency/bytes). Known accepted trade-offs (documented in code): the catch-up replay's strict timestamp bound can miss a record whose Apply lagged its Save across a crash (the alternative is permanent double-counting), and startup rejected-shed recording is synchronous by design. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…s, narrow the sandbox shed skip - Management built-ins (upstream_servers, quarantine_security) are hidden from the glance whatever their status (GlanceSelection rule 1), so their failures must not bar either; Go admission and the Swift live-count mirror now exclude them entirely (non-management internal failures still count). - emitSubCallActivity skipped every limiter error, but only queue_full/ queue_timeout sheds get the canonical rejected record from the admission observer — a server_unavailable refusal lost its only activity record. The skip (shedHasCanonicalRecord, unit-tested) is now reason-scoped. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…ange Round-3 review: the round-2 admission narrowing (management built-ins out) changed which records count, so snapshots stamped 2 must rebuild too. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Contributor
📦 Build ArtifactsWorkflow Run: View Run Available Artifacts
How to DownloadOption 1: GitHub Web UI (easiest)
Option 2: GitHub CLI gh run download 32505815696 --repo smart-mcp-proxy/mcpproxy-go
|
… window User feedback on #1016: the native Activity window had no way to walk from a code_execution to its sub-calls or back, and the code argument rendered as an escaped one-line JSON string. - Detail panel: 'View sub-calls' on code_execution parents filters the list by parent_id (with a dismissable chip); sub-call records show 'View parent call', which restores the list and selects the parent (fetched by request_id and pinned if it scrolled past the page). - List rows: sub-calls carry an arrow marker in the Details column. - Detail panel: the code argument renders as a Code section (language badge, monospace); one-line agent scripts are broken at statement boundaries — never inside string literals or parens (formatScriptForDisplay, unit-tested). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…b-call filter - loadActivities now publishes only the newest in-flight fetch (monotonic ticket), so a slow unfiltered load can't overwrite the sub-call view. - Entering the sub-call view drops the parent's selection so clearing the chip doesn't silently reopen its detail panel. - formatScriptForDisplay documents its display-only limits (regex literals, nested template substitutions); Copy always yields the verbatim script. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Docs audit findings (PR #1016): drop the stale 'failed call_tool_* are always shown' claims (all call_tool_* records are hidden by default now — every dispatch has a paired canonical record), add the parent_id query param to the REST + feature docs, document code_execution sub-call records and their parent/child navigation, and note sub-call activity logging in the code-execution security model. Spec audit: no normative amendments needed — spec 096 FR-010 (sub-calls recorded in activity logging) is fulfilled by this PR, spec 090 was amended in-branch, spec 093's rejected-shed exclusion is preserved. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…contract Spec audit for PR #1016: two normative statements were made stale by this PR. Spec 024's note claimed failed call_tool_* records are the sole witness of a failed dispatch (they are paired now, and hidden by default); spec 069's usage contract said the timeline excludes blocked attempts (it now mirrors the glance population). Both amended with superseded notes. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Dumbris
added a commit
that referenced
this pull request
Aug 22, 2026
…1023) The status-bar menu had grown long enough to scroll, which is the opposite of a glance, and the glance itself spent a row on an internal primitive. Menu length (3 rows back): - Drop the grey, disabled "N quarantined server(s)" line — Needs Attention already carries that fact, and actionably. - Drop "Report an Issue…" — the tracker is still reachable through the GitHub link in the About panel's credits. - Move "Add Server..." into the Servers submenu as its first item (Cmd+N still matches; performKeyEquivalent recurses into submenus). It stays at the top level only when there are no servers and therefore no submenu to hold it, so adding the first server is never unreachable. code_execution is an internal primitive, not a call the user made. Since its sub-calls became tool_call records of their own (#1016), they show the REAL work — "jira:get_issue ×3" — where the wrapper row said only "code_execution", naming no server and no tool. A SUCCESSFUL wrapper now rows in neither the tray glance nor the shared usage timeline; a FAILED one still does, through rule 3's failure branch, because a script that died before dispatch has no children to speak for it. Kept in lockstep: GlanceSelection.glanceInternalTools (Swift), AppState.countsTowardUsageTimeline (follows the same set), and runtime.glanceInternalTools (Go). usageAdmissionVersion 3 → 4 so snapshots counted under the old rule are rebuilt instead of carried forward. The Web UI activity list still shows code_execution parents — it is the drill-down home for a script — so the parity test now models the glance as the list filter plus the glance's own narrowing rather than equating the two. Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes three user-reported activity-log defects (tray screenshot triage, 2026-08-21).
1. Tray histogram didn't correspond to the call log
2. OK and errored calls collapsed into one tray run
`GlanceRun.Key` gains a status class — consecutive success and error calls to the same tool split into separate runs, so a red "×N" never counts successes. Spec 090 FR-002/FR-004 amended; `worstStatus` collapsed to `status` (runs are homogeneous now).
3. code_execution sub-calls invisible in the activity log (transparency principle)
QA (all against real local MCP calls — everything server, isolated instance)
Known follow-ups (deliberate non-changes)
🤖 Generated with Claude Code