fix(a2a): advertise streaming on agent_registry agent cards - #6781
Open
lllakshit wants to merge 1 commit into
Open
fix(a2a): advertise streaming on agent_registry agent cards#6781lllakshit wants to merge 1 commit into
lllakshit wants to merge 1 commit into
Conversation
agent_registry called build_agent_card without capabilities or streaming, so constructed cards advertised streaming:false. Pass streaming=True on that convenience path and document that streaming= is ignored when capabilities is provided. Fixes google#6778
|
Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). View this failed invocation of the CLA check for more information. For the most up to date status, view the checks section at the bottom of the pull request. |
Author
|
@googlebot rescan I have already signed the Google Individual CLA (Lakshit Mathur / lllakshit / llakshitmathur239@gmail.com). Please re-check this pull request. |
Author
|
@DeanChensj Could you please review this PR and let me know if any changes are required? I’d appreciate your feedback so I can address any remaining concerns and move it toward merging into main. |
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.
Please ensure you have read the contribution guide before creating a pull request.
Link to Issue or Description of Change
1. Link to an existing issue (if applicable):
Problem:
AgentRegistry.get_remote_a2a_agent()builds a card through_compat.build_agent_card()with neithercapabilitiesnorstreaming. The helper then falls through todefault_capabilitieswherestreamingdefaults toFalse, so registry-constructed cards advertisestreaming: false.The issue also asked which public-API shape to use for the
streaming=parameter. This PR takes the non-breaking option: keepstreaming=as the no-capabilities convenience path only. It does not dropstreaming=(that would remove public surface) and does not composestreaming=onto a passedcapabilitiesobject (that would change the meaning of an existing parameter; current tests already lock in "capabilities wins").AgentCardBuilderstill defaultsAgentCapabilities()withoutstreaming=Trueon GitHubmain(#6673 closed without landing here). That is #6672 and is left out of this PR so this stays one concern.Solution:
Pass
streaming=Trueat theagent_registrycall site, which is the convenience pathbuild_agent_cardalready implements. Document thatstreaming=is ignored whencapabilitiesis provided.Testing Plan
Unit Tests:
Commands:
Summary (Python 3.12.10, a2a-sdk 1.1.2, matching the issue repro):
Skipped tests are the existing 0.3-only
@v03_onlycases; this environment is a2a-sdk 1.x. New coverage that runs on 1.x:capabilitiesstill defaultsstreamingtoFalsestreaming=Trueis honoured whencapabilitiesis omittedcapabilitiesobject still wins (no composition)get_remote_a2a_agent()constructed cards advertisestreaming is TrueManual End-to-End (E2E) Tests:
Reproduced the issue snippet against GitHub
mainvs this branch (a2a-sdk 1.1.2):git show upstream/main:.../agent_registry.pystill has nostreaming=on that call. After this change the same call passesstreaming=True.No
adk webUI change; this is card construction only.Checklist
Additional context
I will complete the Google CLA if it is not already on file.
Assisted by an AI coding tool; I reviewed the diff, ran the tests above, and confirmed the issue still reproduces on
main.