File tree Expand file tree Collapse file tree 2 files changed +5
-3
lines changed Expand file tree Collapse file tree 2 files changed +5
-3
lines changed File renamed without changes.
Original file line number Diff line number Diff line change 17
17
BASE_URL = "https://comicvine.gamespot.com/api/"
18
18
HEADERS = {"User-Agent" : "Python Comic Vine Client" }
19
19
20
- # Change this to the comic series you want to display:
21
- SEARCH_QUERY = "Weird Science"
20
+ # List of comic series to display, separated by commas. You can add more series to this list, or change the existing ones.
21
+ SEARCH_QUERIES = [ "Weird Science" ]
22
22
# Set to True to pick a random volume from the query results (this is helpful if the series is split into multiple volumes):
23
23
RANDOM_VOLUME = False
24
24
@@ -88,7 +88,9 @@ def display_image_on_inky(image_url):
88
88
89
89
90
90
try :
91
- volume_id = find_volume_id (API_KEY , SEARCH_QUERY )
91
+ # Pick a random search term from the list
92
+ search_query = random .choice (SEARCH_QUERIES )
93
+ volume_id = find_volume_id (API_KEY , search_query )
92
94
comic_image_url = fetch_random_comic_image (API_KEY , volume_id )
93
95
display_image_on_inky (comic_image_url )
94
96
except Exception as e :
You can’t perform that action at this time.
0 commit comments