Open ssynical opened 7 months ago
the error suggest it cant fetch build url from discord perhaps discord introduced some breaking changes to their api and now won't it work with the old discord.py. i will look into this when i get home
yup fixed it, and now get another error with a token i have confirmed works:
C:\Users\hello\Downloads\self-reaction-bot (1)>py -V:3.10 main.py ERROR:root:Login failed. Make sure you're using a valid user token. ERROR:asyncio:Unclosed client session client_session: <aiohttp.client.ClientSession object at 0x000002BD726A4E50> ERROR:asyncio:Unclosed connector connections: ['[(<aiohttp.client_proto.ResponseHandler object at 0x000002BD72667760>, 18348.296)]'] connector: <aiohttp.connector.TCPConnector object at 0x000002BD726A4C70>
hi, im sorry for the delay, it is the issue is with the api wrapper itself ive done some testing and the bot works correctly using the development version, you can install it by running
git clone https://github.com/dolfies/discord.py-self
cd discord.py-self
python -m pip install -U .
if the error keeps occuring make sure you are not using it alongside the upstream discord.py
in the future id like to migrate to another wrapper, but i dont know any. im open for suggestions
I'm also get this, using the master branch fixed it
this is the error i receive, have tried it with py 3.12 and py 3.10 too
ERROR:root:An error occurred while running the bot: list index out of range Traceback (most recent call last): File "C:\Users\hello\Downloads\self-reaction-bot\main.py", line 82, in
loop.run_until_complete(client.start(user_token))
File "C:\Users\hello\AppData\Local\Programs\Python\Python39\lib\asyncio\base_events.py", line 642, in run_until_complete
return future.result()
File "C:\Users\hello\AppData\Local\Programs\Python\Python39\lib\site-packages\discord\client.py", line 857, in start
await self.login(token)
File "C:\Users\hello\AppData\Local\Programs\Python\Python39\lib\site-packages\discord\client.py", line 698, in login
data = await state.http.static_login(token.strip())
File "C:\Users\hello\AppData\Local\Programs\Python\Python39\lib\site-packages\discord\http.py", line 991, in static_login
await self.startup()
File "C:\Users\hello\AppData\Local\Programs\Python\Python39\lib\site-packages\discord\http.py", line 562, in startup
self.super_properties, self.encoded_superproperties = sp, = await utils._get_info(session)
File "C:\Users\hello\AppData\Local\Programs\Python\Python39\lib\site-packages\discord\utils.py", line 1446, in _get_info
bn = await _get_build_number(session)
File "C:\Users\hello\AppData\Local\Programs\Python\Python39\lib\site-packages\discord\utils.py", line 1474, in _get_build_number
build_url = 'https://discord.com/assets/' + re.compile(r'assets/+([a-z0-9]+).js').findall(login_page)[-2] + '.js'
IndexError: list index out of range