Skip to content

Commit a117cf0

Browse files
google-genai-botcopybara-github
authored andcommitted
fix: Fix the path for agent card in A2A demo
`AGENT_CARD_WELL_KNOWN_PATH` already contains a leading slash so is not needed in the `agent_card` URL. PiperOrigin-RevId: 796537920
1 parent 1fd58cb commit a117cf0

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

contributing/samples/a2a_basic/agent.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ def roll_die(sides: int) -> int:
8888
name="prime_agent",
8989
description="Agent that handles checking if numbers are prime.",
9090
agent_card=(
91-
f"http://localhost:8001/a2a/check_prime_agent{AGENT_CARD_WELL_KNOWN_PATH}"
91+
f"http://localhost:8001/a2a/check_prime_agent/.well-known/agent-card.json"
9292
),
9393
)
9494

contributing/samples/a2a_root/agent.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,5 +20,5 @@
2020
description=(
2121
"Helpful assistant that can roll dice and check if numbers are prime."
2222
),
23-
agent_card=f"http://localhost:8001/{AGENT_CARD_WELL_KNOWN_PATH}",
23+
agent_card=f"http://localhost:8001{AGENT_CARD_WELL_KNOWN_PATH}",
2424
)

0 commit comments

Comments
 (0)