Skip to content

fix(ci): restore green main (prettier, cargo fmt, loan_events view migration) - #1583

Merged
ogazboiz merged 3 commits into
mainfrom
fix/ci-main-red-fmt-lint-migration
Aug 3, 2026
Merged

fix(ci): restore green main (prettier, cargo fmt, loan_events view migration)#1583
ogazboiz merged 3 commits into
mainfrom
fix/ci-main-red-fmt-lint-migration

Conversation

@ogazboiz

@ogazboiz ogazboiz commented Aug 3, 2026

Copy link
Copy Markdown
Contributor

Join us on Telegram: https://t.me/+DOylgFv1jyJlNzM0

Main CI has been red since ~July 30, which makes every contributor PR fail the backend, contracts and migration-check jobs through no fault of their own. This fixes the three causes:

  1. backend eslint: prettier formatting errors in src/services/crossContractReconciler.ts and its test.
  2. contracts: cargo fmt diff in lending_pool/src/lib.rs.
  3. migration-check: 1802000000000_money_stroops_integer retypes contract_events.amount, but the backward-compat loan_events view depends on that column, so postgres aborts with "cannot alter type of a column used by a view or rule" on a fresh schema. The migration now drops the view before the ALTER and recreates it verbatim afterwards (up and down).

Note: we also have two migrations sharing the number 1802000000000 (create-ledger-checkpoints and money_stroops_integer). They run in a deterministic alphabetical order so nothing breaks today, but new migrations should start at 1803000000000 or higher.

- backend: run prettier on crossContractReconciler.ts and its test (6 eslint errors)
- contracts: cargo fmt on lending_pool/src/lib.rs
- migrations: 1802000000000_money_stroops_integer failed on a fresh schema because
  the loan_events view depends on contract_events.amount and postgres refuses to
  retype a column a view uses. Drop the view before the ALTER and recreate it
  verbatim afterwards, in both up and down.
pgm.dropIndex(table, 'idx_...') treats the string as a column list and
generates the wrong index name (contract_events_idx_contract_events_seek_index),
so the rollback path failed once up() could complete. Pass the explicit
{ name } option instead.
deposit gained a min-shares arg, remittance_nft mint/update_score and
metadata types changed shape. The fuzz crate is checked by CI but had
drifted since these API changes landed.
@ogazboiz
ogazboiz merged commit cf1aca6 into main Aug 3, 2026
14 checks passed
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