diff --git a/hues/console.py b/hues/console.py index 4d11e73..5e7e2cb 100644 --- a/hues/console.py +++ b/hues/console.py @@ -8,10 +8,6 @@ CONFIG_FNAME = '.hues.yml' -if sys.version_info.major == 2: - class FileNotFoundError(IOError): - '''Implement FileNotFoundError in Python 2''' - class InvalidConfiguration(Exception): '''Raise when configuration is invalid.''' @@ -39,7 +35,7 @@ def _load(cdir, recurse=False): if type(conf) is not dict: raise InvalidConfiguration('Configuration at %s is not a dictionary.' % confl) return conf - except FileNotFoundError: + except EnvironmentError: parent = os.path.dirname(cdir) if recurse and parent != cdir: return _load(parent, recurse=True)