Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

Optimistic history oracle retains source rows from an aborted batch

Abierto
#2,063 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
3/5
Tiempo estimado
1-2 días
Aptitud para principiantes
72/100
Tipo de issue
Error
Claridad
Bien especificado
Estado de actividad
Activo
Stack tecnológico
typescript
Área
testing-qa

Línea de trabajo

Start with collection-state-retention-oracle.property.test.ts and trace how the oracle driver handles beginSourceBatch() and aborts for sourceKeys and sourceRows. Run the saved replay using the provided TANSTACK_DB_ORACLE_* values, then add the focused oracle-driver comparison described in the issue. Done means a partial update after abort behaves like one after a committed delete and the replay passes.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

The optimistic history oracle can report a false production failure after an aborted open source batch. Its driver restores sourceKeys on abort, but beginSourceBatch() has also changed sourceRows, and the abort path does not restore that ledger.

A minimal legal history starts with row 2 at c: 0:

  1. Open a source batch that deletes row 2.
  2. Abort that batch.
  3. Apply a partial update for row 2 whose input has c: -1.

After the abort, the source still holds row 2 at c: 0. The partial-update driver should omit c, so the update should preserve c: 0. Instead, its stale sourceRows ledger says row 2 is absent. The driver writes c: -1, and the independent model correctly rejects the resulting publication.

This reproduces on clean origin/main at 9e8ed997885fb46ac98ec85906f4ca4f662e7cce in collection-state-retention-oracle.property.test.ts. The saved replay is TANSTACK_DB_ORACLE_SEED=-1161486883, TANSTACK_DB_ORACLE_PROPERTY=collection-state.optimistic-history-partial, and TANSTACK_DB_ORACLE_PATH=93:3:2:6:8:13:12:14:14:15:10:10:10:10:11:10:10:10:10:10:10:10.

Restore both source ledgers when an open batch aborts. A focused oracle-driver test should then compare a partial update after abort with one after a committed delete.

Lenguaje dominante
TypeScript
Estrellas
3.9k
Forks
272
Merge medio
1 d 45 min
PR fusionados (30 d)
208

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de TanStack/db

Todos los issues de TanStack/db

Issues similares

Más issues de TypeScript

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.