a2aproject / a2aproject/a2a-tck
TCK mandatory tests: 12 ListTasks tests fail because ListTasksResponse requires pagination fields missing from v1.0 SDK
- 主要言語
- Python
- スター
- 50
- フォーク
- 40
- 平均マージ
- 7日 1時間
- マージ済み PR(30日)
- 1
説明
## Problem
All 12 TCK mandatory ListTasks tests fail against the v1.0 Python SDK because `ListTasksResponse` is missing required pagination fields.
The tests in `tests/mandatory/protocol/test_tasks_list_method.py` assert:
```python
assert 'totalSize' in result
assert 'pageSize' in result
assert 'nextPageToken' in result
```
But the v1.0 Python SDK (`InMemoryTaskStore`) returns only:
```json
{"result": {"tasks": [...]}}
```
## Spec Reference
A2A v1.0 `ListTasksResponse` message (a2a.proto):
```proto
message ListTasksResponse {
repeated Task tasks = 1 [(google.api.field_behavior) = REQUIRED];
string next_page_token = 2 [(google.api.field_behavior) = REQUIRED];
int32 page_size = 3 [(google.api.field_behavior) = REQUIRED];
int32 total_size = 4 [(google.api.field_behavior) = REQUIRED];
}
```
All four fields are REQUIRED.
## Reproduction
```bash
# Start any v1.0 SDK agent
curl -X POST http://localhost:9998 -H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"ListTasks","params":{},"id":"1"}'
# Returns:
# {"result": {"tasks": []}}
# Expected per spec:
# {"result": {"tasks": [], "totalSize": 0, "pageSize": 50, "nextPageToken": ""}}
```
## Affected Tests (12)
- TestBasicListing: test_list_all_tasks, test_list_tasks_empty_when_none_exist, test_list_tasks_validates_required_fields, test_list_tasks_sorted_by_timestamp_descending
- TestFiltering: test_filter_by_context_id, test_filter_by_status, test_filter_by_last_updated_after, test_combined_filters
- TestPagination: test_default_page_size, test_custom_page_size, test_page_token_navigation, test_last_page_detection, test_total_size_accuracy
- TestHistoryLimiting: test_history_length_zero, test_history_length_custom, test_history_length_exceeds_actual
- TestArtifactInclusion: test_artifacts_excluded_by_default, test_artifacts_included_when_requested
- TestEdgeCasesAndErrors: test_default_page_size_is_50, etc.
## Impact
Since these are marked MANDATORY, every v1.0 Python SDK implementation will appear non-compliant. This affects:
- The built-in `python-sut/tck_core_agent`
- Any agent using `InMemoryTaskStore`
- The TCK itself if run against its own reference SUT
## Options
1. Fix `InMemoryTaskStore.list_tasks()` in a2aproject/a2a-python to return pagination fields (preferred)
2. Add a note to TCK that `ListTasks` pagination requires a custom TaskStore implementation
3. Downgrade from MANDATORY to RECOMMENDED until the SDK supports it
コントリビューションガイド
調査の方向性
この issue は a2a-python SDK の InMemoryTaskStore.list_tasks() メソッドにあります。まず、ListTasksResponse の a2a.proto 仕様を確認してください。a2a-python リポジトリ内の InMemoryTaskStore 実装を特定してください。修正では、このメソッドを更新して必要な pagination フィールド (totalSize, pageSize, nextPageToken) を返すようにします。修正を検証するために、tests/mandatory/protocol/test_tasks_list_method.py の失敗している TCK tests を実行してください。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- python
- 領域
- backend-api-design, testing-qa
- issue の種類
- バグ
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 活発さ
- 停滞
- 明瞭さ
- 明確に書かれている
- 初心者へのやさしさ
- 40/100