Skip to content

fix: backport Hindsight consolidation race handling - #32

Merged
LeiShi1313 merged 1 commit into
masterfrom
fix/hindsight-observation-history-race
Jul 16, 2026
Merged

fix: backport Hindsight consolidation race handling#32
LeiShi1313 merged 1 commit into
masterfrom
fix/hindsight-observation-history-race

Conversation

@LeiShi1313

Copy link
Copy Markdown
Owner

Summary

  • backport vectorize-io/hindsight PR #2620 to the pinned Hindsight 0.8.4 image
  • skip best-effort observation history writes when parallel consolidation has already removed the source observation
  • publish the patched local image as telefire-hindsight:0.8.4-hardened-r1

Why

The live Telegram command matrix passed, but its revision-heavy memory flow exposed Hindsight's known observation_history_observation_id_fkey consolidation race. A queued consolidation recovered afterward, but the failed background operation made the deployment audit noisy and could delay future consolidation work.

Verification

  • uv run pytest -q (267 passed, 6 skipped)
  • rebuilt telefire-hindsight:0.8.4-hardened-r1
  • exercised _append_observation_history in the built image with a synthetic asyncpg.exceptions.ForeignKeyViolationError
  • confirmed the patched image still omits the package managers removed by the hardened base
  • docker compose ... config --images
  • git diff --cached --check

Upstream: vectorize-io/hindsight#2620

Apply upstream hindsight PR #2620 to the pinned 0.8.4 image so an observation deleted by parallel consolidation does not fail the entire background task. Tag the hardened image revision explicitly for deployment.
@LeiShi1313
LeiShi1313 merged commit 792624f into master Jul 16, 2026
4 checks passed
@LeiShi1313
LeiShi1313 deleted the fix/hindsight-observation-history-race branch July 16, 2026 14:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant