Skip to content

fix: accept beta-patch wire aliases (e.g. 3.1-beta.5) in detect_wire_version (closes #883)#894

Open
botbikamordehai2-sketch wants to merge 1 commit into
adcontextprotocol:mainfrom
botbikamordehai2-sketch:fix/issue-883-1779958329
Open

fix: accept beta-patch wire aliases (e.g. 3.1-beta.5) in detect_wire_version (closes #883)#894
botbikamordehai2-sketch wants to merge 1 commit into
adcontextprotocol:mainfrom
botbikamordehai2-sketch:fix/issue-883-1779958329

Conversation

@botbikamordehai2-sketch
Copy link
Copy Markdown

What

detect_wire_version({"adcp_version": "3.1-beta.5"}) raises UnsupportedVersionError because normalize_to_release_precision preserves the prerelease patch label and SUPPORTED_WIRE_VERSIONS only contains '3.1-beta.4'. Buyers emitting 3.1-beta.5 (e.g. the current JS SDK) are rejected, forcing downstream adopters (e.g. Prebid Sales Agent #632) to monkey-patch the SDK.

Fix

After the strict membership check fails, apply a beta-patch alias tolerance rule: if the normalized incoming version matches MAJOR.MINOR-PRERELEASE.N and at least one entry in supported shares the same MAJOR.MINOR-PRERELEASE base (differing only by the trailing patch counter), treat the version as wire-compatible and return the normalized value. This is safe because the AdCP 3.1 envelope shape has not changed between beta.4 and beta.5.

Acceptance criteria

  • detect_wire_version({"adcp_version": "3.1-beta.5"}) returns "3.1-beta.5" instead of raising.
  • Genuinely incompatible versions (different major/minor or different prerelease family) still raise UnsupportedVersionError.
  • No monkey-patching required in downstream projects.

Closes #883

@aao-ipr-bot
Copy link
Copy Markdown
Contributor

aao-ipr-bot Bot commented May 28, 2026

⚠️ Argus review could not complete

The automated review encountered an issue (possibly reached max turns, timed out, or failed to post the final gh pr review). A human reviewer should take this PR.

View workflow run

This is an automated message from the Argus AI review workflow.

@github-actions
Copy link
Copy Markdown
Contributor

IPR Policy Agreement Required

@botbikamordehai2-sketch — thanks for the contribution. Before this PR can be merged, the AgenticAdvertising.Org IPR Policy requires your agreement.

To agree, post a new comment on this PR with the exact phrase:

I have read the IPR Policy

Your signature is recorded once and covers all contributions to AAO repositories. See signatures/README.md for what gets recorded and why.

@botbikamordehai2-sketch
Copy link
Copy Markdown
Author

I have read the IPR Policy

@github-actions
Copy link
Copy Markdown
Contributor

IPR Policy — signed

Thanks, @botbikamordehai2-sketch. Your agreement to the IPR Policy is recorded at signatures/ipr-signatures.json and applies to all AAO repositories.

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.

Accept or publish AdCP 3.1-beta.5 wire version

1 participant