Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

[Bug]: AgentCard REQUIRED fields are never validated

Open
#1,267 0 comments 0 reactions 1 assignee View on GitHub

Maintainers usually reply within 2 days

Nobody has claimed this yet.

Assessment

This issue has not been assessed yet.

Description

maintainers-only
What happened?

AgentCard marks 8 fields field_behavior = REQUIRED (https://github.com/a2aproject/A2A/blob/main/specification/a2a.proto#L362-L399): name, description, supported_interfaces, version, capabilities, default_input_modes, default_output_modes, skills.

Nothing in the SDK checks them. proto3 has no required keyword and the annotation is inert metadata, so an empty card is constructible and travels the whole pipeline unchallenged:

AgentCard()   # -> served as HTTP 200 with body {}

None of the methods that accept a card validate it:

  • create_agent_card_routes(agent_card=...)
  • DefaultRequestHandler(agent_card=..., extended_agent_card=...) and on_get_extended_agent_card — validates the request, never the returned card
  • agent_card_to_dict(card)

Correct fix: call the existing validate_proto_required_fields where the card is passed. This would introduce breaking changes for clients that rely on non-spec compliant agent card.

Suggested first step: log a warning when validation fails rather than raising, which is non-breaking and surfaces the problem to the user, with enforcement by default deferred to a major version.

Relevant log output

Code of Conduct
  • I agree to follow this project's Code of Conduct
Dominant language
Python
Stars
2.2k
Forks
499
Avg merge
3d 15h
Merged PRs (30d)
28

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from a2aproject/a2a-python

All issues in a2aproject/a2a-python

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.