simplify some logging calls

This commit is contained in:
Mike Fährmann
2019-12-10 21:30:08 +01:00
parent c9ef1b21c3
commit c4702ec9b6
4 changed files with 6 additions and 6 deletions

View File

@@ -243,7 +243,7 @@ class PinterestAPI():
if response.status_code == 404 or response.history:
resource = self.extractor.subcategory.rpartition("-")[2]
raise exception.NotFoundError(resource)
self.extractor.log.debug("%s", response.text)
self.extractor.log.debug("Server response: %s", response.text)
raise exception.StopExtraction("API request failed")
def _pagination(self, resource, options):

View File

@@ -156,8 +156,8 @@ class TumblrExtractor(Extractor):
invalid = types - POST_TYPES
if invalid:
types = types & POST_TYPES
self.log.warning('invalid post types: "%s"',
'", "'.join(sorted(invalid)))
self.log.warning("Invalid post types: '%s'",
"', '".join(sorted(invalid)))
return types
@staticmethod