diff options
Diffstat (limited to 'gallery_dl/extractor/luscious.py')
| -rw-r--r-- | gallery_dl/extractor/luscious.py | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/gallery_dl/extractor/luscious.py b/gallery_dl/extractor/luscious.py index 8e73964..0cbc523 100644 --- a/gallery_dl/extractor/luscious.py +++ b/gallery_dl/extractor/luscious.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2016-2023 Mike Fährmann +# Copyright 2016-2025 Mike Fährmann # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License version 2 as @@ -26,15 +26,15 @@ class LusciousExtractor(Extractor): "variables" : variables, } response = self.request( - "{}/graphql/nobatch/?operationName={}".format(self.root, op), + f"{self.root}/graphql/nobatch/?operationName={op}", method="POST", json=data, fatal=False, ) if response.status_code >= 400: self.log.debug("Server response: %s", response.text) - raise exception.StopExtraction( - "GraphQL query failed ('%s %s')", - response.status_code, response.reason) + raise exception.AbortExtraction( + f"GraphQL query failed " + f"('{response.status_code} {response.reason}')") return response.json()["data"] @@ -51,7 +51,7 @@ class LusciousAlbumExtractor(LusciousExtractor): def __init__(self, match): LusciousExtractor.__init__(self, match) - self.album_id = match.group(1) + self.album_id = match[1] def _init(self): self.gif = self.config("gif", False) @@ -280,7 +280,7 @@ class LusciousSearchExtractor(LusciousExtractor): def __init__(self, match): LusciousExtractor.__init__(self, match) - self.query = match.group(1) + self.query = match[1] def items(self): query = text.parse_query(self.query) |
