-
Notifications
You must be signed in to change notification settings - Fork 1
feat: integrate AdCP schema improvements (PR #222 + #223) #73
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…, and unified Package Implements changes from upstream AdCP PR #222 and PR #223: **New Types (PR #222)** - AssetContentType: Consolidated enum for asset content types (13 values) - FormatCategory: Semantic enum for format categories (7 values) **Unified Package (PR #223)** - create_media_buy and update_media_buy now return full Package objects - Removed CreatedPackageReference (deprecated) - Better API consistency and developer experience **Breaking Changes** - Removed CreatedPackageReference: use Package directly - Removed AffectedPackage: removed from upstream schemas **Backward Compatibility** - AssetType maintained as deprecated alias to AssetContentType Test results: 283/295 passing (12 failures for removed CreatedPackageReference - expected) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
Removed 5 test functions that tested CreatedPackageReference since this type was removed in AdCP PR #223. The PR unified Package responses so that both create_media_buy and update_media_buy now return full Package objects instead of minimal references. Removed tests: - test_package_type_aliases_imports - test_package_type_aliases_point_to_correct_modules - test_package_type_aliases_have_correct_fields - test_package_type_aliases_in_exports - test_package_aliases_can_instantiate All 290 tests now pass. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
Removed temporary documentation files (SCHEMA_COLLISION_PROPOSAL.md, UPSTREAM_SCHEMA_RECOMMENDATIONS.md) that were used during analysis. Enhanced CHANGELOG_ENTRY.md to include: - Detailed description of upstream schema improvements (PR #222 + #223) - Complete list of new types with all enum values - Expanded migration guide with more examples - Upstream recommendations identified during integration The key findings (orphaned asset-type.json, enum organization suggestions, discriminator standardization opportunities) are now captured in the changelog for future reference. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
Upstream PR #222 removed the orphaned asset-type.json schema file. Our local cache had stale copies that were no longer referenced upstream. Changes: - Removed stale asset-type.json from schemas/cache/1.0.0/ - Removed asset_type.py generated file (no longer has upstream schema) - Removed orphaned type exports: AssetTypeSchema, ContentLength, Dimensions, Duration, FileSize, Quality, Requirements - Added deprecation alias: AssetType = AssetContentType - Synced 6 updated schemas (deployment, destination, activate-signal, get-signals) The sync discovered asset-type.json was 404 upstream - it was removed in PR #222 as part of the enum consolidation work. Tests: 288/290 passing (2 failures in signals tests due to schema API changes from destinations → deployments in upstream) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
….json The orphaned asset-type.json was already removed by the AdCP team in PR #222. Updated changelog to acknowledge this was properly handled upstream. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
Added automatic cleanup of schema files that no longer exist upstream.
This prevents stale cached schemas from causing issues when upstream
removes or renames schema files.
Changes:
- Scan for JSON files in cache that aren't in the upstream schema list
- Remove orphaned files and their empty parent directories
- Report removed count in sync summary
- Updated script documentation to explain new feature
Example output:
Cleaning up orphaned schemas:
✗ asset-type.json (removed - no longer in upstream)
✗ core/asset-type.json (removed - no longer in upstream)
This would have automatically caught the stale asset-type.json files
that were orphaned after PR #222.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
Upstream schema updates changed the signals API from using 'destinations' to 'deployments'. Updated test fixtures to match new API structure. Changes: - GetSignalsRequest.deliver_to.destinations → deployments - ActivateSignalRequest.destinations → deployments Tests now passing: 290/290 (100%) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
Release Please will automatically generate changelog from commits. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
Integrated latest changes from main branch including: - README updates - Client and protocol improvements - CLI enhancements - Test updates All conflicts resolved by regenerating types from latest schemas. All 292 tests passing. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
- Fix import sorting per ruff I001 rules - Fix line length by moving comment above import - Remove orphaned 'Requirements' from __all__ (type was removed with asset-type.json) All linter checks now passing. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Integrates upstream AdCP schema improvements that resolved all type naming collisions, enabling cleaner SDK APIs and better type safety.
Upstream PRs: AdCP #222 (enum consolidation) + #223 (Package unification)
Changes
AssetContentType(13 values) andFormatCategory(7 values) - replacing scattered variantscreate_media_buyandupdate_media_buynow return identical structuresCreatedPackageReference,AffectedPackage, orphanedasset-type.jsonBackward compatible: SDK maintains
AssetTypedeprecation alias through 2.x releases.🤖 Generated with Claude Code