diff options
Diffstat (limited to 'FusionIcon/interface.py')
-rw-r--r-- | FusionIcon/interface.py | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/FusionIcon/interface.py b/FusionIcon/interface.py index 450a7f9..4fa375b 100644 --- a/FusionIcon/interface.py +++ b/FusionIcon/interface.py @@ -30,26 +30,26 @@ interfaces={ def import_interface(interface): try: if interface in interfaces: - print ' * Using the', interfaces[interface], 'Interface' + print(' * Using the', interfaces[interface], 'Interface') __import__('FusionIcon.interface_%s' %interface) else: - print ' *** Error: "%s" interface is invalid, this should not happen' %interface + print(' *** Error: "%s" interface is invalid, this should not happen' %interface) raise SystemExit - except ImportError, e: + except ImportError as e: if [i for i in interfaces if 'interface_%s' %i in str(e)]: - print ' * Interface not installed' + print(' * Interface not installed') else: - print ' *', e + print(' *', e) #doesn't work so remove it from the dict del interfaces[interface] if interfaces: - print ' ... Trying another interface' + print(' ... Trying another interface') choose_interface() else: - print ' *** Error: All interfaces failed, aborting!' + print(' *** Error: All interfaces failed, aborting!') raise SystemExit def choose_interface(try_first=None): @@ -61,7 +61,7 @@ def choose_interface(try_first=None): if try_first in interfaces: chosen_interface = try_first else: - raise SystemExit, ' *** Error: No such interface: %s' %try_first + raise SystemExit(' *** Error: No such interface: %s' %try_first) else: # gtk for everybody for now @@ -83,7 +83,7 @@ def choose_interface(try_first=None): # interfaces is empty else: - raise SystemExit, ' *** no available interfaces, this should not happen' + raise SystemExit(' *** no available interfaces, this should not happen') import_interface(chosen_interface) |