Skip to content

[Bug]: A2A-Version validation ignores minor versions and the query parameter #1204

Description

@lkk7

What happened?

The specification says:

“Agents MUST process requests using the semantics of the requested A2A-Version (matching Major.Minor).”

and

“Clients MAY provide the A2A-Version as a request parameter instead of a header.”

The implementation seems to miss both points.

  1. The code compares only major:
return actual_v.major == expected_v.major
  1. The query parameter is ignored.
            actual_version = headers.get(
                constants.VERSION_HEADER
            ) or headers.get(constants.VERSION_HEADER.lower())

            if not actual_version:
                return constants.PROTOCOL_VERSION_0_3

            return str(actual_version)

A similar issue existed: #856 but it was not fully fixed.

Code of Conduct

  • I agree to follow this project's Code of Conduct

Activity

  1. added theissue type on Aug 25, 2026
  2. self-assigned this
    on Aug 25, 2026
  3. added
    component: serverIssues related to frameworks for agent execution, HTTP/event handling, database persistence logic.
    on Aug 28, 2026
  4. rohityan commented on Aug 28, 2026

    @rohityan

    Hi @lkk7 , Thank you for reporting this. This is a bug and diverges from the formal A2A protocol specification.
    The spec requires agents to match on both Major and Minor versions. The current check in a2a.utils.version_validator.validate_version only evaluates actual_v.major == expected_v.major, which incorrectly permits minor version mismatches .
    Query Parameter Fallback : The spec allows A2A-Version to be passed as a request query parameter. Currently, _get_actual_version only inspects HTTP request headers before falling back to DEFAULT_A2A_VERSION, ignoring URL query parameters.
    If you would like to contribute open a PR with the fix and test coverage for both cases, we would gladly review it. The fix should update validate_version to enforce (actual_v.major == expected_v.major and actual_v.minor == expected_v.minor).
    Update request extraction middleware to check headers first, then URL query parameters, before applying the fallback default.

  5. github-actions commented on Sep 11, 2026

    @github-actions

    Marking this issue as stale since it has been open for 14 days with no activity. This issue will be closed if no further activity occurs.

  6. github-actions commented on Sep 24, 2026

    @github-actions

    This issue was closed because it has been inactive for 27 days. Please post a new issue if you need further assistance. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

component: serverIssues related to frameworks for agent execution, HTTP/event handling, database persistence logic.status:awaiting response

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions