I have no idea why these are popping up, I get onto vs code and these show up.
prfx = (Back.RED + Fore.BLACK + time.strftime('%H:%M:%S UTC', time.gmtime()))
print(prfx + ' Logged in as ' + Fore.LIGHTCYAN_EX + client.user.name)
The above code snippet is what the error is from name
.
Then i get one for almost every embeds
variable (this only shows an error for the code that has interaction.message.embeds
Then lastly I have one for my embed color code
“Cannot assign to attribute “default” for class “TextInput[Unknown]”
``` def __init__(self, original_embed: discord.Embed):
super(general, self).__init__()
self.title_default = original_embed.title if original_embed.title else ""
self.desc_default = original_embed.description if original_embed.description else ""
self.color_default = original_embed.color if original_embed.color else ""
self.titl.default = self.title_default
self.desc.default = self.desc_default
self.hex_color.default = self.color_default (where the error occurs)
full bot setup code
def __init__(self):
super().__init__(command_prefix='kb ', intents=discord.Intents.all(),help_command=None)
self.cogslist = ["cog1","cog3"]
async def setup_hook(self):
for ext in self.cogslist:
await self.load_extension(ext)
async def on_ready(self):
prfx = (Back.RED + Fore.BLACK + time.strftime('%H:%M:%S UTC', time.gmtime()))
print(prfx + ' Logged in as ' + Fore.LIGHTCYAN_EX + client.user.name)
print(prfx + " Python Version " + Fore.LIGHTCYAN_EX + str(platform.python_version()))
print(prfx + ' Current Discord Version '+ Fore.LIGHTCYAN_EX + str(discord.__version__))
I know this might not be an ideal setup, but i’m still in a learning phase so ill change it soon.
But what i don’t understand is everything works the way its suppose to, no errors pop up in console.