I was using yaml_db for an old project recently, one that I had to set up again on my development machine, and my intention was to pull down data from the current production site. Well, due to a silly oversight on my part, I was had not actually checked out the version running in production, and a migration was not present. Trying to run rake db:data:load on my production data resulted in a rather mysterious error:
$ bundle rake db:data:load
rake aborted!
PG::Error: ERROR: current transaction is aborted, commands ignored until end of transaction block
: DELETE FROM "admins"
Tasks: TOP => db:data:load
(See full trace by running task with --trace)
The problem was the admins table was not actually in the database, but this was not apparent to me from the log. And running with --trace did not improve the error message at all. Is it possible a more descriptive error from postgres is getting swallowed by yaml_db somewhere? Or is a transaction swallowing it?
Hi!
I was using yaml_db for an old project recently, one that I had to set up again on my development machine, and my intention was to pull down data from the current production site. Well, due to a silly oversight on my part, I was had not actually checked out the version running in production, and a migration was not present. Trying to run
rake db:data:load
on my production data resulted in a rather mysterious error:The problem was the
admins
table was not actually in the database, but this was not apparent to me from the log. And running with--trace
did not improve the error message at all. Is it possible a more descriptive error from postgres is getting swallowed by yaml_db somewhere? Or is a transaction swallowing it?