a2aproject / a2aproject/a2a-python

[Bug]: Wrong error when sending a message for a terminal task

Aperta
#1,205 2 commenti 0 reazioni 1 assegnatario Rivendicata da @lkk7 Vedi su GitHub
component: server status:awaiting response
Lingua principale
Python
Stelle
2.1k
Fork
496
Merge medio
4g 17h
PR unite (30g)
12

Descrizione

### What happened?

What the spec says about the "Send Message" operation errors:
> UnsupportedOperationError: Messages sent to Tasks that are in a terminal state [...]

What the code does (`on_message_send(...)->_setup_message_execution(...)`):
```python
if task.status.state in TERMINAL_TASK_STATES:
raise InvalidParamsError(
message=f'Task {task.id} is in terminal state: {task.status.state}'
)
```

### Relevant log output

```shell

```

### Code of Conduct

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

Guida per i contributori

Apri la guida per i contributori

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.