AttributeError: 'Database' object has no attribute 'compiler'
Is database the flask peewee wrapper? Have you tried database.database in that case?
 Awesome! That was indeed the problem!

Thanks a million. Both for solving this, and for creating Peewee. We're already using it in several websites now. Big thumbs up!

I'm trying to use the peewee migration [described here](http://peewee.readthedocs.org/en/latest/peewee/playhouse.html#schema-migrations).  But when running the migrate command I get the error below this message.

I'm on Ubuntu 14.04 with Python 2.7 with the regular MySQL from the apt repos.

Anybody any idea what could be wrong here? All tips are welcome!

```
Traceback (most recent call last):
  File "<input>", line 1, in <module>
  File "/usr/local/lib/python2.7/dist-packages/playhouse/migrate.py", line 575, in migrate
    operation.run()
  File "/usr/local/lib/python2.7/dist-packages/playhouse/migrate.py", line 144, in run
    getattr(self.migrator, self.method)(*self.args, **kwargs))
  File "/usr/local/lib/python2.7/dist-packages/playhouse/migrate.py", line 138, in _handle_result
    self._handle_result(item)
  File "/usr/local/lib/python2.7/dist-packages/playhouse/migrate.py", line 135, in _handle_result
    result.run()
  File "/usr/local/lib/python2.7/dist-packages/playhouse/migrate.py", line 144, in run
    getattr(self.migrator, self.method)(*self.args, **kwargs))
  File "/usr/local/lib/python2.7/dist-packages/playhouse/migrate.py", line 152, in inner
    return fn(self, *args, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/playhouse/migrate.py", line 190, in alter_add_column
    field_clause = self.database.compiler().field_definition(field)
AttributeError: 'Database' object has no attribute 'compiler'
```
