this bug started to happen after discord updated their api
Reproduction Steps
File "main.py", line 14, in
client.run("TOKEN")
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/client.py", line 938, in run
asyncio.run(runner())
File "/nix/store/2vm88xw7513h9pyjyafw32cps51b0ia1-python3-3.8.12/lib/python3.8/asyncio/runners.py", line 44, in run
return loop.run_until_complete(main)
File "/nix/store/2vm88xw7513h9pyjyafw32cps51b0ia1-python3-3.8.12/lib/python3.8/asyncio/base_events.py", line 616, in run_until_complete
return future.result()
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/client.py", line 927, in runner
await self.start(token, reconnect=reconnect)
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/client.py", line 857, in start
await self.login(token)
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/client.py", line 698, in login
data = await state.http.static_login(token.strip())
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/http.py", line 991, in static_login
await self.startup()
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/http.py", line 562, in startup
self.super_properties, self.encoded_superproperties = sp, = await utils._get_info(session)
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/utils.py", line 1446, in _get_info
bn = await _get_build_number(session)
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/utils.py", line 1478, in _get_build_number
return int(build_file[build_index : build_index + 6])
ValueError: invalid literal for int() with base 10: 'ERV2'
should work and update the tokens discords status and custom emoji
Actual Results
File "main.py", line 14, in
client.run("TOKEN")
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/client.py", line 938, in run
asyncio.run(runner())
File "/nix/store/2vm88xw7513h9pyjyafw32cps51b0ia1-python3-3.8.12/lib/python3.8/asyncio/runners.py", line 44, in run
return loop.run_until_complete(main)
File "/nix/store/2vm88xw7513h9pyjyafw32cps51b0ia1-python3-3.8.12/lib/python3.8/asyncio/base_events.py", line 616, in run_until_complete
return future.result()
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/client.py", line 927, in runner
await self.start(token, reconnect=reconnect)
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/client.py", line 857, in start
await self.login(token)
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/client.py", line 698, in login
data = await state.http.static_login(token.strip())
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/http.py", line 991, in static_login
await self.startup()
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/http.py", line 562, in startup
self.super_properties, self.encoded_superproperties = sp, = await utils._get_info(session)
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/utils.py", line 1446, in _get_info
bn = await _get_build_number(session)
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/utils.py", line 1478, in _get_build_number
return int(build_file[build_index : build_index + 6])
ValueError: invalid literal for int() with base 10: 'ERV2'
System Information
Python v3.8.12-final
discord.py-self v2.0.0-final
aiohttp v3.8.3
system info: Linux 6.2.0-1018-gcp #20~22.04.1-Ubuntu SMP Mon Oct 23 12:29:43 UTC 2023
Checklist
[x] I have searched the open issues for duplicates.
[X] I have shared the entire traceback.
[X] I am using a user token (and it isn't visible in the code).
Summary
this bug started to happen after discord updated their api
Reproduction Steps
File "main.py", line 14, in
client.run("TOKEN")
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/client.py", line 938, in run
asyncio.run(runner())
File "/nix/store/2vm88xw7513h9pyjyafw32cps51b0ia1-python3-3.8.12/lib/python3.8/asyncio/runners.py", line 44, in run
return loop.run_until_complete(main)
File "/nix/store/2vm88xw7513h9pyjyafw32cps51b0ia1-python3-3.8.12/lib/python3.8/asyncio/base_events.py", line 616, in run_until_complete
return future.result()
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/client.py", line 927, in runner
await self.start(token, reconnect=reconnect)
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/client.py", line 857, in start
await self.login(token)
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/client.py", line 698, in login
data = await state.http.static_login(token.strip())
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/http.py", line 991, in static_login
await self.startup()
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/http.py", line 562, in startup
self.super_properties, self.encoded_superproperties = sp, = await utils._get_info(session)
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/utils.py", line 1446, in _get_info
bn = await _get_build_number(session)
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/utils.py", line 1478, in _get_build_number
return int(build_file[build_index : build_index + 6])
ValueError: invalid literal for int() with base 10: 'ERV2'
Code
Expected Results
should work and update the tokens discords status and custom emoji
Actual Results
File "main.py", line 14, in
client.run("TOKEN")
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/client.py", line 938, in run
asyncio.run(runner())
File "/nix/store/2vm88xw7513h9pyjyafw32cps51b0ia1-python3-3.8.12/lib/python3.8/asyncio/runners.py", line 44, in run
return loop.run_until_complete(main)
File "/nix/store/2vm88xw7513h9pyjyafw32cps51b0ia1-python3-3.8.12/lib/python3.8/asyncio/base_events.py", line 616, in run_until_complete
return future.result()
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/client.py", line 927, in runner
await self.start(token, reconnect=reconnect)
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/client.py", line 857, in start
await self.login(token)
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/client.py", line 698, in login
data = await state.http.static_login(token.strip())
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/http.py", line 991, in static_login
await self.startup()
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/http.py", line 562, in startup
self.super_properties, self.encoded_superproperties = sp, = await utils._get_info(session)
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/utils.py", line 1446, in _get_info
bn = await _get_build_number(session)
File "/home/runner/zersy/venv/lib/python3.8/site-packages/discord/utils.py", line 1478, in _get_build_number
return int(build_file[build_index : build_index + 6])
ValueError: invalid literal for int() with base 10: 'ERV2'
System Information
Checklist
Additional Information
the same code used to work for years