-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MySQL Time is not resolved in YAML #7
Comments
Thanks for reporting this bug. It seems that mysql time objects really don't play nice with yaml in ruby 1.9.3 and appear as empty objects Can you try add this to your gem file:
and then This might slow it down if you have a large data set. But more important for it to work. |
Ok. Thanks for the fix. It worked like a charm :) |
Updating version to 0.0.11, including fixes from issue #7.
The generated .yml files doesn't contain the right values for time fields in a mysql database. For example the created_at and updated_at fields.
Here is a part from a yml file:
updated_at: !ruby/object:Mysql::Time {}
ActiveRecord::Base.connection.select_all generate an array with hashes. The value for the time fields in the hashes is a Mysql::Time instead of an string. I think YAML.dump can't convert an instance from Mysql::Time into a string.
It would be nice, if you can fix this bug.
The text was updated successfully, but these errors were encountered: