Comments (2)
Okay, it seems like the SQL file was in fact the problem.
Specifically, it seems like if there are any multi-line comments in the SQL file, the migration process will crash (and somehow not be catched by the try-catch block and therefore the ROLLBACK
instruction). If I filter out the multi-line comment stmt
blocks using the \n*\/\*
RegEx, it works.
The fact that an empty migration file crashed as well for me seems to have been a cache issue.
I don't know if this is intended behavior, but if it is, it's nowhere documented.
from drizzle-orm.
I may have experienced the same problem just now. I made some changes to the schema for the app I'm developing and ran the migration command. When I tried to start the app again, Expo Go entirely crashed and returned to the Expo dashboard. Tried a few things, clearing cache, etc. no luck in either Android or iOS simulators.
Fortunately I found your issue when searching for possible causes; sure enough the new migration SQL file contained a multiline comment regarding a .notNull()
I was trying to remove from the schema. I took it out and now Expo successfully starts the app so I can continue working (Thanks to you 🫡 I don't know how long it would have taken me to troubleshoot).
I've really gotten to like Drizzle and would be happy to hear if this bug could be prevented so that other devs won't run into the same problem.
- Expo SDK 51.0.8
- expo-sqlite 14.0.3
- drizzle-orm 0.30.10
from drizzle-orm.
Related Issues (20)
- [FEATURE]: add brackets for every column into select
- [FEATURE]: Support for MongoDB.
- [BUG]: drizzle lets you write string to json pg column
- [BUG]: database url not parsing password properly
- [BUG]: UNION with magic SQL + AS is ignored HOT 1
- [BUG]: TypeError: Do not know how to serialize a BigInt
- [BUG]: drizzle-kit push TypeError Cannot use 'in' operator to search for 'default' in undefined HOT 2
- [BUG]: Typing issue when using tables with the same name across different schemas
- [BUG]: Unable to provide sql value in $onUpdate
- [BUG]: drizzle-kit push is not detecting Postgres enum label already exists
- [BUG]: SQl commands in wrong roder
- [FEATURE]: column.as("alias") method
- [FEATURE]: transform/alias raw row properties HOT 1
- [BUG]: PgEnum does not work with Xata Postgres Beta (got unsupported statement [DO] on regular level)
- [BUG]: Type error when using subquery in where
- [BUG]: Postgres push fails due to lack of quotes
- [FEATURE]: Fuzzy string matching functions
- [BUG]: Postgres Schema and Table name not properly escaped HOT 1
- [BUG]:Dependency conflict error with React 18.3.1 during installation HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from drizzle-orm.