[Bug]: VersionedDatabaseTaskStore get() and delete() fail with "no such table" when initialize() was not called
Los mantenedores suelen responder en 3 días
Evaluación
Este issue todavía no se ha evaluado.
Descripción
What happened?
VersionedDatabaseTaskStore (src/a2a/server/cluster/database_task_store.py, added in #1281) creates its tables lazily, like DatabaseTaskStore: save() calls self._db._ensure_initialized() and then self._ensure_cluster_tables() before touching the database. get() and delete() only initialize the underlying DatabaseTaskStore, so on that path the task_versions table is never created.
If the store is used without calling initialize() first and the first operation is a get() or a delete(), the query on task_versions fails instead of returning None for a missing task:
store = VersionedDatabaseTaskStore(engine=create_async_engine('sqlite+aiosqlite:///:memory:'))
await store.get('missing', ServerCallContext())
# sqlalchemy.exc.OperationalError: (sqlite3.OperationalError) no such table: task_versions
await store.delete('missing', ServerCallContext())
# sqlalchemy.exc.OperationalError: (sqlite3.OperationalError) no such table: task_versions
The cluster sample and the existing tests call initialize() explicitly, so this only shows up when relying on the lazy initialization that save() and DatabaseTaskStore already provide.
Suggested fix: call self._ensure_cluster_tables() in get() and delete() after initializing the underlying store, as save() does.
I have a fix ready and I'm opening a PR alongside this issue.
Code of Conduct
- I agree to follow this project's Code of Conduct
- Lenguaje dominante
- Python
- Estrellas
- 2.2k
- Forks
- 518
- Merge medio
- 3 d 23 h
- PR fusionados (30 d)
- 41
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 a2aproject/a2a-python
-
[Bug]: `A2A-Version` validation ignores minor versions and the query parameterPosiblemente ocupada @rohityan la tomó hace 56 días. Abiertocomponent: server status:awaiting response
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
a2aproject/a2a-python#1204 · 3 comentarios · 1 asignado ·
Los mantenedores suelen responder en 3 días
-
[Bug]: REST task/request id sanitizationPosiblemente ocupada @Linux2010 la tomó hace 115 días. Abiertomaintainers-only
Dificultad 2/5 1-3 horas Aptitud para principiantes 65/100
a2aproject/a2a-python#805 · 1 comentario ·
Los mantenedores suelen responder en 3 días
-
Legacy handler ignores history_length on message/streamPosiblemente ocupada @rohityan la tomó hoy. Abierto
a2aproject/a2a-python#1363 · 2 asignados ·
Los mantenedores suelen responder en 3 días
-
v0.3 client returns an empty status message and provider when they are unsetPosiblemente ocupada @rohityan la tomó hoy. Abierto
a2aproject/a2a-python#1361 · 2 asignados ·
Los mantenedores suelen responder en 3 días
-
[Bug]: Executor failure right after its Task is enqueued leaves the task SUBMITTED on DatabaseTaskStorePosiblemente ocupada @Iwaniukooo11 la tomó hace 2 días. Abiertocomponent: server
a2aproject/a2a-python#1351 · 2 asignados ·
Los mantenedores suelen responder en 3 días
Todos los issues de a2aproject/a2a-python
Issues similares
-
[Bug] Unit tests reach real Bedrock call paths without patching the modelPosiblemente ocupada @proton0210 la tomó hoy. Abiertobug
Dificultad 2/5 1-3 horas Aptitud para principiantes 67/100
aws-samples/sample-aws-genai-db-modernizer#1318 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
pyarrow-25.0.1-cp310-cp310-manylinux_2_28_x86_64.whl: 1 vulnerabilities (highest severity is: 5.3)AbiertoMend: dependency security vulnerability
Dificultad 2/5 1-3 horas Aptitud para principiantes 62/100
capitalone/locopy#394 ·
-
[Bug] Unhandled ValueError terminates watchdog thread when GISRC value contains multiple colonsAbiertobug
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
Los mantenedores suelen responder en 1 día
-
sdk-typescript: unquoted COPY globs in shell form are silently dropped from the image build contextAbiertobug javascript
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
Los mantenedores suelen responder en 1 día
-
enhancement
Dificultad 2/5 1-3 horas Aptitud para principiantes 65/100
ietf-tools/datatracker#11922 · 1 comentario ·
Los mantenedores suelen responder en 1 día