When PieFed forgets which migration it ran recently

Occasionally, for unknown reasons, the database table that keeps track of recent migrations gets dropped. Somehow. To resolve this, re-create the table:

create table if not exists public.alembic_version
(
    version_num varchar(32) not null
        constraint alembic_version_pkc
            primary key
);

Then you need to figure out what value to put into the ‘version_num’ column.

See how those two bits of gibberish are the same length?

Look in the app/migrations/versions directory, sort files by date. Then find the one before the new migration(s) that appeared when you did your last git pull. Insert the beginning of the file name into the database table.