drizzle-kit generate not working with unhelpful error message
Ian into an issue with generate yesterday and can't really make sense of the error...
Downgrading drizzle-orm or drizzle-kit version does not change anything (min version tried: orm: 32.0 and kit:22.0 -> (did not go lower because since v32 the new drizzle kit version was required and a drizzle-kit up was done and the config changes were applied, etc...))
I dont know if any change in my schemas causes this issue but the schemas seem correct to me... Because i don't know what causes this looking at the error message i have a hard time debugging this...
Did you run into the same issue or was yours of different nature?
1 Reply
Update: after trying for way too long i found the issue... Having files in the schema folder that are not relevant to db tables (and therefore not exported in the schemas/index.ts file) caused this issue... In my case it was a utils file and ta types file inside the schema folder... After moving them outside of the schema folder, the issue did not occur again...
I hope this helps if anyone else runs into this issue...
It would be nice if the error message for this could be a bit more indicative to the issue causing it...