A2aAgentExecutor has no native way to emit TaskState.rejected on the server side
Los mantenedores suelen responder en 3 días
@sanketpatil06 ya está trabajando en esto.
Desde el 23/11/2026.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 25/100
Línea de trabajo
Start in google/adk/a2a/executor/a2a_agent_executor_impl.py around _handle_request and in google/adk/a2a/executor/task_result_aggregator.py where terminal states are tracked, then check google/adk/a2a/converters/to_adk_event.py to see how TS_REJECTED is already read on the client side. Settle on a server-side signal (exception type or event action flag) with the maintainers before coding. Done means a rejection maps to TS_REJECTED with priority above completed and distinct from failed, with tests covering both paths.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Environment
google-adk==2.15.0a2a-sdk==0.3.26- Python
3.12
Problem
In the A2A specification, TaskState.rejected (TASK_STATE_REJECTED in v1.0) represents a policy/business refusal distinct from a technical execution failure (failed).
In google-adk==2.15.0:
- The client converter (
google/adk/a2a/converters/to_adk_event.py:70) recognizes_compat.TS_REJECTEDin_TASK_RESPONSE_BOUNDARY_STATES. - On the server side,
A2aAgentExecutor(google/adk/a2a/executor/a2a_agent_executor_impl.py:266-297) andTaskResultAggregator(google/adk/a2a/executor/task_result_aggregator.py:55-60) only trackcanceled,failed,auth_required,input_required,working, andcompleted. There is no ADK primitive (tool return contract,EventActionsfield, or mapped exception) for an agent or tool exposed viato_a2a()to emitTaskState.rejected.
Without a workaround, policy refusals end up either as completed (if the tool returns a refusal dict and the LLM explains it in text) or as failed (if an uncaught exception is raised, which clients interpret as a transient error rather than a semantic rejection).
Workaround
- Record a rejection reason from the remote tool / callback (e.g. in session-scoped store or state).
- In an
ExecuteInterceptor.after_agentpassed toA2aAgentExecutorConfig, replace the terminalTS_COMPLETEDTaskStatusUpdateEventwith a newTaskStatusUpdateEventcarrying_compat.TS_REJECTED(final=True) and the refusal message.
Suggested Fix in ADK
Provide a native server-side signal in ADK mapped by TaskResultAggregator / A2aAgentExecutor to _compat.TS_REJECTED — for example:
- a dedicated exception type (e.g.
A2aTaskRejectedErroror policy rejection error) or anEventActions/ToolContextaction flag honored byTaskResultAggregatorandA2aAgentExecutor._handle_request(with priority abovecompletedand distinct fromfailed).
- Lenguaje dominante
- Python
- Estrellas
- 22.3k
- Forks
- 4.4k
- Merge medio
- 1 d 2 h
- PR fusionados (30 d)
- 6
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de google/adk-python
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
google/adk-python#8360 ·
Los mantenedores suelen responder en 3 días
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
google/adk-python#8359 ·
Los mantenedores suelen responder en 3 días
-
Can pin to litellm version be changed?Posiblemente ocupada @llalitkumarrr la tomó hace 10 días. Abiertomodels
Dificultad 1/5 Menos de una hora Aptitud para principiantes 65/100
google/adk-python#8129 · 2 comentarios · 1 asignado ·
Los mantenedores suelen responder en 3 días
-
OpenAPI tools ignore operation- and path-level server overridesPosiblemente ocupada @sanketpatil06 la tomó hace 14 días. Abiertotools
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
google/adk-python#8064 · 4 comentarios · 1 asignado ·
Los mantenedores suelen responder en 3 días
-
Two docstrings in openapi_tool document parameters the signatures do not acceptPosiblemente ocupada @surajksharma07 la tomó hace 17 días. Abierto
Dificultad 1/5 Menos de una hora Aptitud para principiantes 88/100
google/adk-python#8024 · 1 comentario · 1 asignado ·
Los mantenedores suelen responder en 3 días
Todos los issues de google/adk-python
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
vllm-project/vllm#70030 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
TigreGotico/tugaphone#408 ·
Los mantenedores suelen responder en 1 día
-
t: bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
Los mantenedores suelen responder en 3 días
-
needs-triage
Dificultad 1/5 Menos de una hora Aptitud para principiantes 85/100
Azure/azure-sdk-for-python#50155 · 1 reacción ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 66/100
Los mantenedores suelen responder en 1 día