but this might (or not!) be because the branch is not found. For example, what if `/usr/bin/` is not in the path and the exception is raised?

An error that could be a bit more generic might be better here, something like: 

    log.exception('Encountered errors while trying to switch to branch %s' % branch)

It would also be useful to have something that wraps these subprocess calls so that it automatically logs the command that was attempted.

It would be useful just so we can keep track of what is going on before the exception.