drizzle-kit generate keeps trying to recreate enum value that already exists

I recently created a migration using drizzle-kit generate after replacing a pg enum value. the generated migration was incorrect as it added the new value but never removed the old one. Hence, I manually edited the migration to look like this: ALTER TYPE job_status RENAME VALUE 'completed' TO 'successful'; however, now whenever I run generate for subsequent migrations, it keeps trying to create the new enum value: ALTER TYPE "job_status" ADD VALUE 'successful';--> statement-breakpoint is there a way to stop it from doing so?
2 Replies
TOSL
TOSL3w ago
So you're doing drizzle-kit generate and then drizzle-kit migrate?
ac222222222222
ac222222222222OP2w ago
yes. actually issue only occurred for the first migration after. I am not seeing this issue anymore 👍

Did you find this page helpful?