Fix for 500s

2 quota fixes needed for Production release.

I'm probably going to have to do some flake8 fixes as well. They were *way* more locally than I was expecting (many not in my code change), so I'm wondering what Travis is going to say.
Yeah, I'm not sure how our database layer would work today if the quota raised an exception mid-loop. I don't doubt there could be orphaned rows.