Skip to content

[DIPS] add pending_rca_proposals migration#1173

Closed
MoonBoi9001 wants to merge 3 commits intofeat/dips-supportfrom
feat/pending-rca-migration
Closed

[DIPS] add pending_rca_proposals migration#1173
MoonBoi9001 wants to merge 3 commits intofeat/dips-supportfrom
feat/pending-rca-migration

Conversation

@MoonBoi9001
Copy link
Member

@MoonBoi9001 MoonBoi9001 commented Mar 3, 2026

Motivation

The indexer-rs DIPs flow stores validated RCA proposals in a pending_rca_proposals table for the agent to later pick up and accept on-chain. By convention in this codebase, the indexer-service does not run database migrations -- it defers to the agent to avoid DDL conflicts from two processes sharing a database. Without this migration, indexer-service rejects every valid proposal with relation "pending_rca_proposals" does not exist.

Summary

  • Adds Umzug migration 23-add-pending-rca-proposals.ts that creates the pending_rca_proposals table with the schema defined in indexer-rs/migrations/20260302000000_dips_pending_proposals.up.sql
  • The table is intentionally minimal (6 columns): id, signed_payload, version, status, created_at, updated_at. The signed payload blob is the source of truth -- the agent decodes it when accepting on-chain
  • Does not drop the old indexing_agreements / dips_receipts tables (the existing agent DIPs code still references them; updating that code is a separate piece of work)

Co-Authored-By: Claude Opus 4.6 noreply@anthropic.com

The indexer-rs v2 DIPs flow stores validated RCA proposals in a
pending_rca_proposals table, which the agent will later pick up and
accept on-chain. The indexer-service does not run migrations (by
convention, the agent owns DDL), so this migration creates the table
that indexer-service needs to write to.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@github-project-automation github-project-automation bot moved this to 🗃️ Inbox in Indexer Mar 3, 2026
@MoonBoi9001 MoonBoi9001 changed the base branch from main-dips to feat/dips-support March 3, 2026 01:43
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@MoonBoi9001 MoonBoi9001 changed the title feat: add pending_rca_proposals migration for DIPs v2 [DIPS] add pending_rca_proposals migration Mar 3, 2026
@MoonBoi9001 MoonBoi9001 requested a review from Maikol March 3, 2026 02:15
Copy link
Member

@Maikol Maikol left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have this migration as part of #1174 Don't mind if you want to merge this but we should create the index using sequilize api

Replace raw SQL with queryInterface.addIndex using the fields object
syntax for DESC ordering, per review feedback.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@MoonBoi9001 MoonBoi9001 requested a review from Maikol March 3, 2026 15:58
@MoonBoi9001
Copy link
Member Author

@Maikol going to close this so we can use #1174 instead

@MoonBoi9001 MoonBoi9001 closed this Mar 3, 2026
@github-project-automation github-project-automation bot moved this from 🗃️ Inbox to ❌ Closed in Indexer Mar 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: ❌ Closed

Development

Successfully merging this pull request may close these issues.

2 participants