Bookworm-project / BookwormDB

Tools for text tokenization and encoding
MIT License
84 stars 12 forks source link

Travis build can't handle unicode strings in query #124

Closed bmschmidt closed 7 years ago

bmschmidt commented 7 years ago

Although it works fine under OS X, I'm getting an error when running a query with a unicode word (Cherokee characters) on Travis.

It's raised by MySQL when the API is called:

OperationalError: (1267, "Illegal mix of collations (latin1_swedish_ci,IMPLICIT) and (utf8_general_ci,COERCIBLE) for operation '='")

There must be somewhere that either the host or the client of MySQL isn't being coerced into using unicode.

I'm not sure if this is Travis-specific, or likely to occur on a lot of Ubuntu platforms.

bmschmidt commented 7 years ago

I have added an explicit forcing of unicode to the db creation code which seems to fix this on Travis.

https://github.com/Bookworm-project/BookwormDB/commit/a64186650f1137a2abd5ec7d8909be2245b518bd