client.run(os.getenv('TOKEN')) not working in python

My Code

import os
import discord
from keep_alive import keep_alive

client = discord.Client()

@client.event
async def on_ready():
  print('We have logged in')

@client.event
async def on_message(message):
  if message.author == client.user:
    return

  msg = message.content

  if msg.startswith('*help'):
    await message.channel.send('This bot is still been made')

keep_alive()
client.run(os.getenv('TOKEN'))

Error

 * Serving Flask app '' (lazy loading)
 * Environment: production
   WARNING: This is a development server. Do not use it in a production deployment.
   Use a production WSGI server instead.
 * Debug mode: off
 * Running on all addresses.
   WARNING: This is a development server. Do not use it in a production deployment.
 * Running on http://172.18.0.3:8080/ (Press CTRL+C to quit)
Traceback (most recent call last):
  File "main.py", line 22, in <module>
    client.run(os.getenv('TOKEN'))
  File "/opt/virtualenvs/python3/lib/python3.8/site-packages/discord/client.py", line 723, in run
    return future.result()
  File "/opt/virtualenvs/python3/lib/python3.8/site-packages/discord/client.py", line 702, in runner
    await self.start(*args, **kwargs)
  File "/opt/virtualenvs/python3/lib/python3.8/site-packages/discord/client.py", line 665, in start
    await self.login(*args, bot=bot)
  File "/opt/virtualenvs/python3/lib/python3.8/site-packages/discord/client.py", line 511, in login
    await self.http.static_login(token.strip(), bot=bot)
  File "/opt/virtualenvs/python3/lib/python3.8/site-packages/discord/http.py", line 300, in static_login
    data = await self.request(Route('GET', '/users/@me'))
  File "/opt/virtualenvs/python3/lib/python3.8/site-packages/discord/http.py", line 216, in request
    raise HTTPException(r, data)
discord.errors.HTTPException: 429 Too Many Requests (error code: 0): You are being blocked from accessing our API temporarily due to exceeding our rate limits frequently. Please read our docs at https://discord.com/developers/docs/topics/rate-limits to prevent this moving forward.
 172.18.0.1 - - [22/Oct/2021 10:21:27] "GET / HTTP/1.1" 200 -

KeyboardInterrupt
 

my apologies, it decided it wanted to work after i re pasted it

The error said the issues was too many requests and you were temporarily blocked from the API

Hi all,
I am trying to troubleshoot/modify my python interpreter. I have downloaded 3.9, but my environment variable still points to the original 3.8 directory. I use ATOM (on occassion) and the CMD to run my little scripts.

  1. If I change the path in “C:\Program Files(X86)\Common Files…” to the new 3.9 directory, does that “break” the CMD path? I’m worried once I remove the 3.8 directory, I will lose ATOM connectivity.
  2. Why does the environment variable have a special variable called, “Python_Home”? Which does point to “C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Python 3.8” Is this the link that runs my ATOM scripts?
    Thanks for any help. https://omegle.onl/

@finacoles2
Please stop posting in other people’s topics.
If you need help, then please create your own topic and people would be glad to help you there. :grinning:

Thanks!