WilsonSquared
WilsonSquared
Explore posts from servers
DTDrizzle Team
Created by WilsonSquared on 9/14/2024 in #help
Introspection fails sonb_build_array(" is not valid JSON
I'm trying to switch from prisma to drizzle. To begin, I've tried introspecting my database, but it fails with an error sonb_build_array(" is not valid JSON. No logs either. Any idea what could be causing this
npx drizzle-kit introspect

No config path provided, using default 'drizzle.config.ts'
Reading config file '/Users/wilson/Developer/Projects/senja/apps/api/drizzle.config.ts'
Pulling from ['public'] list of schemas

Using 'postgres' driver for database querying
[✓] 49 tables fetched
[⣟] 471 columns fetching
[✓] 0 enums fetched
[⣟] 0 indexes fetching
[⣟] 9 foreign keys fetching
undefined:1
sonb_build_array(
^

SyntaxError: Unexpected token 's', "sonb_build_array(" is not valid JSON
at JSON.parse (<anonymous>)
at defaultForColumn (/Users/wilson/Developer/Projects/senja/node_modules/.pnpm/[email protected]/node_modules/drizzle-kit/bin.cjs:19380:55)
npx drizzle-kit introspect

No config path provided, using default 'drizzle.config.ts'
Reading config file '/Users/wilson/Developer/Projects/senja/apps/api/drizzle.config.ts'
Pulling from ['public'] list of schemas

Using 'postgres' driver for database querying
[✓] 49 tables fetched
[⣟] 471 columns fetching
[✓] 0 enums fetched
[⣟] 0 indexes fetching
[⣟] 9 foreign keys fetching
undefined:1
sonb_build_array(
^

SyntaxError: Unexpected token 's', "sonb_build_array(" is not valid JSON
at JSON.parse (<anonymous>)
at defaultForColumn (/Users/wilson/Developer/Projects/senja/node_modules/.pnpm/[email protected]/node_modules/drizzle-kit/bin.cjs:19380:55)
4 replies
DTDrizzle Team
Created by WilsonSquared on 5/25/2024 in #help
Drizzlekit push fails with "database...TypeError: Cannot use 'in' operator to search for 'default'"
I'm trying to run a migration on my Neon postgres instance, but I keep getting this error: Any ideas on how to solve/workaround this error?
Reading config file '/Users/wilson/Developer/Projects/rewardmojo/pkgs/db/drizzle.config.ts'
Using 'postgres' driver for database querying
[✓] Pulling schema from database...TypeError: Cannot use 'in' operator to search for 'default' in undefined
at /Users/wilson/Developer/Projects/rewardmojo/node_modules/drizzle-kit/bin.cjs:18362:23
at Array.map (<anonymous>)
at alternationsInColumn (/Users/wilson/Developer/Projects/rewardmojo/node_modules/drizzle-kit/bin.cjs:18361:10)
at /Users/wilson/Developer/Projects/rewardmojo/node_modules/drizzle-kit/bin.cjs:18321:49
at Array.map (<anonymous>)
at findAlternationsInTable (/Users/wilson/Developer/Projects/rewardmojo/node_modules/drizzle-kit/bin.cjs:18321:37)
at /Users/wilson/Developer/Projects/rewardmojo/node_modules/drizzle-kit/bin.cjs:18203:14
at Array.map (<anonymous>)
at applyJsonDiff (/Users/wilson/Developer/Projects/rewardmojo/node_modules/drizzle-kit/bin.cjs:18201:69)
at applyPgSnapshotsDiff (/Users/wilson/Developer/Projects/rewardmojo/node_modules/drizzle-kit/bin.cjs:19822:26)
Reading config file '/Users/wilson/Developer/Projects/rewardmojo/pkgs/db/drizzle.config.ts'
Using 'postgres' driver for database querying
[✓] Pulling schema from database...TypeError: Cannot use 'in' operator to search for 'default' in undefined
at /Users/wilson/Developer/Projects/rewardmojo/node_modules/drizzle-kit/bin.cjs:18362:23
at Array.map (<anonymous>)
at alternationsInColumn (/Users/wilson/Developer/Projects/rewardmojo/node_modules/drizzle-kit/bin.cjs:18361:10)
at /Users/wilson/Developer/Projects/rewardmojo/node_modules/drizzle-kit/bin.cjs:18321:49
at Array.map (<anonymous>)
at findAlternationsInTable (/Users/wilson/Developer/Projects/rewardmojo/node_modules/drizzle-kit/bin.cjs:18321:37)
at /Users/wilson/Developer/Projects/rewardmojo/node_modules/drizzle-kit/bin.cjs:18203:14
at Array.map (<anonymous>)
at applyJsonDiff (/Users/wilson/Developer/Projects/rewardmojo/node_modules/drizzle-kit/bin.cjs:18201:69)
at applyPgSnapshotsDiff (/Users/wilson/Developer/Projects/rewardmojo/node_modules/drizzle-kit/bin.cjs:19822:26)
10 replies