Skip to content

bug: a system-scoped caller of a gated skill is promised the outcome but never receives it #3233

Closed

Description

@webmixgamer

Summary

When a request names a gated skill (abilityai/trinity-enterprise#751), the MCP server turns the backend's pending_approval answer into a result whose message ends "Do not retry or route it through another agent — the outcome will be sent to you." (src/mcp-server/src/client.ts, parseGateResult). The backend tells only two kinds of requester: an agent gets a new skill_gate task, a person gets an Inbox notice. A system-scoped MCP key — the scope the system agent uses — is classified KIND_OTHER by skill_gate_service.requester_from_principal, and _notify sends it nothing. That caller is told to wait for an outcome that never arrives, and told not to retry.

Context

  • requester_from_principal (src/backend/services/skill_gate_service.py): agent_name is set only for agent-scoped keys, and X-Source-Agent is honoured only for them (dependencies.resolve_source_agent). is_person_principal accepts only the scopes in PERSON_SCOPES (None, user). A system-scoped key falls through to KIND_OTHER.
  • _notify: an agent requester gets a platform task, a person requester an Inbox notice; "Schedules, channels, public visitors, paid callers and connectors have no channel after the request". KIND_OTHER lands in that no-channel group.
  • The outcome stays on the gate record and in the executor's Executions, so a caller that knew to look could find it — the MCP message says the opposite.
  • Found while reviewing abilityai/trinity-enterprise#568, whose delegation contract reuses the "the outcome will be sent to you" wording.

Acceptance Criteria

  • A system-scoped requester is told the outcome (for example a skill_gate task to the system agent), or the pending_approval message says where to read the outcome whenever it will not be delivered
  • A test drives a system-scoped request to a gated skill and asserts the caller's path to the outcome
  • The MCP result never promises a delivery the backend does not make for that caller

Technical Notes

  • ent#715: an agent learns an outcome, never which person decided it — keep that for any new delivery channel.

Activity

  1. added
    priority-p2
    type-bug
    theme-reliability
    complexity-low
    status-ready
    on Oct 5, 2026
  2. added
    status-in-dev
    on Oct 7, 2026
  3. removed
    status-ready
    on Oct 7, 2026
  4. added a commit that references this issue on Oct 20, 2026
  5. removed
    status-in-dev
    on Oct 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    complexity-lowpriority-p2theme-reliabilitytype-bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions