Repository navigation
fix(backend): make analytics migrations compatible with supported PostgreSQL (#1702) - #1719
Merged
blurbeast merged 2 commits intoOct 22, 2026
Conversation
…tgreSQL (LabsCrypt#1702) - Guard TimescaleDB extension, hypertables, continuous aggregates, and compression policies in 20261001000000_add_timescaledb_analytics with dynamic execution when timescaledb extension is present, safely falling back to live aggregation when absent - Fix foreign key ordering on PostgreSQL in 20260221132622_init by adding inline unique constraints on table creation - Support clean migration replay in 20260729170000_timestamp_bigint with IF NOT EXISTS for endTime column - Drop existing table cascade in 20260926000000_add_indexer_dead_letter_event to resolve collision with duplicate earlier migration - Update CI workflow to use prisma migrate deploy from an empty database instead of prisma db push
2 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #1702
Summary
EXECUTEwithin a conditionalDO $block checkingpg_available_extensions.20260221132622_initfor foreign key ordering.IF NOT EXISTSforendTimecolumn in20260729170000_timestamp_bigint.DROP TABLE IF EXISTS CASCADEin20260926000000_add_indexer_dead_letter_eventto avoid duplicate table collisions..github/workflows/ci.ymlto runprisma migrate deployfrom an empty database.Testing
npx prisma migrate deploycleanly applies all 18 migrations from an empty database.