mirror of
https://github.com/spalencsar/bearhub.git
synced 2026-07-07 00:04:15 +02:00
flake warnings (#304)
This commit is contained in:
@@ -112,5 +112,5 @@ class DefaultMemoryCacheFactory(MemoryCacheFactory):
|
||||
|
||||
if self.cleaner:
|
||||
self.cleaner.register(instance)
|
||||
|
||||
|
||||
return instance
|
||||
|
||||
@@ -54,7 +54,7 @@ def get_locale_keys(key: str = None, locale_dir: str = resource.get_path('locale
|
||||
|
||||
if current_locale is None or current_locale[0] is None:
|
||||
current_locale = ('en', 'UTF-8')
|
||||
except:
|
||||
except Exception:
|
||||
current_locale = ('en', 'UTF-8')
|
||||
|
||||
else:
|
||||
@@ -83,7 +83,7 @@ def get_locale_keys(key: str = None, locale_dir: str = resource.get_path('locale
|
||||
try:
|
||||
keyval = line_strip.split('=')
|
||||
locale_obj[keyval[0].strip()] = keyval[1].strip()
|
||||
except:
|
||||
except Exception:
|
||||
print("Error decoding i18n line '{}'".format(line))
|
||||
|
||||
return locale_path.split('/')[-1], locale_obj
|
||||
|
||||
@@ -69,7 +69,7 @@ def clean_app_files(managers: List[SoftwareManager], logs: bool = True):
|
||||
shutil.rmtree(path)
|
||||
if logs:
|
||||
print('{}[bauh] Directory {} deleted{}'.format(Fore.YELLOW, path, Fore.RESET))
|
||||
except:
|
||||
except Exception:
|
||||
if logs:
|
||||
print('{}[bauh] An exception has happened when deleting {}{}'.format(Fore.RED, path, Fore.RESET))
|
||||
traceback.print_exc()
|
||||
|
||||
Reference in New Issue
Block a user