a2aproject / a2aproject/a2a-python

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

オープン
#1,204 コメント 2 件 リアクション 0 件 担当者 1 名 @rohityan が担当を希望しています GitHub で見る
component: server status:awaiting response status:stale
主要言語
Python
スター
2.1k
フォーク
496
平均マージ
4日 17時間
マージ済み PR(30日)
12

説明

### 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`:

```python
return actual_v.major == expected_v.major
```

2. The query parameter is ignored.

```python
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: https://github.com/a2aproject/a2a-python/issues/856 but it was not *fully* fixed.

### Code of Conduct

- [x] I agree to follow this project's Code of Conduct

コントリビューションガイド

コントリビューションガイドを開く

評価

この issue はまだ評価されていません。

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。