Flake8 bugbear fixes (#12072)

* Don't use mutable argument defaults (bugbear B006)

* Use callable(x) instead of hasattr(x, '__call__') (bugbear B004)

* Remove/mark unused loop control variables (bugbear B007)

* Fix stripping protocol from kodi host name (bugbear B005)

* Fix plant daily history add default date (bugbear B008)
This commit is contained in:
Ville Skyttä authored and Paulus Schoutsen committed 2018-01-30 14:44:05 -08:00
1 parent 37034a7450
commit cab6c694c5
15 files changed
+23 -22

No files matched your search

+1 -1
View File
@@ -134,7 +134,7 @@ def run(script_args: List) -> int:
for sfn, sdict in res['secret_cache'].items():
sss = []
for skey, sval in sdict.items():
for skey in sdict:
if skey in flatsecret:
_LOGGER.error('Duplicated secrets in files %s and %s',
flatsecret[skey], sfn)