mirror of
https://github.com/JimmXinu/FanFicFare.git
synced 2026-01-04 07:03:44 +01:00
Use logger.warning() not .warn() consistently.
This commit is contained in:
parent
ad3a16f423
commit
ea66ae350b
4 changed files with 4 additions and 4 deletions
|
|
@ -97,7 +97,7 @@ class FirefoxCache2(BaseBrowserCache):
|
|||
self.add_key_mapping(cache_url,path,created)
|
||||
self.count+=1
|
||||
except Exception as e:
|
||||
logger.warn("Cache file %s failed to load, skipping."%path)
|
||||
logger.warning("Cache file %s failed to load, skipping."%path)
|
||||
logger.debug(traceback.format_exc())
|
||||
# logger.debug(" file time: %s"%datetime.datetime.fromtimestamp(stats.st_mtime))
|
||||
# logger.debug("created time: %s"%datetime.datetime.fromtimestamp(created))
|
||||
|
|
|
|||
|
|
@ -90,7 +90,7 @@ class SimpleCache(BaseBrowserCache):
|
|||
self.add_key_mapping(cache_url,path,created)
|
||||
self.count+=1
|
||||
except Exception as e:
|
||||
logger.warn("Cache file %s failed to load, skipping."%path)
|
||||
logger.warning("Cache file %s failed to load, skipping."%path)
|
||||
logger.debug(traceback.format_exc())
|
||||
|
||||
# key == filename for simple cache
|
||||
|
|
|
|||
|
|
@ -1039,7 +1039,7 @@ class Configuration(ConfigParser):
|
|||
age_limit=self.getConfig("browser_cache_age_limit"))
|
||||
fetcher.BrowserCacheDecorator(self.browser_cache).decorate_fetcher(self.fetcher)
|
||||
except Exception as e:
|
||||
logger.warn("Failed to setup BrowserCache(%s)"%e)
|
||||
logger.warning("Failed to setup BrowserCache(%s)"%e)
|
||||
raise
|
||||
## cache decorator terminates the chain when found.
|
||||
logger.debug("use_basic_cache:%s"%self.getConfig('use_basic_cache'))
|
||||
|
|
|
|||
|
|
@ -179,7 +179,7 @@ def cleanup_url(href,configuration,foremail=False):
|
|||
href = adapter.get_request_redirected(href)[1]
|
||||
href = href.replace('&index=1','')
|
||||
except Exception as e:
|
||||
logger.warn("Skipping royalroad email URL %s, got HTTP error %s"%(href,e))
|
||||
logger.warning("Skipping royalroad email URL %s, got HTTP error %s"%(href,e))
|
||||
return href
|
||||
|
||||
def get_urls_from_imap(srv,user,passwd,folder,markread=True):
|
||||
|
|
|
|||
Loading…
Reference in a new issue