Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
-- AlterTable
ALTER TABLE "Stream" ADD COLUMN "isPaused" BOOLEAN NOT NULL DEFAULT false;
ALTER TABLE "Stream" ADD COLUMN "pausedAt" INTEGER;
ALTER TABLE "Stream" ADD COLUMN "totalPausedDuration" INTEGER NOT NULL DEFAULT 0;
-- The pause-state columns (isPaused, pausedAt, totalPausedDuration) are added by
-- the earlier migration `20260428000000_add_pause_state_fields`, which is the
-- single source of truth for them. This migration only adds the index, so that a
-- fresh `prisma migrate deploy` no longer fails with
-- `column "isPaused" of relation "Stream" already exists`.

-- CreateIndex
CREATE INDEX "Stream_isPaused_idx" ON "Stream"("isPaused");
CREATE INDEX IF NOT EXISTS "Stream_isPaused_idx" ON "Stream"("isPaused");
4 changes: 4 additions & 0 deletions backend/src/__tests__/integration/streams.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ const { mockPrisma, mockSseService } = vi.hoisted(() => ({
},
streamEvent: {
create: vi.fn(),
// `upsert` + `findUnique` back the worker's duplicate-event guard
// (soroban-event-worker.ts handleStreamCreated/handleStreamCancelled,
// ~L360/L558). Don't remove them or the indexer tests fail to load
// with "is not a function" — this regressed Backend CI in #527.
upsert: vi.fn(),
findUnique: vi.fn().mockResolvedValue(null),
findMany: vi.fn().mockResolvedValue([]),
Expand Down
Loading