introspect failing with pscale db

Getting a strange error when running the introspect command. I'm using a connectionString from pscale. drizzle.config:
schema: "./schema.ts",
out: "./drizzle",
driver: "mysql2",
dbCredentials: {
connectionString: ...
}
schema: "./schema.ts",
out: "./drizzle",
driver: "mysql2",
dbCredentials: {
connectionString: ...
}
- I've included ?ssl={"rejectUnauthorized":true} script: "introspect": "drizzle-kit introspect:mysql", Error:
Error: rpc error: code = Unknown desc = uncaught panic: interface conversion: interface is nil, not sqlparser.Expr, vtgate:
at PromiseConnection.execute (/Users/robmartin/Projects/americana-neue/node_modules/.pnpm/[email protected]/node_modules/drizzle-kit/index.cjs:35440:26)
at fromDatabase (/Users/robmartin/Projects/americana-neue/node_modules/.pnpm/[email protected]/node_modules/drizzle-kit/index.cjs:11845:33)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5) {
code: 'ER_UNKNOWN_ERROR',
errno: 1105,
sql: 'SELECT table_name, column_name\n' +
' FROM information_schema.table_constraints t\n' +
' LEFT JOIN information_schema.key_column_usage k\n' +
' USING(constraint_name,table_schema,table_name)\n' +
" WHERE t.constraint_type='PRIMARY KEY'\n" +
" and table_name != '__drizzle_migrations'\n" +
' AND t.table_schema = ?',
sqlState: 'HY000',
sqlMessage: 'rpc error: code = Unknown desc = uncaught panic: interface conversion: interface is nil, not sqlparser.Expr, vtgate:
Error: rpc error: code = Unknown desc = uncaught panic: interface conversion: interface is nil, not sqlparser.Expr, vtgate:
at PromiseConnection.execute (/Users/robmartin/Projects/americana-neue/node_modules/.pnpm/[email protected]/node_modules/drizzle-kit/index.cjs:35440:26)
at fromDatabase (/Users/robmartin/Projects/americana-neue/node_modules/.pnpm/[email protected]/node_modules/drizzle-kit/index.cjs:11845:33)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5) {
code: 'ER_UNKNOWN_ERROR',
errno: 1105,
sql: 'SELECT table_name, column_name\n' +
' FROM information_schema.table_constraints t\n' +
' LEFT JOIN information_schema.key_column_usage k\n' +
' USING(constraint_name,table_schema,table_name)\n' +
" WHERE t.constraint_type='PRIMARY KEY'\n" +
" and table_name != '__drizzle_migrations'\n" +
' AND t.table_schema = ?',
sqlState: 'HY000',
sqlMessage: 'rpc error: code = Unknown desc = uncaught panic: interface conversion: interface is nil, not sqlparser.Expr, vtgate:
1 Reply
focused_morning
focused_morningOP17mo ago
so, instead of using introspect I created all of the schemas. Now when I db push I get the same error
interface is nil, not sqlparser.Expr
interface is nil, not sqlparser.Expr
it also says this, which seems to suggest it has columns but no table? [⣟] 0 tables fetching [⣟] 16 columns fetching [⣟] 0 enums fetching [⣟] 0 indexes fetching [⣟] 0 foreign keys fetching seems related to 0.19.11, I switched to 0.19.1 and its working. narrowed it down to drizzle-kit: v0.19.6
Want results from more Discord servers?
Add your server