Middleman fails when writing to report database