ITADN

[BUG]: drizzle-kit pull, fails using mssql dialect when decimal is null

#5726Closedrtncdevs 创建于 2026-05-06
bug1.0.0-beta.*
R
rtncdevscommented
### Report hasn't been filed before. - [x] I have verified that the bug I'm about to report hasn't been filed before. ### What version of `drizzle-orm` are you using? 1.0.0-beta.22 ### What version of `drizzle-kit` are you using? 1.0.0-beta.22 ### Other packages _No response_ ### Describe the Bug Using "npx drizzle-kit pull" gave this error. Cannot read properties of null (reading 'replace') TypeError: Cannot read properties of null (reading 'replace') at Object.defaultFromIntrospect (C:\Data\VisualStudio\Projects\NODEJS\ncs-node-express-hr-data\node_modules\drizzle-kit\bin.cjs:31733:22) at parseDefault$1 (C:\Data\VisualStudio\Projects\NODEJS\ncs-node-express-hr-data\node_modules\drizzle-kit\bin.cjs:31483:26) at fromDatabase (C:\Data\VisualStudio\Projects\NODEJS\ncs-node-express-hr-data\node_modules\drizzle-kit\bin.cjs:241551:14) at process.processTicksAndRejections (node:internal/process/task_queues:104:5) at async fromDatabaseForDrizzle (C:\Data\VisualStudio\Projects\NODEJS\ncs-node-express-hr-data\node_modules\drizzle-kit\bin.cjs:241617:15) Using AI chat mode, it purports to fix the error by including a null guard inside Decimal.defaultFromInspect, after trying the non-beta version of drizzle-kit, and and the latest RC versions. I've not included the patch, as I'm unsure whether it's just fixing a local issue, or whether there are wider issues are play. After applying the fix the pull migration ran, and a schema was created, I've not explored whether the schema is correct.
关闭于 2026-05-21 1 条评论