Monday, 6 August 2012

Padrino, Datamapper, Rake, Uninitialized Constant

So, perhaps you've set up a fancy application using padrino, datamapper and sqlite and you are going great guns until
padrino rake dm:migrate
=> Executing Rake dm:migrate ...

rake aborted!
uninitialized constant Text
Or something similar - the datatype is probably not too important. The solution is to edit your migration and put the datatype into quotes....like this:
column :description, "TEXT"
There seems to be a bug with the use of datamapper and the migration. I'm not sure where the bug is, but this fixes it!

1 comment:

  1. Thanks for the tip, it fixed my migration.

    ReplyDelete