Repository navigation
feat(a2a): donkey.serve() wraps the official a2a-sdk - #1212
Merged
Merged
Conversation
donkey.serve(handler) serves a @donkey.agent handler over A2A in one line. The a2a-sdk does the protocol (DefaultRequestHandler, InMemoryTaskStore, TaskUpdater, its routes); DDK adds the agent card generated from the @donkey.agent record donkey scan reads, a 127.0.0.1 default bind, and a handler failure that fails the task with the exception type only. - New top-level donkey_kit.a2a package, an independent sibling of integrations in the layers contract (ADR 0014). A2ATask / A2AResult are exported from donkey_kit; build_app() gives the same server as an ASGI app. - New [a2a] extra (a2a-sdk[http-server]>=1.2.0, uvicorn>=0.30), in [all]. 1.2.0 is the first release with DefaultRequestHandler.aclose(), wired into the app lifespan so shutdown drains in-flight tasks. Floor run with lowest-direct on Python 3.10 (verified-apis §8.3); wrapped names in §8.5. - The PR test matrix installs [a2a]; test locks regenerated. - Docs: a2a.mdx leads with "Why not have users call the a2a-sdk directly?" and the setup it replaces; serve is Offline-verified, expose/dev Roadmap. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
4 tasks
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.
Closes #224
Summary
donkey.serve(handler)serves a@donkey.agenthandler over A2A in one line (BG §2.9.1). The a2a-sdk handles the protocol; DDK adds a card generated from the@donkey.agentrecord, a localhost default bind, and failures that reveal only the exception type.donkey_kit.a2apackage besideintegrations(ADR 0014);A2ATask/A2AResultexported. New[a2a]extra (a2a-sdk[http-server]>=1.2.0,uvicorn>=0.30), in[all]; floor in verified-apis §8.3, wrapped names in §8.5.a2a.mdxleads with "Why not have users call the a2a-sdk directly?" and "The setup it replaces"; serve is Offline-verified, expose/dev stay Roadmap. Governed inbound and typed refusals are a2a: governance-aware inbound — correlation, tags, spans and typed refusals on served tasks #225.Test plan
tests/unit/test_a2a_serve.py: raw JSON-RPC round trips (str, A2AResult, sync handler, failures), card from marker, localhost default, missing-extra error,import donkey_kitdoes not load a2a.Post-deploy steps
[a2a], a serve test against the installed package,coverage.tomlwording.🤖 Generated with Claude Code