aws / aws/bedrock-agentcore-sdk-python

AgentCore Runtime - get_async_task_info - did not return metadata

オープン
#258 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る
主要言語
Python
スター
761
フォーク
147
平均マージ
1日 23時間
マージ済み PR(30日)
7

説明

**Describe the bug**
Method `get_async_task_info` currently did not return metadata as shown here: https://github.com/aws/bedrock-agentcore-sdk-python/blob/9bd262397c3f3e662b2b178e397568ce184c7888/src/bedrock_agentcore/runtime/app.py#L223-L235

The metadata itself can be injected using method `add_async_task` as shown here: https://github.com/aws/bedrock-agentcore-sdk-python/blob/9bd262397c3f3e662b2b178e397568ce184c7888/src/bedrock_agentcore/runtime/app.py#L259-L264

**To Reproduce**
Create new task with metadata
```
task_id = app.add_async_task("file_processing", {"file": "data.csv"})
# ... do background work ...
app.complete_async_task(task_id)
```

Try to fetch metadata:
```
# Get info about running async tasks
task_info = app.get_async_task_info()
for task in task_info.get('running_jobs', []):
metadata = task.get('metadata', {})
print(metadata)
```

**Expected behavior**
`get_async_task_info` should return the metadata

**Screenshots**
n/a

**Additional context**
AgentCore SDK v1.2.1

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

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

調査の方向性

Start in src/bedrock_agentcore/runtime/app.py at get_async_task_info and compare it with add_async_task, using the linked line ranges. Reproduce the flow with metadata such as {"file": "data.csv"}, then check the returned running_jobs entries. Done means get_async_task_info exposes the metadata added by add_async_task.

索引モデルが issue の本文から書いたものです。

評価

技術スタック
python
領域
backend
issue の種類
バグ
難易度
2/5
見積もり時間
1〜3時間
活発さ
停滞
明瞭さ
明確に書かれている
初心者へのやさしさ
52/100

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

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