don't return SQL to the user when there is an IntegrityError, DataError, or ProgrammingError

fixes #280
Merge pull request #343 from goodscloud/jsonify-security-fixes-280

don't return SQL to the user when there is an IntegrityError, DataError, or ProgrammingError