Skip to content

fix(release): allow non-selectable schema statuses in discovery test - #6043

Merged
bokelley merged 1 commit into
mainfrom
fix/schema-release-status-test
Jul 27, 2026
Merged

fix(release): allow non-selectable schema statuses in discovery test#6043
bokelley merged 1 commit into
mainfrom
fix/schema-release-status-test

Conversation

@bokelley

Copy link
Copy Markdown
Contributor

Summary

  • allow exact stable-semver artifacts to carry withdrawn or unpublished discovery status
  • keep prerelease: false for those exact artifacts
  • strengthen alias and latest_stable assertions so every selectable target must resolve to a discovered entry with stability: stable

Why

The 3.1.6 release audit exposed a stale assertion in test:dist-schema-version-ids: 3.1.3 is intentionally preserved as an exact-addressable withdrawn artifact, but the test still required every stable-semver directory to report stability: stable. This contradicted the release-status behavior added in #5913.

Validation

  • npm run test:dist-schema-version-ids — 2/2 passed
  • npx vitest run tests/schema-release-status.test.ts — 2/2 passed
  • precommit suite — 1,022 repo unit tests, dynamic-import lint, callApi lint, and TypeScript typecheck passed
  • git diff --check — passed

No changeset: test-only release tooling correction; no protocol surface change.

@aao-secretariat aao-secretariat Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Clean fix. Loosens the per-directory stability assertion to match the release-status model from #5913 while tightening the invariant that actually matters — selectable targets must resolve to a discovered, stable entry. Fail-closed beats fail-open.

Things I checked

  • The three accepted stability values are real, not phantom. scripts/build-schemas.cjs:44-45 defines exactly ['3.1.3', 'withdrawn'] and ['3.2.0', 'unpublished']; the loosened check at tests/dist-schema-version-ids.test.cjs:104 accepts ['stable', 'withdrawn', 'unpublished']. No fourth status can slip through — the assert.ok fails closed with the offending value in the message.
  • The prerelease: false assertion that survives the loosening still holds for both non-stable statuses. build-schemas.cjs:145 (withdrawn) and :153 (unpublished) both emit prerelease: false, so keeping assert.equal(entry.prerelease, false) on every stable-semver dir is correct, not accidental.
  • assertSelectableStableTarget is a net strengthening, not a loosening. Before this PR, alias targets were only regex-matched against the stable-semver shape; nothing verified the target resolved to a discovered entry with stability: stable. Now latest_stable and every alias must resolve through entriesByVersion to a stable, non-prerelease entry — so an alias pointing at withdrawn 3.1.3 would fail. That is the exact hole the 3.1.6 audit exposed.
  • Lineage checks out: #5913 is fix(release): preserve schema release status, and the test was the stale half of that behavior.

Follow-ups (non-blocking — file as issues)

  • None.

Minor nits (non-blocking)

  1. Redundant-but-harmless double check on aliases. tests/dist-schema-version-ids.test.cjs:85 keeps assert.match(version, stableVersion, ...) and :86 adds assertSelectableStableTarget(version, alias). The helper's entriesByVersion lookup plus stability: stable subsumes most of what the regex proves. Not worth a change — the regex gives a sharper failure message for the malformed-alias case.

