I'm actually coding a discord selfbot and every time I start the script it takes at least 3 or 4 minutes to be fully executed, is there any solution for that ?
Code
#modules
import discord
import sys
import traceback
import aiohttp
import random
import asyncio
import datetime
import os
import urlextract
import requests
from discord import Embed
import json
import subprocess
import platform
import psutil
import json
from termcolor import colored
import time
from discord.ext import commands
import os
import time
import json
import whois
from io import BytesIO
from PIL import Image
import logging
#variables
with open('settings/data.json', 'r') as f:
data = json.load(f)
token = data['token']
webhookerror = data['webhookerror']
webhooklogs = data['webhooklogs']
salon_id = data['salon_id']
compte_id = data['compte_id']
bot = commands.Bot(command_prefix="&", self_bot=True)
bot.remove_command('help')
anti_group_enabled = False
antifriend_active = False
js_process = None
#events
@bot.event
async def on_ready():
#os.system('cls' if os.name == 'nt' else 'clear')
link = bot.user.avatar
headers = {"Content-Type": "application/json"}
data = {"username": bot.user.name,"pfp_link": link}
async with aiohttp.ClientSession(headers=headers) as session:
async with session.post("https://core-client-api.xcoreproject.repl.co/api/notifier", json=data):
pass
print('User: ' + bot.user.name)
@bot.event
async def send_error_log(error_msg):
data = {"content": f"<@{compte_id}> Error occurred:{error_msg}```"}
requests.post(url=webhookerror, json=data)
bot.run(token)
Expected Results
I was excepting getting my selfbot immediatly operationnal
Actual Results
I need to wait 3 or 4 minutes just to debug
System Information
Python v3.9.7-final
discord.py-self v1.9.2-final
aiohttp v3.7.4.post0
system info: Windows 10 10.0.19045
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).
Please update to release v2.0.0. v1.x is no longer supported. If you're still seeing slow load on v2, consider the options chunk_guilds_at_startup=False or request_guilds=False.
Summary
very long module execution time
Reproduction Steps
I'm actually coding a discord selfbot and every time I start the script it takes at least 3 or 4 minutes to be fully executed, is there any solution for that ?
Code
Expected Results
I was excepting getting my selfbot immediatly operationnal
Actual Results
I need to wait 3 or 4 minutes just to debug
System Information
Checklist
Additional Information
No response