feat: upgrade to a2a-sdk v1.0.0-alpha.0 with v0.3 compat layer#12
Merged
feat: upgrade to a2a-sdk v1.0.0-alpha.0 with v0.3 compat layer#12
Conversation
Upgrades the SDK dependency from a2a-sdk==0.3.20 to a2a-sdk[telemetry,sqlite]==1.0.0-alpha.0, and restructures the package to support both protocol versions simultaneously. Key changes: - Add slima2a/compat/v3_0/ with SRPCCompatHandler and SRPCCompatTransport for backward-compatible v0.3 wire support - Add slima2a/types/v0/ (moved from slima2a/types/) and slima2a/types/v1/ with separate SlimRPC bindings per protocol version - Rewrite slima2a/client_transport.py and slima2a/handler.py for the v1.0 proto types (no Pydantic conversion needed) - Split buf.gen.yaml into buf.gen.v0.yaml and buf.gen.v1.yaml - Update examples to use v1.0 proto types and add --a2a-version flag (v0/v1/both) to echo_agent server; fix sys.path so scripts can be run directly with `uv run examples/...` without conflicting with the slim-bindings examples package Signed-off-by: Sam Betts <1769706+Tehsmash@users.noreply.github.com>
Pass the shared secret explicitly in all four example scripts to match the value used in slim-a2a-go echo_agent examples, enabling cross-language testing out of the box. Signed-off-by: Sam Betts <1769706+Tehsmash@users.noreply.github.com>
- list(response.parts): RepeatedCompositeFieldContainer is not list[Part] - fetch_agent_card return type: object -> AgentCard; add AgentCard import - TaskState.completed -> TaskState.TASK_STATE_COMPLETED (proto enum name) Signed-off-by: Sam Betts <1769706+Tehsmash@users.noreply.github.com>
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
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
a2a-sdkfrom0.3.20to1.0.0-alpha.0(proto-based types, new service namelf.a2a.v1.A2AService)slima2a/compat/v3_0/withSRPCCompatHandlerandSRPCCompatTransportso servers/clients can continue speaking the v0.3 wire protocol (a2a.v1.A2AService) via a bridge to the v1.0RequestHandlerinterfaceslima2a/types/v0/(v0.3) andslima2a/types/v1/(v1.0); both service names can coexist on the same SLIM serverslima2a/client_transport.pyandslima2a/handler.pyfor v1.0 proto types directly (no Pydantic conversion)buf.gen.yamlintobuf.gen.v0.yamlandbuf.gen.v1.yaml--a2a-version v0|v1|bothflag toecho_agentserver and--a2a-version v0|v1to clientssys.pathin example scripts souv run examples/...works without colliding with theexamplespackage installed byslim-bindingssqliteextra toa2a-sdkdependency to satisfy SQLAlchemy requirement froma2a.compat.v0_3BEGIN_COMMIT_OVERRIDE
feat!: upgrade to a2a-sdk v1.0.0-alpha.0 with v0.3 compat layer
END_COMMIT_OVERRIDE