You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I cant seem to figure out the exact reason it occurs but some search terms result in a "list index out of range".
im using this with a discord bot and so far everything is working except for a few random searches like searching safebooru for "rem" or rule34 for "princess_rosalina". (Both of these searches work on the actual site itself.
exact error:
`[2022-10-08 20:08:46] [ERROR ] discord.client: Ignoring exception in on_message
Traceback (most recent call last):
File "C:\Users\xxxxx\AppData\Local\Programs\Python\Python310\lib\site-packages\booru\client\safebooru.py", line 139, in search
return better_object(self.not_random[randint(0, len(self.not_random))])
IndexError: list index out of range
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\Users\xxxxx\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\client.py", line 409, in _run_event
await coro(*args, **kwargs)
File "C:\Users\xxxxx\Downloads\Python programs\waifu.py", line 109, in on_message
res = await imgs.search(query=content, random=True, gacha=True)
File "C:\Users\xxxxx\AppData\Local\Programs\Python\Python310\lib\site-packages\booru\client\safebooru.py", line 148, in search
raise ValueError(f"Failed to get data: {e}")
ValueError: Failed to get data: list index out of range`
OS: windows 11
Python: 3.10.7
The text was updated successfully, but these errors were encountered:
I cant seem to figure out the exact reason it occurs but some search terms result in a "list index out of range".
im using this with a discord bot and so far everything is working except for a few random searches like searching safebooru for "rem" or rule34 for "princess_rosalina". (Both of these searches work on the actual site itself.
exact error:
`[2022-10-08 20:08:46] [ERROR ] discord.client: Ignoring exception in on_message
Traceback (most recent call last):
File "C:\Users\xxxxx\AppData\Local\Programs\Python\Python310\lib\site-packages\booru\client\safebooru.py", line 139, in search
return better_object(self.not_random[randint(0, len(self.not_random))])
IndexError: list index out of range
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\Users\xxxxx\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\client.py", line 409, in _run_event
await coro(*args, **kwargs)
File "C:\Users\xxxxx\Downloads\Python programs\waifu.py", line 109, in on_message
res = await imgs.search(query=content, random=True, gacha=True)
File "C:\Users\xxxxx\AppData\Local\Programs\Python\Python310\lib\site-packages\booru\client\safebooru.py", line 148, in search
raise ValueError(f"Failed to get data: {e}")
ValueError: Failed to get data: list index out of range`
The text was updated successfully, but these errors were encountered: