Jadpo is experimental and not ready for production. These docs follow the compiler's main branch as of 5 Nov 2026. What's built · Install 0.3.0
jadpo
ReferenceErrors

ErrorsEntities, stores and migrations · rule

migration.record_invalid

On this page

A file in a migration's folder is missing, can't be read, or was changed by hand, so Jadpo can't use the migration.

Area 5, Entities, stores and migrations; not declinable; the next step is usually the human's.

Why Jadpo refuses it

jadpo migrate new writes each migration's folder: snapshot.json, the whole schema at that point, and postgres.sql, the SQL that gets there. jadpo check compares the entities with the latest snapshot, and the next migration is worked out from it. A record that can't be read breaks both, and a guess at what it held could change a real database in a way nobody wrote.

Jadpo won't rebuild the file for you. The right content is the one that was committed, and that may already have been applied to a database.

What it looks like

A project whose first migration's snapshot was edited by hand:

database/migrations/20261020T1400_initial/snapshot.json:

example
{"format": 1}
jadpo checkcheck failed: 1 error, 2 files

error database/migrations/20261020T1400_initial/snapshot.json can't be read

--> database/migrations/20261020T1400_initial/snapshot.json

reason
A migration's records are written by jadpo migrate new and never edited by hand; this one can't be used: it has no stores object.
next
Restore it from version control (human)
rule
migration.record_invalid
help
https://jadpo.dev/docs/errors/migration.record_invalid

(human) at the end of the next: line tells your coding agent to stop and ask you which fix you want, because the choice is yours to make: it decides which committed version of the migration your databases are compared with.

How to fix it

If the file was committed, bring back the committed version:

shell
git restore database/migrations/20261020T1400_initial/snapshot.json

The snapshot again matches what jadpo migrate new wrote, so jadpo check can compare the entities with it, and the next migration starts from it.

A migration's files are never fixed by hand, since jadpo migrate new is the only thing that writes them.

Markdown for agents: /docs/errors/migration.record_invalid.md.Built from Jadpo main at aee2e8f.