The 'else' clause is part of the try/except and gets executed when the try exits without an exception being thrown. I re-arranged this block for a number of reasons: (1) the repo_distributor_manager was being assigned in the try block, but accessed outside of it, which leads to the situation in which it can be accessed without being defined. (2) I like to keep only the calls that can possibly throw exceptions in the try block and keep the except block(s) very specific the the exceptions that can be thrown. This keeps me from inadvertently "handling" an exception. (3) Just general best-practices, keeping it very clear which statements are being handled and which are not.

Sorry for the long explanation, but this is something I've been on a bit of a kick about lately.