Skip to content

allowed-tools drifts from skill body when mechanism changes — add a deterministic lint gate; fix discover-agents (mcp__trinity__report), trim orchestrate's vestigial schedule tools #7

Description

@vybe

Summary

allowed-tools frontmatter drifts out of sync with skill bodies when a skill's mechanism changes but its tool list isn't updated. Under enforcement, a body call to an undeclared tool is silently blocked. Reported by corbin (Item 1): orchestrate v1.7/1.8 rewired its watchdog onto set_reminder/cancel_reminder (trinity#1296) but its allowed-tools still listed only the old schedule tools.

Status of the reported instance: already fixed in HEAD

The orchestrate defect corbin hit was fixed upstream in orchestrate v1.11 / bundle v1.18 ("allowed-tools gains … the set_reminder/cancel_reminder the v1.7 watchdog already instructs"). Current bundle (v1.20, orchestrate v1.13) declares both reminder tools. Corbin diagnosed correctly against their cached bundle (v1.15), which predated the fix — every install of v1.14/v1.15 has it, current installs do not. list_reminders is not used in the body, so it does not need adding.

But the audit corbin asked for found a live same-class drift

I ran an allowed-tools-vs-body sweep across all eight bundle skills. One genuine hit:

  • discover-agents v1.7 calls mcp__trinity__report(...) (fleet_scan) in its body, but mcp__trinity__report is absent from its allowed-tools. The call is wrapped in a guard that swallows tool-not-found/permission errors, so it degrades gracefully — but under enforcement the fleet_scan report silently never publishes. Lower severity than the orchestrate watchdog (that was a safety fallback failing silently), but the same defect class.

Minor hygiene in the same pass:

  • orchestrate v1.13 still lists the three vestigial schedule tools (create_agent_schedule, delete_agent_schedule, list_agent_schedules) — zero positive body usage remains since the v1.7 watchdog moved fully to set_reminder. Safe to drop (least-privilege).

Proposed work

  1. Fix discover-agents: add mcp__trinity__report to allowed-tools (v1.7→1.8).
  2. Trim orchestrate: drop the three unused schedule tools (v1.13→1.14).
  3. The durable fix — add an allowed-tools↔body lint as a deterministic /audit-wizards + /test-wizard gate: every mcp__trinity__* (and reserved tool) invoked in a skill body must appear in allowed-tools. This is what turns "someone hand-diffed eight skills and caught it" into "caught before publish." (An over-declared-tools warning — declared-but-unused — is a nice-to-have advisory, not a blocker.)

Version bumps, changelog, bundle bump, /audit-wizards green; push operator-gated.

Filed by trinity-pm on behalf of corbin's report. Verdict: adopt the generalizing gate + the discover-agents fix; the orchestrate reminder-tools defect is already resolved upstream.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions