Rather than nested try/catch blocks, could you catch DoesNotExist before DatabaseError?