~cloud-init-dev/cloud-init/trunk

« back to all changes in this revision

Viewing changes to cloudinit/distros/__init__.py

Enable flake8 and fix a large amount of reported issues

Show diffs side-by-side

added added

removed removed

Lines of Context:
50
50
LOG = logging.getLogger(__name__)
51
51
 
52
52
 
 
53
@six.add_metaclass(abc.ABCMeta)
53
54
class Distro(object):
54
 
    __metaclass__ = abc.ABCMeta
55
55
 
56
56
    usr_lib_exec = "/usr/lib"
57
57
    hosts_fn = "/etc/hosts"
97
97
        try:
98
98
            res = os.lstat('/run/systemd/system')
99
99
            return stat.S_ISDIR(res.st_mode)
100
 
        except:
 
100
        except Exception:
101
101
            return False
102
102
 
103
103
    @abc.abstractmethod