Ingredients and MariaDB don't work well together #2304
mamhoff
started this conversation in
Show and tell
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Steps to reproduce
Try using any
Alchemy::Ingredientwith a MariaDB database. You'll get an error such as:Expected behavior
The upgrader should create ingredients.
Reasons
MariaDB differs from MySQL in that they do not provide a native JSON datatype, and thus Rails does not know that the
datacolumn is, in fact, a JSON column. You can fix it by modifying theAlchemy::Ingredientclass as such:We can't do this globally, because for MySQL and Postgres this is not necessary and will generate a bunch of warnings.
It is also hard to do conditionally, because we do not want to access the database on app startup.
System configuration
All reactions