Skip to content

feat(compliance): scoping lint exempts ID-scoped tasks (#2577 Option C)#2578

Merged
bokelley merged 1 commit into
mainfrom
bokelley/scoping-lint-exempt-id-tasks
Apr 20, 2026
Merged

feat(compliance): scoping lint exempts ID-scoped tasks (#2577 Option C)#2578
bokelley merged 1 commit into
mainfrom
bokelley/scoping-lint-exempt-id-tasks

Conversation

@bokelley

Copy link
Copy Markdown
Contributor

Summary

Implements the lint-classification half of #2577 Option C. Seven tasks whose request schema requires a globally-unique scope-ID move from TENANT_SCOPED_TASKS to EXEMPT_FROM_LINT.

Task Required scope-ID
check_governance plan_id
report_plan_outcome plan_id
acquire_rights rights_id + buyer + campaign
log_event event_source_id
calibrate_content standards_id
validate_content_delivery standards_id
validate_property_delivery list_id (schema also has optional account)

At the spec level, the seller resolves the ID → tenant via its own lookup. Envelope account is redundant.

What this PR does not do

Why the split matters for future authors

Before this PR the rule was "tenant-scoped at the handler level ⇒ require envelope identity." After: "required globally-unique scope-ID in schema ⇒ seller resolves by ID, lint doesn't require envelope identity."

The second rule maps cleanly to how a production seller works: auth context identifies the principal, plan_id/rights_id/standards_id identifies the scoped resource, envelope account is either absent or optional. The first rule was a sandbox artifact.

The authoring guide (docs/contributing/storyboard-authoring.md) documents the rule-of-thumb, the three exempt sub-buckets, and explicitly warns authors not to drop envelope identity on exempt tasks until the runtime side of #2577 lands.

Test plan

  • npm run build:compliance (scoping lint + build)
  • npm run test:storyboard-scoping (parity test — 3/3)
  • npm run test:schemas (7/7)
  • SEO metadata check (253/253, exit 0)

Related

🤖 Generated with Claude Code

Seven tasks whose request schema requires a globally-unique scope-ID
move from TENANT_SCOPED_TASKS to EXEMPT_FROM_LINT:

- check_governance, report_plan_outcome  — required plan_id
- acquire_rights                         — required rights_id + buyer + campaign
- log_event                              — required event_source_id
- calibrate_content                      — required standards_id
- validate_content_delivery              — required standards_id
- validate_property_delivery             — required list_id (schema also has
                                            optional account)

At the spec level, the seller resolves the ID → tenant via its own lookup —
envelope account is redundant. Per #2577 Option C.

Authoring-guide update (docs/contributing/storyboard-authoring.md)
documents the new rule-of-thumb ("required globally-unique scope-ID ⇒
exempt") and the three exempt sub-buckets, and is explicit that storyboards
should keep carrying envelope identity today because sessionKeyFromArgs
still routes by it — the lint just stops enforcing what the spec doesn't
require. Runtime-side alignment (resolve by ID) remains tracked in #2577.

Parity test + scoping lint + build:compliance + test:schemas pass.
Storyboards unchanged; the 7 exempt tasks already carry identity from
earlier work.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown
Contributor

Schema Link Check Results

Commit: fbd58c1 - feat(compliance): scoping lint exempts ID-scoped tasks (#2577 Option C)

⚠️ Warnings (schema not yet released)

These schemas exist in source but haven't been released yet. The links will be broken until the next version is published:

  • https://adcontextprotocol.org/schemas/v3/enums/specialism.json
    • Schema exists in latest (source) but not yet released in v3
    • Action: This link will work after next 3.x release is published

To fix: Either:

  1. Wait for the next release and merge this PR after the release is published
  2. Use latest instead of a version alias if you need the link to work immediately (note: latest is the development version and may change)
  3. Coordinate with maintainers to cut a new release before merging

@bokelley
bokelley merged commit b4e8ddf into main Apr 20, 2026
16 checks passed
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.

1 participant