My discord bot isnt responding with no error messages.(Python)

Viewed 35

The bot hasnt been responding to commands with no error messages. I am also coding it on replit so if you know of any issues to do with that please say. If there are any problems to do with it please recommend any other online editors as I cannot keep my computer online 24/7.I d have commands but they are related to me and my friends so I prefer to keep them secret.

from replit import db
import discord
import os
import random as r
from flask import Flask
from threading import Thread

app = Flask('')

@app.route('/')
def home():
    return "I'm in boi."


def run():
    app.run(host='0.0.0.0', port=8080)


def keep_alive():
    t = Thread(target=run)
    t.start()

from discord.ext import commands

TOKEN = os.environ['token']

bot = commands.Bot(command_prefix='f!')
bot.remove_command('help')

@bot.event
async def on_ready():
    await bot.change_presence(activity=discord.Activity(
        type=discord.ActivityType.watching, name="f!help"))
    keep_alive()
                
bot.run(TOKEN)
0 Answers
Related