#discord-bots

1 messages · Page 963 of 1

supple thorn
#

You are?

#

Fuck

slate swan
#

idk am i you firgure it out

supple thorn
slate swan
#

too bad😳

supple thorn
#

If you are a she

slate swan
#

styling as?

supple thorn
#

You have a deep ass voice that can fool anyone

slate swan
#

💀

supple thorn
slate swan
#

yes

supple thorn
#

We talked about this a couple days ago

slate swan
#

i keep forgetting i stream

#

😭

supple thorn
#

1 stream

slate swan
supple thorn
#

Lmao

hasty lake
#

Which part of discord?

slate swan
#

@slate swan @hasty lake everything as in this

#

even the font

#

all styling

slate swan
hasty lake
slate swan
#

of your client?

#

and bro what is that msg😭

supple thorn
#

Imagine they add a uwu special font in discord

slate swan
slate swan
supple thorn
#

Like it just adds random uwu to your messages

slate swan
supple thorn
#

Useful for ashley

slate swan
#

ash do you an iphone?

hasty lake
slate swan
supple thorn
supple thorn
slate swan
supple thorn
#

I didn't word it

slate swan
#

heh

slate swan
# slate swan oneplus

fuck, if you had an iphone it would be funny if you had the setting where it converts ily into uwu

supple thorn
slate swan
#

tf is an uwu voice

slate swan
supple thorn
slate swan
supple thorn
#

Dms

hasty lake
#

!rule 7

unkempt canyonBOT
#

7. Keep discussions relevant to the channel topic. Each channel's description tells you the topic.

hasty lake
#

Talk in the off-topic channels.

slate swan
#

Leo😔

#

nobody's even here 😔

#

thank you😔

supple thorn
slate swan
primal cliff
#

hi can someone give me the ban and kick code

hoary cargo
#

!d discord.Member.ban

unkempt canyonBOT
#