No changeset required — test-only release-tooling correction, no static/schemas/source/** or wire surface touched. Validation in the PR body (dist-schema-version-ids 2/2, schema-release-status 2/2, precommit suite green) covers the path being changed.

Approving on the strength of the generator/test coherence check plus the alias-resolution tightening.

@bokelley
bokelley merged commit 12c3976 into main Jul 27, 2026
14 checks passed
@bokelley
bokelley deleted the fix/schema-release-status-test branch July 27, 2026 17:40
bokelley added a commit that referenced this pull request Jul 27, 2026
Backport #6043 so the 3.1.6 release audit accepts exact withdrawn artifacts while continuing to reject non-selectable alias targets.
bokelley added a commit that referenced this pull request Jul 28, 2026
* fix(delivery-metrics): allow null for video-only metrics (quartile_data, completion_rate) (#5837)

* fix(delivery-metrics): allow null for video-only metrics (quartile_data, completion_rate)

Sellers running non-video inventory (display, audio-only, DOOH-without-video)
legitimately return null for video-only metrics — the correct "not applicable"
signal. The schema required type:"number"/"object" and rejected null, so
receivers throw a validation error on every valid display-inventory delivery
report.

- delivery-metrics.json: completion_rate -> ["number","null"], quartile_data
  -> ["object","null"] (min/max on completion_rate still apply to non-null).
- get-media-buy-delivery-response.json: aggregated_totals.completion_rate gets
  the same loosening so the aggregate path can't re-trigger the failure.
- Docs: scope the null convention to these two fields; omission remains the
  canonical "not applicable" signal for every other metric.

Refs Sentry AGENTIC-API-9P (87 events/5 days; PubX, BidMachine, Ozone, Vox).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

* fix(docs): escape bare < in spec-guardian so Mintlify link check parses it

'overturn <5%' parsed as a JSX tag open (< before a digit), failing the
Mintlify broken-links check that runs on any docs change. Escape to &lt;5%.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
# Conflicts:
#	specs/spec-guardian.md

* chore(ci): add 3.1.x to release and CI workflow branch filters

Enables the Release workflow, Build Check, Changeset Check, and CodeQL
to fire on pushes and PRs targeting the 3.1.x maintenance branch.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* fix(storyboards): port governance approval and stale date fixes to 3.1.x

Cherry-picks two patch fixes from main needed for storyboard coverage to
pass on 3.1.x:
- Fix brand-handlers to always return REFERENCE_NOT_FOUND (removing 3.0
  compat path that returned BRAND_NOT_FOUND), fixing brand_baseline failure
- Move stale exclusivity/rights window dates in brand-handlers from
  2026-2027 to 2099 to prevent date-expiry storyboard failures
- Fix governance compliance storyboards for human approval and signal
  activation enforcement

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* fix(signals): port signal governance enforcement fix to 3.1.x

Cherry-picks a335070 from main: signal agents now fail closed on governed
accounts without a valid approval context, and governance compliance checks
no longer require the signals tenant to own sync_plans. Fixes the
activate_signal_denied storyboard floor failure on 3.1.x.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* chore(deps): bump @adcp/sdk to 9.6.2 on 3.1.x

The signal governance enforcement fix cherry-picked in da636b4 was
validated on main under @adcp/sdk 9.6.2 (bumped there in 7a27263 the
day before the fix landed). Under 9.3.0 the storyboard runner skips
sync_accounts as not_applicable when require_operator_auth is true, so
the governance_denied storyboard never registers a governance agent and
activate_signal returns success instead of PERMISSION_DENIED, leaving
the signals 3.0-compat leg at 64 clean vs the 65 floor.

Verified locally: 3.0-compat matrix passes all tenants (signals 65
clean, 108 steps, matching main) and current matrix passes (signals
113 clean, 137 steps).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* fix(deps): regenerate lockfile with npm 10 for CI compatibility

The previous lockfile was regenerated by a locally wrapped npm 11 that
pruned nested proxy-agent@8.0.2 entries, so npm ci on CI (node 22,
npm 10) failed with a lock sync error. Restore the prior lockfile and
apply only the @adcp/sdk 9.6.2 bump via npm 10, matching CI. Verified
with npm@10 ci --dry-run plus a rerun of typecheck and the 3.0-compat
storyboard matrix (all tenants meet floors).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* Version Packages (#5842)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* fix(training-agent): backport publisher_domain filter to 3.1.x (#5868)

* feat(training-agent): add publisher_domain filter to get_products (#5867)

* feat(discovery): add publisher_domain filter to get_products

Adds a publisher_domain filter to product-filters.json so buyers can
discover which products from a seller cover a given publisher domain.
A product matches when at least one publisher_properties entry targets
the specified domain exactly. Implements the training-agent filter
alongside schema and tests.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* feat(training-agent): add publisher_domain filter to get_products

Adds publisher_domain as a filter on get_products so buyers can narrow
results to products whose publisher_properties cover a specific domain.

- Adds publisher_domain to the source schema (static/schemas/source)
  so it survives schema rebuilds
- Handles both publisher_domain (singular) and publisher_domains[]
  (plural array) forms of PublisherPropertySelector, matching the logic
  in adagents-manager.ts
- Canonicalizes the filter value and stored values via
  canonicalizePublisherDomain so BBC.com / bbc.com/ / bbc.com all match
- Adds typeof guard to reject non-string values passed as the filter

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* fix(ci): revert immutable dist artifact edit

The dist/schemas/3.1.0/ artifacts are released and immutable. The
publisher_domain field belongs in the source schema only; the versioned
dist is generated by npm run version when the changeset is processed.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

---------

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>

* chore(changeset): downgrade to patch for 3.1.x backport

---------

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>

* Version Packages (#5869)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* fix(protocol): restore the supported 3.1 contract (#5908)

* Version Packages (#5909)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* fix: prepare 3.1.5 patch release (#6001)

* fix(creative): clarify preflight dry-run validation (#5791)

* Clarify creative preflight semantics

* chore: refresh PR checks

* docs(get_media_buy_delivery): correct misleading "Buyer Reference Query" example (#5807)

Fix a misleading get_media_buy_delivery example that implied buyers can look up delivery by their own reference. media_buy_ids are seller-assigned, so the example now uses seller-assigned mb_... IDs and points buyers to reconcile their own reference through opaque context echoed by create_media_buy / get_media_buys.

* docs(compliance): document branch-set any_of peer cascade exemption (#5783)

Adds `branch_set_cascade_exemption` to `cascade_rules` in
runner-output-contract.yaml (parallel to `sole_stateful_step_exemption`):
a stateful peer's genuine failure or `peer_branch_taken` skip MUST NOT
cascade `prerequisite_failed` onto a sibling phase sharing the same
`branch_set.id` under `any_of` semantics. Branch-set peers are
mutually-exclusive alternatives, not a dependency chain. Scoped to
`any_of`, N-ary-safe, cross-set and within-phase cascade unchanged, and
explicitly `depends_on`-agnostic (fires whether the sibling's dependency
is the implicit default or an explicit depends_on naming the peer).

`default_cascade` gains a pointer to the new exemption; storyboard-
schema.yaml's `depends_on` section gains a cross-reference.

Documents-only: codifies the runner behavior shipped in adcp-client#2306
(closing adcp-client#2305), root-caused in #5337. No schema or wire change.

Co-authored-by: Fernando Granata <fernandogranata@Host-001.homenet.telecomitalia.it>
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>

* compliance(media-buy): available_actions uses a non-guaranteed fixture (runnable by sales-non-guaranteed-only sellers) (#5731)

The available_actions scenario seeded a guaranteed-only product fixture, so its
create_buy_from_product step failed with a terminal DELIVERY_MODE_NOT_SUPPORTED
for sellers declaring only specialisms: ["sales-non-guaranteed"], cascading the
whole available-actions enforcement flow (read_persisted_buy_actions +
enforce_available_actions all prerequisite_failed).

The allowed_actions behavior this scenario grades is delivery-type-agnostic, so
the fixture switches to non_guaranteed (fixed_price → floor_price). Same fix as
the base media_buy_seller flow; the create steps reference the product/pricing by
id, unchanged.

The packaged dist/compliance/ cache is generated from this source.

Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>

* chore(changeset): mark available actions fix as patch (#5906)

* fix(compliance): correct creative storyboard capability assertions (#5847)

- canonical_supported_formats: change hardcoded field_value for
  capability_id ("training_image_generation") to field_present, since
  capability_id is agent-local; remove field_absent on supported_formats[1]
  which incorrectly capped to a single advertised format; rename key: to
  name: in context_outputs per storyboard schema. Bump to 1.0.1.

- evaluator_auth: add requires_capability guards to all six optional
  phases so agents declaring creative.supports_evaluator: false receive
  not_applicable instead of false failures; guards evaluate against the
  raw capabilities response, bypassing a runner-side boolean-false context
  accumulator bug (adcp-client); rename key: to name: in context_outputs.
  Bump to 1.0.1.

Closes #5843. Refs #5844 (runner fix in adcp-client still required;
storyboard fix stops the false failures).


Claude-Session: https://claude.ai/code/session_011iWNWasRVCisU8sMy688Qx

Co-authored-by: Claude <noreply@anthropic.com>

* fix(compliance): correct privacy and inventory guidance (#5904)

* fix(release): preserve schema release status (#5913)

* fix(docs): replace phantom creative and governance error codes with canonical enum members (#5819)

sync_creatives, build_creative, the creative specification, check_governance,
and sync_plans documented 13 errors[].code values that do not exist in
enums/error-code.json. Remap each to the existing code with matching
semantics (UNSUPPORTED_FEATURE, VALIDATION_ERROR, CREATIVE_REJECTED,
INVALID_STATE, INVALID_REQUEST, PERMISSION_DENIED); replace GENERATION_FAILED
with task-failure guidance per the open-vocabulary rule. Also fix the one
live INVALID_FORMAT emission in the training-agent reference implementation.
Same failure mode as #4852 / #5307.

* docs: add creative agent setup verification (#5881)

Co-authored-by: Brian O'Kelley <bokelley@scope3.com>

* docs(media-buy): add Budget & Pacing Controls reference to create_media_buy (#5984)

Enumerates every budget-constraint field (total_budget, package budget,
impressions, pacing, bid_price, flight window) in one place, documents the
three pacing modes, and marks the missing daily-cap field as a known gap
with the pacing-based workaround. Cross-links from update_media_buy.

Closes #4429

* fix(schema): require cancellation_fee rate/amount by fee type (#5987)

cancellation-policy.json documents cancellation_fee.rate as "Required when
type is 'percent_remaining'" and .amount as "Required when type is
'fixed_fee'" — restated in the pricing-models reference — but cancellation_fee
listed only ["type"] in required[]. A validator accepted a percent_remaining
or fixed_fee cancellation term with no fee value, leaving the cancellation
cost undefined for a buyer accepting the product's terms.

Adds if/then conditionals enforcing the documented contract; full_commitment
and none are unaffected. No prose change. Regression coverage added.

Closes #5986

* fix: align retry_after with the canonical error shape (#5954)

* fix(ci): preserve forward-merge branches when opening PRs (#5978)

* docs: expand AgenticAdvertising.org name in backports

---------

Co-authored-by: Steven Liss <stevenliss45@gmail.com>
Co-authored-by: fgranata <220887501+fgranata@users.noreply.github.com>
Co-authored-by: Fernando Granata <fernandogranata@Host-001.homenet.telecomitalia.it>
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Co-authored-by: Aleksander Sekowski <aleksander@uixlimited.com>
Co-authored-by: Bill Jung <56685007+sangilish@users.noreply.github.com>
Co-authored-by: Garvit kaushik <77023388+garvitkaushik-123@users.noreply.github.com>

* Version Packages (#6003)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* fix(schema): backport legacy format mappings to 3.1.x (#6040)

Backport the patch-eligible literal v1 canonical format mappings from #6037 for the 3.1.6 maintenance release.

* fix(release): backport schema discovery status test correction (#6044)

Backport #6043 so the 3.1.6 release audit accepts exact withdrawn artifacts while continuing to reject non-selectable alias targets.

* Version Packages (#6041)

Release adcontextprotocol 3.1.6.

* fix(schema): allow canonical list_creatives identities (#6047) (#6057)

* fix(schema): allow canonical list_creatives identities

* chore(schema): update oneOf discriminator baseline

* Version Packages (#6059)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* fix(schema): correct legacy canonical mappings (#6061) (#6066)

* fix(schema): preserve video aspect ratio mapping

* fix(schema): publish AAO display mappings

* Version Packages (#6067)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

---------

Co-authored-by: Rachit <43431004+rachitm022@users.noreply.github.com>
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Co-authored-by: Nastassia Fulconis <nfulconis@scope3.com>
Co-authored-by: aao-release-bot[bot] <280565558+aao-release-bot[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Nastassia Fulconis <nastassia.fulconis@gmail.com>
Co-authored-by: Steven Liss <stevenliss45@gmail.com>
Co-authored-by: fgranata <220887501+fgranata@users.noreply.github.com>
Co-authored-by: Fernando Granata <fernandogranata@Host-001.homenet.telecomitalia.it>
Co-authored-by: Aleksander Sekowski <aleksander@uixlimited.com>
Co-authored-by: Bill Jung <56685007+sangilish@users.noreply.github.com>
Co-authored-by: Garvit kaushik <77023388+garvitkaushik-123@users.noreply.github.com>
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