refactoring: cleanup and linting in dnf.exceptions.