await ban(*, delete_message_days=1, reason=None)```
This function is a [*coroutine*](https://docs.python.org/3/library/asyncio-task.html#coroutine).

Bans this member. Equivalent to [`Guild.ban()`](https://discordpy.readthedocs.io/en/master/api.html#discord.Guild.ban "discord.Guild.ban").
hoary cargo
#

!d disnake.Member.kick

unkempt canyonBOT
#

await kick(*, reason=None)```
This function is a [*coroutine*](https://docs.python.org/3/library/asyncio-task.html#coroutine).

Kicks this member. Equivalent to [`Guild.kick()`](https://docs.disnake.dev/en/latest/api.html#disnake.Guild.kick "disnake.Guild.kick").
primal cliff
supple thorn
#

Use it on your member object

supple thorn
hoary cargo
sick birch
#

For most things it’s the same

tough notch
#

!d disnake.Member.kick

slate swan
#

how can i let my bot load a cog on startup?

sick birch
#

Use the setup_hook provided to you in 2.0

#

Or have a main asynchronous startup point for your bot

junior verge
#
@commands.Cog.listener()
    async def on_message_delete(self, message):
    
            channel = self.client.get_channel(954837357239091260)
            deleted = Embed(
                description=f"Message deleted in {message.channel.mention}", color=0x4040EC
            ).set_author(name=message.author, url=Embed.Empty, icon_url=message.author.avatar_url)

            deleted.add_field(name="Message", value=message.content)
            deleted.timestamp = message.created_at
            await channel.send(embed=deleted)
``` is anything wrong with this? it says that it has a invalid form body
maiden fable
#

Sho error

sick birch
#

so the value field was empty which is invalid

keen dust
#

Hello, I'm new to discord bot dev and I'm kinda stuck in the middle of a program to find a word in a message and make the bot reply to it, I tried following a tutorial but it didn't work.

slate swan
#

you would be using the python in statement ```py
message: discord.Message

if "word" in message.content:
...

do your stuff```

keen dust
slate swan
#

may i see your code

keen dust
#

gimme a sec

slate swan
#

alright

keen dust
#
sad_words = ["depressed, unhappy, hate, miserable, pathetic, depressing, sad"]
encouragements = ["You are amazing!", "Happiness!", "You can get through it!"]

def quotes():
    response=requests.get('https://zenquotes.io/api/random')
    json_data = json.loads(response.text)
    quote = json.data[0]['q'] + " -" + json_data[0]['a']
    return quote

@client.event
async def on_message(message):
    if message.author == client.user:
        return
    msg = message.content
 
    if message.content.startswith('!quote!'):
        quote = quotes()
        await message.channel.send('')

  
    if "sad" in msg:
        await message.channel.send(random.choice(encouragements))

#

This is the main part of the code

#

I included the token and other necessary functions

#

I'm trying to make the words loop through the sad_words lists, check it and reply if any of those words are found

keen dust
slate swan
#

What can I do get all the guilds my bot is in
(Not guild name)

#

try making the content lower first

#

msg = message.content.lower()

keen dust
#

ok

slate swan
unkempt canyonBOT
keen dust
#

next

slate swan
#

does bring a change?

keen dust
keen dust
slate swan
keen dust
#

I don't know why

slate swan
#

change .event to .listen()

#

you're using client= commands.Bot(...) right?

slate swan
#

it would be a list of discord.Guild objects

#

ok

slate swan
keen dust
keen dust
# slate swan so just do this and your commands will work
import dis
from tokenize import String
from turtle import setundobuffer
import discord
import random
from discord.ext import commands, tasks
import os
import requests
import json


client = commands.Bot(command_prefix = '.')
sad_words = ["depressed, unhappy, hate, miserable, pathetic, depressing, sad"]
encouragements = ["You are amazing!", "Happiness!", "You can get through it!"]


def quotes():
    response=requests.get('https://zenquotes.io/api/random')
    json_data = json.loads(response.text)
    quote = json.data[0]['q'] + " -" + json_data[0]['a']
    return quote


@client.listen
async def on_message(message):
    if message.author == client.user:
        return
    msg = message.content.lower()
    
    if message.content.startswith('$inspire'):
        quote = quotes()
        await message.channel.send('')  

    if "sad" in msg:
        await message.channel.send(random.choice(encouragements))


@client.event
async def on_ready():
    await client.change_presence(status=discord.Status.online, activity=discord.Game("Ready"))

    print("Bot is ready")

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

    
    if message.content.startswith('$inspire'):
        quote = quotes()
        await message.channel.send('')

    if any(word in msg for word in sad_words):
        await message.channel.send(random.choice(encouragements))

client.run('TOKEN IS HERE')

This is the entire program, edited the @client.listen part

slate swan
#

change all event-s to listen

keen dust
slate swan
keen dust
#

as in @client.event to @client.listen()

slate swan
#

yes ig?

slate swan
slate swan
#

k

keen dust
keen dust
slate swan
#

pleasure

keen dust
hoary cargo
cold sonnet
#

use commands

paper sluice
#
Get-wiki-function                                  -> 0.8879458000010345s
main programm                                      -> 2.478715300007025s

timed my function, and it takes about 1.6s to send the data to discord (main program the sending to discord), any tips on how to improve discord ping, the ping of my bot is like 300ms

cold sonnet
#

you have multiple on messages for nothing

cold sonnet
paper sluice
#

ya

cold sonnet
#

o

vale wing
paper sluice
vale wing
#

Or get faster net

cold sonnet
#

just walk up there and you'll get it

vale wing
#

Nothing else

paper sluice
#

my net is fast, i dont have ethernet, sad moment

vale wing
#

Networking can't be almost instant if it involves remotes

slate swan
#
@client.command()
async def interest(self, ctx):
  roles = {"Coder": 100, "Gamer": 100, "Anime Weeb": 100, "Superior Coder": 150, "Mods": 100, "Partners": 50,
           "Owner": 999999}
  channel = self.client.get_channel(891318288859140096)
  guild = self.client.get_guild(guild.id)
  em = discord.Embed(title="Interest By time : ")
  total = 0
  for members in guild.members:
      try:
          em.add_field(name="Member Name: ", value=members.name)
          for role in [role for role in members.roles if role.name in roles.keys()]:
            em.add_field(name=f"{role} : ", value=roles[role])
            total += roles[role]
            em.add_field(name="Total : ", value=total)
            em.set_footer(text="Type .role_shop to See how you can spend Money",
                          icon_url=channel.guild.owner.avatar_url)
            await ctx.send(embed=em)
          except:
            pass

this is my code and,
im getting invalid syntax error for except:
^

jovial plover
#

tab

vale wing
#

It must be on the same indent level with try

nimble plume
#

bot has admin perms disnake.ext.commands.errors.CommandInvokeError: Command raised an exception: Forbidden: 403 Forbidden (error code: 50013): Missing Permissions

slate swan
#

bot cannot perform moderation operations on owner/users with higher roles

halcyon sparrow
#

I think you need to put something aftrr except

nimble plume
#

i forgot to add try except

halcyon sparrow
#

a kind of error or a catchall for any error

slate swan
#

But now the error is discord.ext.commands.errors.CommandInvokeError: Command raised an exception: AttributeError: ‘Context’ object has no attribute ‘client”

placid skiff
#

Don't answer

#

Now tell me, what the error is sayin?

vale wing
#

Is your command in a cog

slate swan
placid skiff
#

so what do you think that means?

slate swan
#

Context is not having an attribute called ‘client’

placid skiff
#

exactly

vale wing
#

Then wtf for do you have the self arg

keen dust
slate swan
keen dust
#

Wait I can check the documentation

slate swan
#

Remove (self)?

keen dust
#

I'll get back if I have any doubts

vale wing
#

Yes but the question is do you know OOP basics in py

slate swan
maiden fable
#

He is talking about Python itself, not dpy

halcyon sparrow
#

This 'client' is what you called the bot when you told it what prefix to use

slate swan
#

client is the bot

halcyon sparrow
#

Have you read the docs for discord.py? They usually have examples.

slate swan
#

agreed

vale wing
#

OOP is above functional

#

One of the main programming methods in today's world in many languages including python

maiden fable
#

can we take this to an ot channel

vale wing
#

Oh you mean that

#

Well not gonna argue too it won't change anything anyways

#

OOP includes functional doesn't it

#

Objects have methods

#

The only difference I can see is they interact with instance as well

#

Shortly in functional the function is the main unit and in and in OOP the object is

#

But objects do have methods

tough lance
#

Yes discord bots

vale wing
#

I only see this as a disadvantage of functional

#

Ok well this is pointless

slate swan
#

How can I get a guild Id?

unkempt canyonBOT
vale wing
#

Depends what exactly do you mean

#

If you mean get it from discord UI you need to enable developer mode

vale wing
formal basin
#

Anyone know how I can make a custom command command using json

vale wing
#

What

vale wing
#

Json is data storage format how can you make a custom command with it

formal basin
#

But only for that server

#

So that’s why I want to use json

slate swan
#

hm ic, but, why not use sqlite?

formal basin
slate swan
formal basin
#

I’m trying to learn json more

slate swan
#

opposing the opposition

formal basin
#

Would that be for one server

#

Because I don’t want the tag to be in every server

#

I want to connect it to a json file

vale wing
#

Big data with JSON = hell

#

I mean a bad way

primal cliff
#

Can someone help me with creating the ban and kick cmd?

#

I am using replit

#

well my bot is basically a normal chat bot

#

it doesnt have any features like ban or kick or mute

vale wing
#

But if you would like to you could do something like

{"guilds": {
    "12345": {
        "command_name": "command_response"}
    }
}```
lofty tinsel
#

Hello I need help. I am a beginner and I would like to make a command that interacts with what we enter. It's for a Discord bot.
For example I create the command >recipe and in fact it will be necessary to do >recipe + what we want behind (pasta, fries) to have an answer from the bot. And the bot will adapt to the request. If the person wants pasta then the bot will print the pasta recipe. I know how to do that but what I don't know how to do is to make the bot take into account what is behind the order so not >recipe but the dish behind

primal cliff
#

well I have searched the internet for the code

#

but its still doesnt work

#

uhhh Idk it doesnt say on replit but before today i tried getting codes on github and it says 3.3 i think

vale wing
primal cliff
#

oh wait i know how to check

#

wait me a second

#

Python 3.8.2 @slate swan

vale wing
#

He meant the library not the python

vocal plover
#

which discord library?

vocal plover
#

Most likely it'll be one of discord.py, nextcord, disnake, pycord

vale wing
lofty tinsel
#

nothing for the moment because I'm waiting to know how to do it

primal cliff
vale wing
#

Alright what library are you using for requests @lofty tinsel

primal cliff
#

oh ok let me check

lofty tinsel
vale wing
#

It's not for requests

primal cliff
#

It says unident does not match any outer indentation level

#

oh ok

vale wing
#

Could you state in which of these steps are you having issues
make a command -> send a request (get recipe data) -> convert returned data -> send data as a message

unkempt canyonBOT
#

@slate swan :white_check_mark: Your eval job has completed with return code 0.

one egg, etc..
lofty tinsel
#

get recipe data

vale wing
#

You said you know how to make API call lol

#

Well personally I don't know any recipes APIs but I can search for it

lofty tinsel
#

I'm not english So I'm expressing myself badly what I just want to know is how to take into account what is after the command and not just <recipe

vale wing
#

Oh that

#
async def command(ctx, *, thing)```
lofty tinsel
vale wing
#

I just didn't get you right I think (I am not english too)

lofty tinsel
#

ty i'll try

primal cliff
#

How do i fix the indent cause I am very new to python just start using it when my friend told me a few months ago so can someone help me

unkempt canyonBOT
#

Indentation

Indentation is leading whitespace (spaces and tabs) at the beginning of a line of code. In the case of Python, they are used to determine the grouping of statements.

Spaces should be preferred over tabs. To be clear, this is in reference to the character itself, not the keys on a keyboard. Your editor/IDE should be configured to insert spaces when the TAB key is pressed. The amount of spaces should be a multiple of 4, except optionally in the case of continuation lines.

Example

def foo():
    bar = 'baz'  # indented one level
    if bar == 'baz':
        print('ham')  # indented two levels
    return bar  # indented one level

The first line is not indented. The next two lines are indented to be inside of the function definition. They will only run when the function is called. The fourth line is indented to be inside the if statement, and will only run if the if statement evaluates to True. The fifth and last line is like the 2nd and 3rd and will always run when the function is called. It effectively closes the if statement above as no more lines can be inside the if statement below that line.

Indentation is used after:
1. Compound statements (eg. if, while, for, try, with, def, class, and their counterparts)
2. Continuation lines

More Info
1. Indentation style guide
2. Tabs or Spaces?
3. Official docs on indentation

slate swan
#

Yerlikaya😳

slate swan
#

hi, im known for being quickpithink

vale wing
#

I have been authorising an application yesterday and there wasn't such thing

hoary cargo
slate swan
#

i did😔

#

take my place! its not like im gonna be missedyert

#

😔 😳

primal cliff
#

Uhh so I fixed the indent but now it is saying name "bot" is not defined

slate swan
#

anyways gtg later

slate swan
vale wing
#

Ima check rn

slate swan
primal cliff
#

oh ok

vale wing
slate swan
hoary cargo
#

suss i'm pretty sure that 2fa is a required standard, at least for verified bot devs

primal cliff
#

I changed all of the bot to client in the code to give me now the error is "Bot" object has no attribute "has_permissions"

vale wing
#

@slate swan well yeah its true

#

Cringe

hoary cargo
slate swan
vale wing
#

Yes

slate swan
#

I hate 2fa for some reasonsyhuh

vale wing
#

When I was signing up with my alt on dev portal it said "please enable 2fa to sign up"

vale wing
#

Maybe you registered before it was added

slate swan
#

Probably

hoary cargo
#

i just tried rn and for me it doesn't ask for code even if i have 2fa 🗿

vale wing
#

Wth for would they need to ask for the code if we are already logged in and its not a destructive action

primal cliff
#

I changed all of the bot to client in the code to give me now the error is "Bot" object has no attribute "has_permissions"

vale wing
#

Unless you are adding nuke bot

formal basin
#

How can I make a command to def a channel

hoary cargo
slate swan
hoary cargo
formal basin
#

async def channel (ctx, channel):

formal basin
slate swan
vale wing
#

I don't really see a point in adding it to there

hoary cargo
slate swan
hoary cargo
#

can you transfer the ownership to a bot? Kek

vale wing
formal basin
#

To def a role you do async def role(ctx, role: discord.Role):

But I want to def a channel

vale wing
#

At least there's a button

hoary cargo
#

i shall try

slate swan
lofty tinsel
#

I succeeded in making the order but let's imagine that the person makes a mistake and instead of writing pasta she writes pastas with an "s" (we can imagine other possible mistakes) how to make the bot understand that the person wants pasta. Another example, if the person wants pasta and writes (>recipe pasta please sir) how to do to answer the request of the lady because the bot does not understand because there are several words

vale wing
#

Maybe now you can't

#

Idk I haven't tried that

formal basin
#

Yeah but instead of a role I want a channel

#

No

vale wing
lofty tinsel
#

Yes it's a way to answer but isn't there a way to understand what she's asking without answering her with an error message?

vale wing
#

Or other comparison method

formal basin
#

@bot.command()
async def defrole(ctx, role: discord.Role):

lofty tinsel
#

hmm okay i'll try other way

formal basin
primal cliff
#

So I changed all of the bot to client in the code to give me now the error is "Bot" object has no attribute "has_permissions"

formal basin
hoary cargo
formal basin
sick birch
#

What exactly does your defrole command do?

formal basin
formal basin
sick birch
#

So just typehint to channel?

formal basin
#

And do something with it

sick birch
#
@bot.command()
async def channel(ctx, channel: discord.TextChannel):
  ...
vale wing
#

@formal basin I think you need this typehint

from typing import Union

async def command(ctx, something: Union[TextChannel, Role])```
vale wing
#

If you meant alternative between channel and a role

formal basin
lofty tinsel
#
nextcord.ext.commands.errors.CommandInvokeError: Command raised an exception: KeyError: 'test'
``` I have this error message
primal cliff
#

What does a Attribute error mean?

lofty tinsel
#

yes

formal basin
#

I was giving you e.gs

sick birch
#

!e

class MyClass:
  def __init__(self):
    self.x = "Hello, world!"

instance = MyClass()
print(instance.y)
unkempt canyonBOT
#

@sick birch :x: Your eval job has completed with return code 1.

001 | Traceback (most recent call last):
002 |   File "<string>", line 6, in <module>
003 | AttributeError: 'MyClass' object has no attribute 'y'
formal basin
#

It’s ok

lofty tinsel
primal cliff
lofty tinsel
#
@client.command()
async def recipe(ctx, dish):
    dishes = {"pasta":"water, salt", "fries":" potatoes"}
    await ctx.send(dishes[dish])
    if not dish in dishes.keys():
        await ctx.send("hi, we dont have that dish")
            return
lofty tinsel
#

like that?

sick birch
#

Here's an example from the docs:

@bot.command()
@commands.has_permissions(manage_messages=True)
async def test(ctx):
    await ctx.send('You can manage messages.')
sick birch
lofty tinsel
#
@client.command()
async def recipe(ctx, dish):
    dishes = {"pasta":"water, salt", "fries":" potatoes"}
    check await ctx.send(dishes[dish])
    if not dish in dishes.keys():
        await ctx.send("hi, we dont have that dish")
    return
pliant gulch
lofty tinsel
#

idk where i must put the check

sick birch
lofty tinsel
#

there is no check in ur code?

sick birch
#

Also it makes it more readable

pliant gulch
#

Faster than checking for it being in keys() yes

#

It’s a hash map

#

That’s why it’s O(1)

#

Constant time

vale wing
#

Algorithm difficulty measure thing or smth

sick birch
#

Time stays constant regardless of number of instructions

slate swan
#

whenever andy starts explaining something, I always get a stroke

sick birch
#

Hash maps are usually O(1) when it comes to looking up items. I just wasn't aware __contains__ used a hashmap

vale wing
#

"Algorithm complexity measurement" would be valid definition

lofty tinsel
#

that's work ty

vale wing
#

I think

sick birch
lofty tinsel
#

and if the Dish is missing how Can i send a error message?

sick birch
#

O(1) is the best you can get

vale wing
lofty tinsel
#

Yes when i write pastas

sick birch
#

When writing algorithms, you always want to get as close as you can to O(1) even if that's not always possible

lofty tinsel
slate swan
#

well

#

!e

r = {"p" : "0"}
print(r["P"])```
unkempt canyonBOT
#

@slate swan :x: Your eval job has completed with return code 1.

001 | Traceback (most recent call last):
002 |   File "<string>", line 2, in <module>
003 | KeyError: 'P'
vale wing
#

Typically this term is used in sorting algs

slate swan
#

the get method returns None if the key isnt in the dictionary

hushed galleon
slate swan
#

Is .lower() gonna work fine for the dish arg?

sick birch
#

Sure

#

Well

#

It depends on how you implement it

lofty tinsel
sick birch
#

It just so happens that hash maps have O(1) so if you used hashmaps within your own __contains__ override you can get O(1) lookup time complexities with your own datastructures

lament mesa
#

set.contains is O(1)

slate swan
#

!e

def command():
  dishes = {"pasta": "water, uwu", "fries": "potatoes"}
  _res = dishes.get("uwu")
  if not _res:
     return "no dish"
  return _res
print(command())
unkempt canyonBOT
#

@slate swan :white_check_mark: Your eval job has completed with return code 0.

no dish
lofty tinsel
#

Yes

dull terrace
#

another day of coding less go eyesintensify

#

hows everyones bots coming along?

vale wing
#

@lofty tinsel I made a closest matching item searching alg 😏

sick birch
lofty tinsel
sick birch
#

It happens

lament mesa
vale wing
#

!e ```py
from typing import Sequence

def get_closest_item(seq: Sequence[str], item: str) -> str:
best_entry = (0, None)
sample_letters = set(item.lower())
for s in seq:
letters = set(s.lower())
n = len(sample_letters & letters)
if n > best_entry[0]:
best_entry = (n, s)

return best_entry

stuff = ["cheese", "bobux", "another stuff"]
print(get_closest_item(stuff, "chees"), get_closest_item(stuff, "bux"))```

unkempt canyonBOT
#

@vale wing :white_check_mark: Your eval job has completed with return code 0.

(4, 'cheese') (3, 'bobux')
dull terrace
#

i don't understand, there are so many options froggy_chill

lofty tinsel
#

The question is if the Dish is missing how Can i Send the same erreur message "Hi WE dont have this Dish"

vale wing
dull terrace
#

hmm everything, my first bot was for artists, there's a huge gap there where no one has made anything @slate swan

#

or anything good

lofty tinsel
#

nah beacque when i wirte >recipe it send an error message in vscode

#

Not in discord

sick birch
#

is it linear? logarithmic?

#

I think you meant it to be linear

slate swan
#

you dont even need to use .keys tbh

vale wing
#

O(amount_of_operations) I am talking about alg complexity not the time

lofty tinsel
#

The error message is telling Dish is a required arg that is missing

sick birch
#

I'm not one for algs myself

lofty tinsel
#

Ahhh Okay

vale wing
slate swan
#

well, its inefficient still 🤷‍♂️

sick birch
#

Oh that's linear!

#

That's great :D

vale wing
#

It would be better to compare order as well but um it would be bigger

sick birch
#

Fair point

#

Not much sense in haggling over minute time complexity details in an I/O application

slate swan
#

lol

vale wing
#

Does anyone know a great source of spam messages samples

pliant gulch
#

The time difference is neglible though

vale wing
# slate swan wdym

I am training an AI model for a hot antispam bot and I need samples of spam messages

vale wing
#

I got 1200 records of spam and non spam so far

lofty tinsel
#
@client.command()
async def recipe(ctx, dish):
    dishes = {"pasta":"water, salt", "fries":" potatoes"}

    if not dish in dishes.keys():
        discord.Embed(title = "Error", description = "Please specify a dish")
        await ctx.send(embed = discord.Embed)
        return
#

im trying to send as an embed

vale wing
#

Vise versa if condition

lofty tinsel
#

but there IS an error

#

what IS wrong?

vale wing
#
if not dish in dishes.keys()```
slate swan
#

I am using a function self.disable_all_buttons() in my view class, to disable a button after it is clicked. How can I disable a button in my command function, without it being clicked? I use msg.edit(view=self) afterwards but my code just stops at self.disable_all_buttons()

lofty tinsel
#

Ah

lofty tinsel
unkempt canyonBOT
#

Objects/dictobject.c lines 4735 to 4741

static int
dictkeys_contains(_PyDictViewObject *dv, PyObject *obj)
{
    if (dv->dv_dict == NULL)
        return 0;
    return PyDict_Contains((PyObject *)dv->dv_dict, obj);
}```
hoary cargo
vale wing
#

I made a closest matching string search alg but nobody would use it lmao

#

It has some cons ofc but it has more functionality compared to that thing

#

Maybe not a thing they need

lofty tinsel
vale wing
#

Anyways forget that

lofty tinsel
#

i have this error

vale wing
#

Put the embed into the variable

lofty tinsel
#

when i write >recipe pastas

vale wing
#

And "send the variable"

#
embed = discord.Embed(...)
await ctx.send(embed=embed)```
#

You can skip the variable as well and put the instance straight into params do as you like

lofty tinsel
#

here?

vale wing
#

discord.Embed itself is a class

#

You need an instance of class

#

Which is discord.Embed(...)

#

OOP 👍

lofty tinsel
#

i do after return?

vale wing
#

Nah you put class not an instance

lofty tinsel
#

how?

vale wing
#

Your instance is right above but you do nothing to it

#

You need to put that into a variable

slate swan
#

why not use the get method on the dictionary rather than looping through it 😔

#

I am using a function self.disable_all_buttons() in my view class, to disable a button after it is clicked. How can I disable a button in my command function, without it being clicked? I use msg.edit(view=self) afterwards but my code just stops at self.disable_all_buttons()

vale wing
#

How does your disable_all_buttons look like

slate swan
#

def disable_all_buttons(self):
for button in self.children:
button.disabled = True

slate swan
#

But not my command class

vale wing
#

Ok full code from view creation to msg.edit please

slate swan
#

That is the entire file

#

Lmk when you see it so I can delete😅

formal basin
#

Please help me what do I put instead of this

formal basin
vale wing
#

@slate swan I didn't see that you are editing message after disabling buttons

slate swan
#

and what is that structure

#

of getting data

slate swan
vale wing
formal basin
#

But idk if I did it right

slate swan
vale wing
#
channel = bot.get_channel(int(data_record))```
#

If it's not int already

#

Idk your json

slate swan
#
channel = (bot.get_guild(data['channel_id']) or await bot.fetch_channel(data['channel_id']))
#

I mean, its still a good idea to do that but okay

vale wing
#

@slate swan oh wait I spotted an error

formal basin
#

channel = (bot.get_guild(data['channel_id'])

vale wing
#

You can't do inter.message.edit I think

#

Anyways need to check docs

lofty tinsel
#

Do you know how to leave a blank in an embed. When you have to choose the name of the field, you can't leave it empty. Is there a way to do it or not?

vale wing
#

!d disnake.InteractionMessage.edit

unkempt canyonBOT
#

await edit(content=..., embed=..., embeds=..., file=..., files=..., attachments=..., view=..., components=..., allowed_mentions=None)```
This function is a [*coroutine*](https://docs.python.org/3/library/asyncio-task.html#coroutine).

Edits the message.

Note

If the original message has embeds with images that were created from local files (using the `file` parameter with [`Embed.set_image()`](https://docs.disnake.dev/en/latest/api.html#disnake.Embed.set_image "disnake.Embed.set_image") or [`Embed.set_thumbnail()`](https://docs.disnake.dev/en/latest/api.html#disnake.Embed.set_thumbnail "disnake.Embed.set_thumbnail")), those images will be removed if the message’s attachments are edited in any way (i.e. by setting `file`/`files`/`attachments`, or adding an embed with local files).
pulsar thunder
#

Can I send screenshots here?

vale wing
#

Well you can k

slate swan
slate swan
pulsar thunder
#

The bot replies only when I type hello

slate swan
#

why do you have two run methods

pulsar thunder
#

If I type anything else with hello no rep,y

lofty tinsel
vale wing
#

@slate swan do you have an error handler

slate swan
vale wing
#

Oh yeah you do

slate swan
vale wing
#

One sec

formal basin
#

Don’t think that works

pulsar thunder
slate swan
#

Sorry for the ping crash if you see this

vale wing
#

@slate swan change all the ifs after the first to elifs because many of ifs make no sense and add

else:
    raise error```
At the end so it doesn't eat your errors
slate swan
pulsar thunder
#

Will it work? If it does I am the biggest idiot on this earth

formal basin
slate swan
#

Oh never mind I can change that to elif

slate swan
#

you dont even need the outer parenthesis tbh

pulsar thunder
slate swan
#

you can use the lower method on the string

pulsar thunder
#

Why didn't it work when I used vwriable

#

Also the lists yeah it was an attempt I removed those commands

slate swan
#

wdym?

pulsar thunder
#

Oh my gooood it works

#

I asked in another server they just told me to learn more about the language and then ask questions

slate swan
#

I mean, thats the first thing that comes to my mind

pulsar thunder
#

Tcd

slate swan
#

well

pulsar thunder
#

The coding den

#

If u excuse me imma go flex on them later

#

Also why did user_message not work?

#

So doest it mean I can remove the command line where I declare it too?

formal basin
#

What do I do here

vale wing
#

How does your data look like @formal basin

slate swan
cloud dawn
#

ashley

#

could you help me out rq

vale wing
#

Use bot.get_channel why are you getting the guild

pulsar thunder
# slate swan wdym

I replaced message.content with user_message it didn't work in the if statement

uncut comet
#

hey does anyone know how a bump reminder can be coded due to the new /commands?

#

but how can i see if they bump? do i just wait for a message from the bot? cause on_message doesn't pickup commands to other bots

#

like how could i see if there was a bump command runned?

slate swan
#

if you are adding it

uncut comet
#

sorry what?

slate swan
uncut comet
#

but i thought my bot cant see any slash commands i run to other bots

stuck oyster
#

hey are you busy?

uncut comet
#

from what i tested stuff like on_message isn't triggered if i run a slash command to a different bot

stuck oyster
#

alright

uncut comet
#

thats why i came here asking if anyone knew anything about it

slate swan
#

@vale wing it says CrashCommand object has no attribute disable_all_buttons. I think it is because I use self.disable_all_buttons, how else am I supposed to call it?

#

disable_all_buttons() by itself doesn’t work

uncut comet
#

okay thanks for your suggestions ill look into it, enjoy your movie

slate swan
#

dude

#

commands by events?

#

oh well nvm, they can be but would be a bad practice

lofty pecan
#

Hey guys, so I made a discord bot but the commands only work for me and not other people, the bot is currently on my pc

maiden fable
slate swan
#

oh lol

valid snow
#

I am looking to make a command that gives the origin of the first name using the length of the first name and the first letter. I have this list:
Lxxxxxx = France
Pxxxxxx = Norway
Cxxxxxx = Italia
Vxxxxxx = Deutshland
Yxxxxxx = Morroco
Jxxxxxx = Algeria
Kxxxxx = USA

And in fact when the person will want to know the origin of his name he will do >origin Laurent and the bot will reply "France" because the name start with L and the lenght is 7 letters

slate swan
stuck oyster
#

Well my question is about the code you help me with recently, is it possible for the bot to update the count for one channel name?
lets say channel is renamed #bug-done
it will update for Bug only
Bug - 1

lofty pecan
# slate swan do you have an on_message event?
@bot.command()
async def Info(ctx, oc: str, database: str):
    id = str(ctx.guild.id)
    os.chdir(id)
    with open(f'{database}.json') as file:
        Content = json.load(file)  
    try:
        character = Content[oc]
    except KeyError:
        await ctx.send(f'No character named {oc}')
        return

    character = Content[oc]
    age = character['age']
    gender = character['gender']
    hex = character['hex']
    Url = character['picture']
    desc = character['description']
    universe = character['universe']

    embed = discord.Embed(title=oc, color=int(hex,0), description=desc, mp=datetime.datetime.utcfromtimestamp(1649356775))
    embed.set_thumbnail(url=Url)
    embed.add_field(name="Age", value=age)
    embed.add_field(name="Gender", value=gender)
    embed.add_field(name="Universe", value=universe)

    await ctx.send(embed=embed)```
slate swan
#

database.json again

lofty pecan
slate swan
lofty pecan
#

it's a command

stuck oyster
#
@client.event
async def on_guild_channel_update(before, after):
  if isinstance(after, discord.TextChannel):
    if after.name in ["bug-done", "bat-done"]:
      data = {"count": 0}

      data["count"] += 1

      channel = client.get_channel(955113139576385576)
      embed = discord.Embed(
        title="MM Tracking",
        description=f"**__Middleman__**\n Bug - {data['count']}\n Batt - {data['count]}"
      )

      await channel.send(embed=embed)```
Is it possible that when the bot detects the channel name being renamed to `#bug-done` it will update for Bug only
#

yes

#

yes

#

I am working on that

slate swan
#

I mean, it works🤷‍♂️

#

Does it not?

lofty pecan
#

My command works fine for me

slate swan
#

I mean, not only can your data get corrupt, it’s insecure!!

lofty pecan
#

not others and it raises the error that file is inexistent

stuck oyster
#

So how would I do that

lofty pecan
stuck oyster
#

yes I am doing that right now

uncut comet
formal basin
#

I have a problem

maiden fable
#

And manually compares the embed content

uncut comet
#

that has been removed

uncut comet
hoary cargo
#

in the pic it's pretty visible it has been used a slash command

#

disboard is removing the prefix commands too

cold sonnet
#

he shouldn't be the only person that bumps

hoary cargo
#

well said had

cold sonnet
#

he would've needed to tell everyone

lofty pecan
uncut comet
#

im just wondering how they find out who triggered the bump?

lofty pecan
#

Would anyone know why

lofty pecan
cold sonnet
#

a what

cerulean rampart
#

Hi guys!
I need help on using Google sheets Api's on a bot discord !
I'm stuck at this step on the console
"Please visit this URL to authorize this application: ..............."

cold sonnet
#

our jobn't

uncut comet
cold sonnet
#

or how does that work

lofty pecan
#

I see it works for me only because the bot doesn't answer and in the terminal it gives me an error

#

and it works fine when I run the command

uncut comet
lofty pecan
cerulean rampart
#

@lofty pecan Oh a french guy

lofty pecan
#

yeah

dull terrace
#

This is a big ask, but does anyone have stats on the amount of active daily users for a bot as big as owobot or similar game type ones

lofty pecan
#

it's not about permission so i'm very confused

cerulean rampart
#

Can't find this file @slate swan

#

@slate swan I'm french so I can translate lol

lofty pecan
#

there is no error about that

hoary cargo
lofty pecan
#

I told you, it works fine for me, but when someone else uses it it breaks the bot

dull terrace
#

i'm doing stats on game play for my bot and if each person spends 5 mins per session before they run out of energy and have to wait that means roughly 14k+ play sessions per day before discord craps out

lofty pecan
#

yup, as if the bot ran by someone else couldn't reach the folder

#

yup

dull terrace
#

so how long can i make the play sessions froggy_chill

cerulean rampart
dull terrace
#

if i make the play sessions 10mins each then that's 7k sessions and if the average is 2 sessions per person per day it means it can only handle 3.5k players

#

hard to find where to balance it

lofty pecan
#

so that comes from here

#

I set the working directory with chdir

formal basin
#

Everytime it dumps somthing it deletes the other dump above it

dull terrace
#

hmm i just realised top.gg votes will correlate with active daily users

lofty pecan
#

maybe when someone else uses the command I have to add the total path ? because when I'm in VS code the folder is set to the correct one

formal basin
slate swan
#

oh wait, it should

formal basin
dull terrace
#

25k votes a day for owo bot froggy_chill

slate swan
formal basin
#

What object

#

And which file?

#

That?

dull terrace
#

does sharding increase the rate limit above 50 per second for discord?

formal basin
#

Why does it delete the other dump

#

@slate swan

lofty pecan
dull terrace
#

ahh i see they offer higher rate limits if your bot gets that high

#

so i don't need to think about it so much

valid snow
#

I am looking to make a command that gives the origin of the first name using the length of the first name and the first letter. I have this list:
Lxxxxxx = France
Pxxxxxx = Norway
Cxxxxxx = Italia
Vxxxxxx = Deutshland
Yxxxxxx = Morroco
Jxxxxxx = Algeria
Kxxxxx = USA

And in fact when the person will want to know the origin of his name he will do >origin Laurent and the bot will reply "France" because the name start with L and the lenght is 7 letters

stuck oyster
#
    batt_done = int(data("batt-count"))
    bug_done = int(data["bug-count"])
    
    if after.name.startswith("bug"):
      bug_done +=1
      embed.description=f"Bug - {bug_done}\n batt - {batt_done}"```
slate swan
# formal basin Why does it delete the other dump

because you are resetting the dictionary by dumping data into the same dictionary

dump({"key": "value"}, f) #this will set the json file to the following |
                                                                        |
'''json file'''                                                         |
{"old_key": "old_value"} = {"key": "value"} <----------------------------

'''WHAT YOU ACTUALLY NEED TO DO'''
{"old_key": "old_value"} = {"old_key", "old_value"}, {"new_key": "new_value"}
                                                                      ^
'''HOW YOU CAN DO IT'''                                               |
data = load(file_path)                                                |
data[str(guild.id)] = {}                                              |
data[str(guild.id)]["channel_name"] = channel.name                    |
data[str(guild.id)]["channel_id"] = channel.id                        |
                                                                      |
dump(data, f) #this will create this ---------------------------------|

'''HOW YOU CAN ACCESS THE channel_id KEY FROM THE JSON FILE'''
data = load(file_path)
welcome_channel = data[str(guild.id)]['channel_id'] #returns the integer id of the channel, you can now use this to get/fetch channels
#

sorry for the amount of time I took

formal basin
slate swan
#

ill cry if you didnt understand 😭

slate swan
#

channel.fetch_message(id) doesnt work with discord.py version one, what is the thing for that?

slate swan
#

since its a coroutine

#

I awaited it

#

!d discord.TextChannel.fetch_message

unkempt canyonBOT
#

await fetch_message(id, /)```
This function is a [*coroutine*](https://docs.python.org/3/library/asyncio-task.html#coroutine).

Retrieves a single [`Message`](https://discordpy.readthedocs.io/en/master/api.html#discord.Message "discord.Message") from the destination.
slate swan
#

or the message simply doesnt exist

#

or the command is run in another channel

#

it says this ```C:\Users\Administrator\Desktop\detection bot>python index.py
Bot is ready!
Ignoring exception in command queue:
Traceback (most recent call last):
File "C:\Python39\lib\site-packages\discord\ext\commands\core.py", line 85, in wrapped
ret = await coro(*args, **kwargs)
File "C:\Users\Administrator\Desktop\detection bot\index.py", line 181, in queue
message = await chnl.fetch_message(queue_message)
AttributeError: 'NoneType' object has no attribute 'fetch_message'

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "C:\Python39\lib\site-packages\discord\ext\commands\bot.py", line 939, in invoke
await ctx.command.invoke(ctx)
File "C:\Python39\lib\site-packages\discord\ext\commands\core.py", line 863, in invoke
await injected(*ctx.args, **ctx.kwargs)
File "C:\Python39\lib\site-packages\discord\ext\commands\core.py", line 94, in wrapped
raise CommandInvokeError(exc) from exc
discord.ext.commands.errors.CommandInvokeError: Command raised an exception: AttributeError: 'NoneType' object has no attribute 'fetch_message'```

formal basin
formal basin
slate swan
# formal basin

dont use that code, use what i sent in the next message, I realized that the previous one was wrong and re-wrote it

formal basin
#

Oh

formal basin
slate swan
formal basin
#

Actually I might

slate swan
formal basin
#

Ok

quaint epoch
#

chnl is NOT a channel object, you probably didn't fetch/get it properly, so it is a NoneType.

slate swan
# formal basin Ok

and ofc if you hadnt been using json and a proper database, it wouldnt have been an issue

broken axle
#

how to make an discord bot (almost all in one) using python?

i want to make a bot & want to know the learning process.

pallid meadow
broken axle
#

I've OOP knowledge but no asyncio

formal basin
#

I did what you said

pallid meadow
#

Here lemme try to find a video

slate swan
pallid meadow
slate swan
pallid meadow
#

@broken axle https://youtu.be/t5Bo1Je9EmE here’s a vid that can help you understand those basic concepts

In today's video, I'll be talking to you about asynchronous programming in python. This Python Async tutorial will cover the 'async' and 'await' keyword, coroutines, futures and tasks, and some basic features from the asyncio module in Python. This video is for intermediate programmers, and it's recommended you have Python 3.7 or above.

💻 Algo...

▶ Play video
broken axle
pallid meadow
#

Yeah, well I can give you a library suggestion for when you are ready to make a bot would you like that?

formal basin
formal basin
#

Why is it deleting the dump

pallid meadow
slate swan
#

both didnt work out with ya

#

nor are you trying

#

what I did and you did are totally different

formal basin
#

Hold up I think I understand

slate swan
#

thats what you said 5 minutes prior

formal basin
slate swan
#

💀

#

I-

slate swan
#

😂

#

why u deleted ittt

#

:'/ i ws reading that :/

#

deleted what?

#

lmao

formal basin
#

Bruh

slate swan
#

:'/

formal basin
#

All I need to do is stop deleting the dumps that’s all

slate swan
#

I feel like jumping out of the window now

formal basin
#

Where do I put them

slate swan
#

😭

slate swan
#

😂 i'm literally feeling like laughing lmfao

slate swan
#

:>

slate swan
slate swan
#

overall thing is

#

i need to get better

#

he's tryna use json as db... and we all know.. tryna use json as db is a fucked up decision :")

slow fog
#

Ashley

slate swan
slate swan
#

:'/

slate swan
#

lmao

slow fog
hoary cargo
#

who's sussy

slate swan
#

right

#

sussy baka

slow fog
#

wts

#

wts means what the sus

hoary cargo
slate swan
#

eren hmm

#

hmm

#

he's gonna die anyways, so who cares

#

lol xD

#

😭 bro, that's a secret.. world shouldn't know that

#

u revealed.. u betrayed us

#

:'/ now we gonna kick u out of the cult

#

and that exclamation mark made it all worse

#

😂

slate swan
#

:'/

#

bro, python file itself is the best db.. what do ya think? 😏

#

csv files got left out 😔

#

😭 ** ** uff sed

slow fog
#

true

slate swan
#

just dont use a db, change my mind

#

💀

#

LMFAOO

#

lmaooooo, good one

#

wait....imagine flipping through pages to find a specific record, awesome

#

💀 i'm gonna die doing tht

slate swan
#

oh :'/

glacial echo
#

how do i host a bit on a raspberry pi

#

but like do i just run the python file form terminal

#

do i have to install my modules

slate swan
#

obviously :")

glacial echo
#

k

slate swan
#

imagine hosting bots

#

and paying for making them

cold sonnet
#

paying for making them?

#

I acc should try hosting my bot on a cmd for some time

#

so I check how much RAM it takes

#

cuz my raspberry pi ain't enjoying this

formal basin
#

@slate swan

#

That’s my only error

junior verge
#

How do I fix this lol

formal basin
slate swan
#

oomg ppl

#

pls stop using json as db (just a suggestion, rest is ur choice)

#

:'/

formal basin
#

And what is that

stuck oyster
slate swan
formal basin
#

How do I check

slate swan
#

and as for db.. u can spend some time learning sql.. once u learn it a bit.. u can easily play around mysql or postgresql shit

formal basin
#

Where do I look

slate swan
#

alright sir :'/

formal basin
#

And I’m pretty sure it’s welcome_file

livid jacinth
#

Hey, how do i get all bot on the discord server?

slate swan
formal basin
#

@bot.command()
@commands.has_permissions(manage_roles=True)
async def welcome_setup(ctx, channel: discord.TextChannel):

  data = json.load(welcome_file)
  data[str(ctx.guild.id)] = {}
  data[str(ctx.guild.id)]['channel_name'] = channel.name
  data[str(ctx.guild.id)]['channel_id'] = channel.id
  
  
  
  

  with open('welcome.json', 'w') as f:
    json.dump(data, f)
  await ctx.send("welcome channel setup")

@bot.event
async def on_member_join(member):

  with open('welcome.json') as welcome_file:
        data = json.load(welcome_file)
        channel = data[str(member.guild.id)]['channel_id']

        await channel.send(f"{member.name} has joined the server")

junior verge
#

ye just trying it out haha

slate swan
formal basin
slate swan
#

?

#

!d discord.Embed.copy is a thing?

unkempt canyonBOT
slate swan
#

?

#

th

#

lol

#

😂 alr

#

why, how, when

slate swan
formal basin
#

What do I put inside

quaint epoch
#

!d disnake.TextChannel.fetch_message

unkempt canyonBOT
#

await fetch_message(id, /)```
This function is a [*coroutine*](https://docs.python.org/3/library/asyncio-task.html#coroutine).

Retrieves a single [`Message`](https://docs.disnake.dev/en/latest/api.html#disnake.Message "disnake.Message") from the destination.
formal basin
#

I can’t see an object

slate swan
quaint epoch
slate swan
slate swan
#

lmfao

quaint epoch
#

!d disnake.Embed.edit_field

slate swan
#

😂

quaint epoch
#

huh

stuck oyster
#

Could I make a command that sends the embed then fetch the message?

slate swan
#

that's why embed.copy() is there ig

#

:")

formal basin
#

@bot.command()
@commands.has_permissions(manage_roles=True)
async def welcome_setup(ctx, channel: discord.TextChannel):

  data = json.load(welcome_file)
  data[str(ctx.guild.id)] = {}
  data[str(ctx.guild.id)]['channel_name'] = channel.name
  data[str(ctx.guild.id)]['channel_id'] = channel.id
  
  
  
  

  with open('welcome.json', 'w') as f:
    json.dump(data, f)
  await ctx.send("welcome channel setup")

@bot.event
async def on_member_join(member):

  with open('welcome.json') as welcome_file:
        data = json.load(welcome_file)
        channel = data[str(member.guild.id)]['channel_id']

        await channel.send(f"{member.name} has joined the server")

quaint epoch
unkempt canyonBOT
#

class discord.Embed(*, colour=None, color=None, title=None, type='rich', url=None, description=None, timestamp=None)```
Represents a Discord embed.

len(x) Returns the total size of the embed. Useful for checking if it’s within the 6000 character limit.

bool(b) Returns whether the embed has any data set.

New in version 2.0.

For ease of use, all parameters that expect a [`str`](https://docs.python.org/3/library/stdtypes.html#str "(in Python v3.10)") are implicitly casted to [`str`](https://docs.python.org/3/library/stdtypes.html#str "(in Python v3.10)") for you.

Changed in version 2.0: `Embed.Empty` has been removed in favour of `None`.
quaint epoch
#

oh, here's a question

slate swan
unkempt canyonBOT
#

set_field_at(index, *, name, value, inline=True)```
Modifies a field to the embed object.

The index must point to a valid pre-existing field.

This function returns the class instance to allow for fluent-style chaining.
#

remove_field(index)```
Removes a field at a specified index.

If the index is invalid or out of bounds then the error is silently swallowed.

Note

When deleting a field by index, the index of the other fields shift to fill the gap just like a regular list.
quaint epoch
#

if you pass in color AND colour, which one overrides what? and which takes priority?

#

🤔

slate swan
slate swan
quaint epoch
quaint epoch
slate swan
quaint epoch
slate swan
formal basin
#

@bot.command()
@commands.has_permissions(manage_roles=True)
async def welcome_setup(ctx, channel: discord.TextChannel):

  data = json.load(welcome_file)
  data[str(ctx.guild.id)] = {}
  data[str(ctx.guild.id)]['channel_name'] = channel.name
  data[str(ctx.guild.id)]['channel_id'] = channel.id
  
  
  
  

  with open('welcome.json', 'w') as f:
    json.dump(data, f)
  await ctx.send("welcome channel setup")

@bot.event
async def on_member_join(member):

  with open('welcome.json') as welcome_file:
        data = json.load(welcome_file)
        channel = data[str(member.guild.id)]['channel_id']

        await channel.send(f"{member.name} has joined the server")

quaint epoch
slate swan
#

💀 no idk about it

slate swan
quaint epoch
#

wow hunter was right where did your humor go?

unkempt canyonBOT
#

discord/embeds.py line 168

self.colour = colour if colour is not None else color```
slate swan
#

still not sure

quaint epoch
slate swan
cold sonnet
#

it's gonna be colour

slate swan
formal basin
#

Ok

final iron
cold sonnet
#

I wonder why you save every id as an str

quaint epoch
quaint epoch
#

And my fame for making things a bit more humorous?

#

I'll tickle your bones, to the tibia toes, unless your my bro jokes flow over his head.

unkempt canyonBOT
#

discord/embeds.py line 168

self.colour = colour if colour is not None else color```
quaint epoch
#

huh wow i do remember the lyrics

cold sonnet
#

it's only gonna be color if colour is None

slate swan
quaint epoch
cold sonnet
#

order of kwargs also doesn't change anything, it's not how python works

cold sonnet
#

😿

slate swan
#

:'/

quaint epoch
#

is this question going to remain forever unsolved?

cold sonnet
#

what question

slate swan
#

💀 which question?

quaint epoch
slate swan
cold sonnet
#

BRO

quaint epoch
cold sonnet
#

I sent it two times

unkempt canyonBOT
#

discord/embeds.py line 168

self.colour = colour if colour is not None else color```
quaint epoch
#

i thought it read color takes priority

slate swan
#

in the end, if you have got common sense, use just one of them

quaint epoch
#

so technically, using colour is very slightly faster

cold sonnet
#

okay but curiosity

slate swan
#

💀 bruhh

slate swan
#

color.. only 5 letters.. so.. :> (my lazy ass)

#

...

cold sonnet
#

that's long term memory

quaint epoch
#

so which is faster, color or colour

slate swan
#

bruhh wtff

#

LFMAOOO

quaint epoch
#

colour would be faster in terms of ram ig

slate swan
#

😂

quaint epoch
#

but color would save long term memory

#

🤔

slate swan
#

😂 omg wtf

quaint epoch
cold sonnet
quaint epoch
#

if im not memorizing morse code im here creating pandemonium, it's kinda my whole thing

quaint epoch
cold sonnet
#

so what

quaint epoch
#

which would be a lot more, because to see bits you would need a font

#

and since a font has usually more than just 0 and 1

#

it would take a lot more memory

#

checkmate

formal basin
#

It doesn’t work

cold sonnet
#

I struggle to understand your logic but sure

slate swan
cold sonnet
#

WHAT

quaint epoch
#

DAMN

slate swan
#

i swa that message

cold sonnet
#

that was a self checkmate

slate swan
#

I SAW THATATT

quaint epoch
#

shhh

#

i made a typo

cold sonnet
#

you aren't getting away with that

formal basin
quaint epoch
slate swan
#

💀 idk from where u got it.. ubt looks like i've seen it somewhere

quaint epoch
#

nothing

cold sonnet
#

corrected your to you're

slate swan
#

horrible frrr

quaint epoch
cold sonnet
#

I've seen that before

quaint epoch
#

frick bro

#

who wrote this and what is their address?

#

128 stars? that's base 2

#

fuck

formal basin
stuck oyster
#
line 531, in _run_event
    await coro(*args, **kwargs)
line 30, in on_guild_channel_update
    message = await after.fetch_message(962066408768958505)
line 1581, in fetch_message
    data = await self._state.http.get_message(channel.id, id)
line 416, in request
    raise NotFound(response, data)
disnake.errors.NotFound: 404 Not Found (error code: 10008): Unknown Message```
quaint epoch
#

bro do you not have a life?

quaint epoch
slate swan
#

💀

quaint epoch
#

can we put cursed code behind and help this poor sod?

slate swan
#

💀 me too

quaint epoch
#

it says, the message doesn't exist

#

and we can't help with that

stuck oyster
quaint epoch
formal basin
#

Someone

quaint epoch
formal basin
#

I just need help

quaint epoch
#

the error is on line 290, and you shared line 450?

slate swan
cold sonnet
quaint epoch
slate swan
formal basin
quaint epoch
slate swan
quaint epoch
#

that isn't an error

slate swan
#

:'/

quaint epoch
#

that's just a line

cold sonnet
#

colour saves you a condition

slate swan
# formal basin Help

im so annoyed now, it had to be done like this

with open('welcome.json') as f: data = json.load(f)```
cold sonnet
quaint epoch
#

bro just ask how to use json.load

#

don't circle a line and ask for help