#discord-bots

1 messages · Page 706 of 1

visual island
#

you

slate swan
#

and wut

#

oh zero two

#

yes

visual island
#

zero

#

yeah

slate swan
#

zero is the best waifu ofc

visual island
#

I havent watch darling in the franxx :(

slate swan
visual island
#

idk, i feel like there are more funner animes

slate swan
#

more like romantic

#

she risked her life for her bf something a girl would never do with me😔

visual island
#

best genre 👍

visual island
slate swan
slate swan
visual island
slate swan
#

watch bro

visual island
#

waiting..

slate swan
#

mobile isnt ez ok

#

will i ever get a gf?

#

!e

import random
a = ("yes","no")
print(random.choice(a))
unkempt canyonBOT
#

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

no
slate swan
#

😔

visual island
#

lmaoooo

slate swan
#

grumpchib 😔

rain olive
slate swan
#

pain😞

visual island
#

will okimii ever get a gf?

#

!e
import random
a = ("yes","no")
print(random.choice(a))

unkempt canyonBOT
#

@visual island :white_check_mark: Your eval job has completed with return code 0.

yes
visual island
#

see

slate swan
#

i saw what you did

visual island
#

no one saw

slate swan
#

will icy ever get a gf?

#

!e

import random
a = ("yes","no")
print(random.choice(a))
unkempt canyonBOT
#

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

yes
visual island
slate swan
#

fuck😔

#

guess ill stick with zero two🚶 😔

visual island
#

should i watch darling in the franxx?

#

!e
import random
a = ("yes","no")
print(random.choice(a))

unkempt canyonBOT
#

@visual island :white_check_mark: Your eval job has completed with return code 0.

yes
slate swan
#

see he never lies

pliant gulch
#

!e ```py
import random; print(random.choices(("Yes", "No"), weights=(0, 100)))

slate swan
#

🕴️

unkempt canyonBOT
#

@pliant gulch :white_check_mark: Your eval job has completed with return code 0.

['No']
pliant gulch
#

😔

visual island
slate swan
visual island
#

there are plenty of single anime girls though

slate swan
visual island
#

whos akeno..

slate swan
#

wtf do you watch

slate swan
visual island
#

..

slate swan
strong vessel
#

is discord client id a secret or can it be shraed publicly?

slate swan
#

;)

strong vessel
#

i'm really new to discord bots

#

as in the discord bot client id

pliant gulch
#

Client ID is public

strong vessel
#

thanks

pliant gulch
#

Its the same thing as your own account's ID

strong vessel
#

so it is ok to share the client id to other people?

pliant gulch
#

Yes

strong vessel
#

thanks!

visual island
pliant gulch
#

You share it in invites after all as well

slate swan
strong vessel
slate swan
#

i watched it because of the story ok🕴️

visual island
slate swan
#

can you blame me tho?😤

visual island
slate swan
visual island
#

wait, you're legal?

slate swan
visual island
#

old enough to watch kid series?

#

gotcha

boreal ravine
#

!ot

unkempt canyonBOT
slate swan
visual island
#

..

slate swan
#

alr ima watch some cocomelon

pulsar shell
slate swan
#

can someone help me create a reputation system?

boreal ravine
slate swan
boreal ravine
pulsar shell
slate swan
#

I already tried to create but it didn't work so I deleted it and got angry today I'm trying to do it again

boreal ravine
#

but why do you need help?

slate swan
#

I wanted to put it on my bot

boreal ravine
#

cool

#

but whats the issue lol

slate swan
#

I don't know how to handle database

boreal ravine
slate swan
#

I just wanted to create a reputation system ;-;

#

But I don't know where I learn, I've already searched the internet

slate swan
#

Exactly I've already searched and haven't found

boreal ravine
#

ok so what database do you wanna use though

slate swan
#

Which ones are there?

slate swan
#

Ooo

#

from kayle btw

#

he showed me it

#

Then I'll learn how to create a database for my bot?

#

In this link

boreal ravine
slate swan
slate swan
#

I use replit is there any interference in this?

#

no json

boreal ravine
slate swan
#

Because I saw it here, it has a database

#

Can I use it?

#

Or will it work? haha

boreal ravine
#

and I don't think its asynchronous to be used with dpy

pliant gulch
#

Basically, you set the bots interaction endpoint and it does this

sick birch
#

i really wouldn't recommend you use replit's db

pliant gulch
visual island
pliant gulch
#

But I don't recommend as it is NO where near finished

slate swan
#

So can I use another base date outside?

pliant gulch
#

Matter of fact, just scratch what I said okimii cause I'm gonna delete that file in the repo

slate swan
#

and andy why did you scrolled so much🕴️ pithink

boreal ravine
slate swan
#

I'm using the translator haha

boreal ravine
#

mongodb is always an option

boreal ravine
slate swan
#

Ok

visual island
#

postgresql..

slate swan
#

Ty for help Sorry the inconvenience

boreal ravine
#

ok

manic wing
#

ok
wow, very socially adept

lost wolf
#

how do i make a timer untill christmas? do i use the time package?

visual island
#

no, use tasks.loop and look if datetime.datetime.now() is the expected time

lost wolf
#

i never heard of tasks.loop may i have a example?

lost wolf
#

thanks icy

visual island
#

this is basically just

@tasks.loop(seconds=5)
async def test():
    pass
test.start()
``` `test` will be executed every 5 seconds
lost wolf
#

im kind of still confused tho

visual island
lost wolf
#

like

#

im a beginner and this is my code so far.

#
   @commands.command(aliases['tracksanta'])
    async def santatracker(self, ctx, time):
        tracker = 
        embed = discord.Embed(title="Santa Spotted!", description=f"Santa is {tracker} EST (Eastern Standerd Time) Away!")

visual island
#

ah you're using command

#

!d datetime.datetime

unkempt canyonBOT
#

class datetime.datetime(year, month, day, hour=0, minute=0, second=0, microsecond=0, tzinfo=None, *, fold=0)```
The *year*, *month* and *day* arguments are required. *tzinfo* may be `None`, or an instance of a [`tzinfo`](https://docs.python.org/3/library/datetime.html#datetime.tzinfo "datetime.tzinfo") subclass. The remaining arguments must be integers in the following ranges...
visual island
#

put the date of Christmas there

#

then tracker = datetime.datetime.now() - christmas_time

lost wolf
#

alright

#

thanks icy again!

visual island
#

anytime

tiny ibex
slate swan
#

Yes

tiny ibex
#

Hmm

lost wolf
#
@client.command(aliases=['tracksanta'])
async def santatracker(ctx, time):
    tracker = datetime.datetime(year=2021, month=12, day=25, hour=5, minute=60)
    embed = discord.Embed(title="Santa Spotted!", description=f"Santa is {tracker} EST (Eastern Standerd Time) Away!")
    await ctx.send(embed = embed)
#

@visual island

quick gust
#

is there a problem with it?

lost wolf
#

no just a mis understanding lmao

muted lynx
#

Is there a way to check if a message contains an embed

lost wolf
#

Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-install-nh7_4wkh/dotenv/

slate swan
#

Merry Christmas guys!!!

lost wolf
#

Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-install-nh7_4wkh/dotenv/

#

@visual island i know the problem i just dont know how to solve it.

#

i use "python3" not "python"

upbeat otter
untold token
#

Pycharm isn't "hard", its complex

#

Its a very advanced IDE, and beginners stumble in it a lot

jade tartan
untold token
#

why even copying, when you can just git clone

jade tartan
#

Someone help me plz

vale wing
upbeat otter
# jade tartan

Pip install it again, it always gives this error on first time use, then restart your ide

jade tartan
#

OK how do i install requests pip?

pliant gulch
maiden fable
jade tartan
#

already did but still same error

#

no have not

jade tartan
maiden fable
#

Then install requests

vale wing
#

If you have python added to PATH it should work

#

Otherwise you may add it to path manually but it is kinda difficult compared to reinstalling python with checkmark on

#

What library is good for fast migration to slash commands?

jade tartan
lost wolf
visual island
lost wolf
#

program

visual island
#

how are you running it?

quick gust
#

How do I timeout a button after x seconds? I have subclassed discord.ui.View

vale wing
visual island
unkempt canyonBOT
#

Timeout from last interaction with the UI before no longer accepting input. If None then there is no timeout.

jade tartan
quick gust
#

print(x)

jade tartan
#
Ignoring exception in command weather:
Traceback (most recent call last):
  File "C:\Users\thoma\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\ext\commands\core.py", line 85, in wrapped
    ret = await coro(*args, **kwargs)
  File "c:\Users\thoma\Desktop\discord.py\python\bot.py", line 346, in weather
    y = x["main"]
KeyError: 'main'

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

Traceback (most recent call last):
  File "C:\Users\thoma\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\ext\commands\bot.py", line 939, in invoke
    await ctx.command.invoke(ctx)
  File "C:\Users\thoma\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\ext\commands\core.py", line 863, in invoke
    await injected(*ctx.args, **ctx.kwargs)
  File "C:\Users\thoma\AppData\Local\Programs\Python\Python310\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: KeyError: 'main'
vale wing
#

It depends how does that API receive apikey

#

It may get it from headers or from params

#

Could you give me the link to API docs so I can help you a bit of more with that? @jade tartan

#

Nvm found them

jade tartan
#

Could send it to me?

vale wing
#

What is your base_url?

#

I would suggest to make the request like

r = requests.get(base_url, params={'appid': api_key, 'q': city_name})```
#

But it depends what base_url you have and does it accept params or json

jade tartan
#

Right?

#

Hello

slate swan
#

You don't get the response with a key "main"

shrewd inlet
#

how do i make a welcome message on my bot delete after a second

slate swan
#

send takes a delete_after kwarg

#
await channel.send("something" , delete_after = 10)```
shrewd inlet
#

ty

jade tartan
#

Hello plz

#

Someone

slate swan
#

could you explain what do you mean by check?

brave flint
slate swan
#

for sending files you can use file ( if a single file) or files if they are many

#

Alright

brave flint
#

arl find the solution

jade tartan
slate swan
boreal ravine
#

copied code

vague sundial
#

A part of it, yes

#

anyway works now

boreal ravine
#

no, all of it and i see no error in your code

vague sundial
boreal ravine
#

nice

graceful mulch
#

Command raised an exception: ServerSelectionTimeoutError: localhost:27017: [Errno 111] Connection refused, Timeout: 30s, Topology Description: <TopologyDescription id: 61c6d3224a33439c539198ad, topology_type: Single, servers: [<ServerDescription ('localhost', 27017) server_type: Unknown, rtt: None, error=AutoReconnect('localhost:27017: [Errno 111] Connection refused')>]>

#

I want help in this error

heavy folio
#

how do i archive a thread (using ctx.channel)

graceful mulch
graceful mulch
#

i am making a discord bo

upbeat otter
#

thanku

boreal ravine
#

I think like some forks have it

heavy folio
#

hmm kden

slate swan
unkempt canyonBOT
#

await edit(*, name=..., archived=..., locked=..., invitable=..., slowmode_delay=..., auto_archive_duration=...)```
This function is a [*coroutine*](https://docs.python.org/3/library/asyncio-task.html#coroutine).

Edits the thread.

Editing the thread requires [`Permissions.manage_threads`](https://discordpy.readthedocs.io/en/master/api.html#discord.Permissions.manage_threads "discord.Permissions.manage_threads"). The thread creator can also edit `name`, `archived` or `auto_archive_duration`. Note that if the thread is locked then only those with [`Permissions.manage_threads`](https://discordpy.readthedocs.io/en/master/api.html#discord.Permissions.manage_threads "discord.Permissions.manage_threads") can unarchive a thread.

The thread must be unarchived to be edited.
slate swan
#

It takes a archived kwarg

heavy folio
#

oo

sour lodge
#

Why is sub classing for custom help command better than making like a command for it

shrewd inlet
#

can u have two welcomes?

#

for some reason one of them isn’t working

heavy folio
#

there's also a guide in there so yeah

shrewd inlet
#

can you have more than one welcome bot event?

maiden fable
shrewd inlet
maiden fable
#

!d discord.ext.commands.Bot.listen use this then

unkempt canyonBOT
#

@listen(name=None)```
A decorator that registers another function as an external event listener. Basically this allows you to listen to multiple events from different places e.g. such as [`on_ready()`](https://discordpy.readthedocs.io/en/master/api.html#discord.on_ready "discord.on_ready")

The functions being listened to must be a [coroutine](https://docs.python.org/3/library/asyncio-task.html#coroutine "(in Python v3.9)").

Example...
shrewd inlet
#

the top one isn’t working

maiden fable
#

It won't work cz two functions can't have the same name

shrewd inlet
#

oh

shrewd inlet
maiden fable
#

Instead of event

shrewd inlet
#

so @bot.@listen(name=None) ?

maiden fable
#
@bot.listen("on_member_join")
async def join_one(member):
    . . . 

@bot.listen("on_member_join") 
async def join_two(member):
   . . . 
shrewd inlet
#

ty

slate swan
#

and you will be able to use things like ctx.send_help

sullen shoal
#

for a good help command, not matter how you implement your help command, you will somehow end up with something that does the same thing as the HelpCommand class. so why not use it instead?

silver vale
#

hi

sullen shoal
#

just overrride the methods and use self.context as the "ctx" of the help command

silver vale
#

ctx

upbeat otter
maiden fable
slate swan
#

You can do different things in different functions simpl

upbeat otter
upbeat otter
jagged root
#

how to make the bot send a message when some timeout a member?

jagged root
#

wym

tawdry perch
#

You don't

jagged root
tawdry perch
#

What?

jagged root
#

You know the new update

#

You cab timeout users

#

so how to log it in a channel

slate swan
#

because discord.py is not adding anything updated on discord

#

It's a dead Library

jagged root
#

i use py.

#

F

#

What should i do

upbeat otter
jagged root
upbeat otter
jagged root
#

what should i do

upbeat otter
#

since its development's stopped

jagged root
#

: (

slate swan
#

don't think there's any such event for that
Disnake and pycord don't have any implementations for that

upbeat otter
jagged root
jagged root
slate swan
#

Disnake

jagged root
#

ok

slate swan
#

you will have to more to any other Library in 2-3 months Anyways

upbeat otter
#

move*

jagged root
#

kk

slate swan
#

Yea. Was a typo

upbeat otter
#

Ikr

jagged root
#

how can i move

tawdry perch
#

!d disnake.Member.timeout

unkempt canyonBOT
#

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

Times out the member from the guild; until then, the member will not be able to interact with the guild.

Exactly one of `duration` or `until` must be provided. To remove a timeout, set one of the parameters to `None`.

You must have the [`Permissions.moderate_members`](https://docs.disnake.dev/en/latest/api.html#disnake.Permissions.moderate_members "disnake.Permissions.moderate_members") permission to do this.

New in version 2.3.
jagged root
boreal ravine
#

grammar

jagged root
#

im not english shut up

boreal ravine
#

👌

tawdry perch
boreal ravine
#

not everything

jagged root
#

i will rn

#

hm?

tawdry perch
visual island
#

pip install disnake[shim]

#

or pip install disnake[discord] i forgot

boreal ravine
#

i never really understood why you need to do that in an import

tawdry perch
tawdry perch
jagged root
#

i already replaced discord to disnake, is it done?

boreal ravine
#

I meant why you need to do disnake[shim]

tawdry perch
jagged root
#

i did manually

tawdry perch
jagged root
#

in packages

#

is that good?

tawdry perch
#

If it is installed then it is

boreal ravine
tawdry perch
#

No I don't think so, it's just a feature of lib afaik

jagged root
boreal ravine
#

o

tawdry perch
jagged root
#

kk

#

tysm

tawdry perch
#

Np

sour lodge
#

like will there be any error throughout the written discord.py code if I change it to disnake

slate swan
#

Everything from discord.py V2 is applicable in disnake

sour lodge
#

Alright

#

Also what does it mean by voice support “To install the library without full voice support…”

wanton veldt
#
@client.command()
@commands.has_permissions(ban_members = True)
async def timeout(ctx, member : discord.Member, *, reason = None):
    await member.timeout(reason = reason)
    await ctx.channel.send(f'{member.mention} has been takeing a brake by {ctx.message.author.mention} for reason of: {reason}!')
````AttributeError: 'Member' object has no attribute  'timeout'` any ideas?
quick gust
#

what fork are u using

tawdry perch
#

It's no longer maintained which means it won't get updated

quick gust
#

oh nvm right, there's discord.Member

wanton veldt
#

ok ty

tawdry perch
#

I recommend to use disnake instead

wanton veldt
#

ok ty

jagged root
#

how to log when a user is manually banned

#

to send a message*

tawdry perch
jagged root
#

Guild i guess

tawdry perch
#

!d disnake.on_member_ban

unkempt canyonBOT
#

disnake.on_member_ban(guild, user)```
Called when user gets banned from a [`Guild`](https://docs.disnake.dev/en/latest/api.html#disnake.Guild "disnake.Guild").

This requires [`Intents.bans`](https://docs.disnake.dev/en/latest/api.html#disnake.Intents.bans "disnake.Intents.bans") to be enabled.
jagged root
#

k

leaden hollow
#
@client.command()
@commands.has_permissions(manage_messages=False)
async def purge(ctx):
    await ctx.send(f'No perms')
@commands.has_permissions(manage_messages=True)
async def purge(ctx,amount=1,):
    await ctx.channel.purge(limit=amount+1)

You are missing Manage Messages permission(s) to run this command.

#

I own that server btw

shadow wraith
#

does disnake have timeout support

sour lodge
#

Yes

shadow wraith
#

ok

tawdry perch
unkempt canyonBOT
#

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

Times out the member from the guild; until then, the member will not be able to interact with the guild.

Exactly one of `duration` or `until` must be provided. To remove a timeout, set one of the parameters to `None`.

You must have the [`Permissions.moderate_members`](https://docs.disnake.dev/en/latest/api.html#disnake.Permissions.moderate_members "disnake.Permissions.moderate_members") permission to do this.

New in version 2.3.
slate swan
#
async def get_pre(bot, message) -> str:
    bot.db
    print(message.guild.id)

    return "guild prefix"

intents = discord.Intents.all()
bot = commands.Bot(command_prefix=get_pre, case_insensitive=True, intents=intents)
bot.remove_command("help")


async def create_db_pool():
    bot.db = await asyncpg.create_pool(
        dsn="my cool link"
    )


bot.loop.run_until_complete(create_db_pool())``` would i be able to use the bot.db in the get_pre coro , altho it wasnt defined ![thinkCat](https://cdn.discordapp.com/emojis/882473068881145899.webp?size=128 "thinkCat")
tawdry perch
#

Oh wait now I know

#

You have bot = commands.Bot, u have defined bot after get_pre function

visual island
slate swan
velvet tinsel
#

Merry Christmas y’all

upbeat otter
velvet tinsel
#

It’s Christmas 😭

#

It’s a time for forgiving

upbeat otter
upbeat otter
velvet tinsel
#

yeah

#

anyways

upbeat otter
#

bye?

velvet tinsel
#

hehe discord bots

upbeat otter
#

oof

velvet tinsel
#

what discord bots have you been working on

upbeat otter
#

django supremacy :blobthumbsup:

#

anyways

#

nvm

velvet tinsel
#

Yeah I’ve been doing django as well lol

maiden fable
#

I was just gonna do OT

velvet tinsel
#

Yeah

#

Anyways

#

Bye 👋

maiden fable
velvet tinsel
#

Flexing your nitro, huh

velvet tinsel
#

Alright

#

If you do manage_messages=False why can’t you just remove it?

#

Also

#

You did two has_permissions

#

You can just make an error handler to handle missing permissions

#

All you have to do is commands.has_permissions(manage_messages=True)

#

However if you retrieve a missing permissions error you can just make a purge.error

tawdry perch
#

Or global error handler

velvet tinsel
#

Yeah ig lol

#

I’m starting to get good at asking questions

#

I recently received 2 upvotes in another question

#

And one downvote 😭

#

I also gained 2 rep from editing

tawdry perch
#

I don't use stack overflow for asking questions

velvet tinsel
#

Why

tawdry perch
#

This server is better place

velvet tinsel
#

I agree, but there are experts out there that don’t use this discord server

#

We are privileged to have Caeden though lol

heavy folio
#

how do i convert a str object (image) into a bytes object

slate swan
heavy folio
#

nah url

slate swan
#

You may use request and pillow

heavy folio
#

hm

slate swan
#

Are you taking about a user's avatar?just asking

hollow crown
#

Command raised an exception: AttributeError: 'Member' object has no attribute 'avatar_url' how?

#

command was working yesterday

hollow crown
slate swan
hollow crown
slate swan
#

hey

#

can someone help with this its a tweet command in python for my discord bot

#

error_style is incorrect and idk what to replace with

tawdry perch
#

You made the code, right?

slate swan
#

You can use py member.avatar.url to get the user's avatar url ( though this works only if the user has a non default avatar ).

member.default_avatar.url``` for default avatar
Or , just use ```
member.display_avatar``` will show the user's avatar which shows up in the server , either custom , or main , or default
slate swan
#

thats why i have no clue

heavy folio
slate swan
tawdry perch
slate swan
slate swan
slate swan
jagged root
#

@tawdry perch

tawdry perch
#

ok so

tawdry perch
slate swan
hollow crown
#

how about member.top_role.color what has it have changed it to

jagged root
#

i dont know how to code the new feature " timeout "

slate swan
tawdry perch
#

!d disnake.Member.timeout

unkempt canyonBOT
#

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

Times out the member from the guild; until then, the member will not be able to interact with the guild.

Exactly one of `duration` or `until` must be provided. To remove a timeout, set one of the parameters to `None`.

You must have the [`Permissions.moderate_members`](https://docs.disnake.dev/en/latest/api.html#disnake.Permissions.moderate_members "disnake.Permissions.moderate_members") permission to do this.

New in version 2.3.
hollow crown
slate swan
#

!d discord.Role.color

unkempt canyonBOT
#

property color: discord.colour.Colour```
Returns the role color. An alias exists under `colour`.
slate swan
#

Yea it's same

tawdry perch
#

so.. get member object -> do member.timeout(duration, reason)
duration will be in seconds or it can be datetime object, reason is optional

slate swan
tawdry perch
#

quite simple

jagged root
#

ight

slate swan
#

It's basic python.

#

ohhhh

#

after i do that everythings kind of fine

#

oh

#

got it

#

now i need help with coin flip

#

datetime. is a error and time

#

any other way?

#

Import datetime

#

thanks

#

Weird i get like a million error codes when i try either of those

#

You should actually learn python properly before making a bot

sour lodge
#

How can I write 8ball without the _ showing in the help command and command requiring the _?

slate swan
#

Use the name kwarg of commands

#
@bot.command(name=" commandname")
async def command....```
sour lodge
#

oh ok thanks

vague sundial
#

Can we add a warning system in discord like telegram?

maiden fable
#

Wym

vague sundial
#

for eg lets say you used an abuse in telegram, u usually get a warning by bots, can we do the same in discord?

maiden fable
#

Sure

#

There's a warning command in @unkempt canyon too

#

!source warn

unkempt canyonBOT
#
Command: warn

Warn a user for the given reason.

Source Code
minor ether
#

☺️💀💀

sour lodge
#

how do I make it so these dont show under the help list

visual island
#

hidden = True

#

!d discord.ext.commands.Command.hidden

unkempt canyonBOT
sour lodge
#

thanks

#

and is there a way to give it a category name cause the custom help command is in the main.py

visual island
#

no but you can just change if category == "No Category" to something

sour lodge
#

alright

sour lodge
#

How to reply to a message without it being global, so like it can only be seen by the person who used the command

visual island
#

ephemeral message can only be sent from interactions

sour lodge
#

oh okay

slate swan
#

다들 메리크리스마스~~~!!!!!!

#

merry christmas

#

メリークリスマス

#

Error: Command raised an exception: RecursionError: maximum recursion depth exceeded while calling a Python object

#

Help plsss

slate swan
#

이건 아냐

slate swan
visual island
#

add_item()'s arg should be ui.Item instance

slate swan
#

Is it possible to make a bot livestream something as a message? or do I need to keep editing the message, wouldn't that hit the API rate limit?

#

error:

discord.ext.commands.errors.CommandInvokeError: Command raised an exception: HTTPException: 400 Bad Request (error code: 50035): Invalid Form Body
In embed.thumbnail.url: Scheme "img/error_minecraft_1.png" is not supported. Scheme must be one of ('http', 'https').

code:

emb.set_thumbnail(url = "img/error_minecraft_1.png")
``` ?
slate swan
#

how do I add a image from a computer to embed?

boreal ravine
#

!local-embed

#

what

#

!local-image

#

wtf

boreal ravine
visual island
#

!local-file

unkempt canyonBOT
#

Thanks to discord.py, sending local files as embed images is simple. You have to create an instance of discord.File class:

# When you know the file exact path, you can pass it.
file = discord.File("/this/is/path/to/my/file.png", filename="file.png")

# When you have the file-like object, then you can pass this instead path.
with open("/this/is/path/to/my/file.png", "rb") as f:
    file = discord.File(f)

When using the file-like object, you have to open it in rb mode. Also, in this case, passing filename to it is not necessary.
Please note that filename can't contain underscores. This is a Discord limitation.

discord.Embed instances have a set_image method which can be used to set an attachment as an image:

embed = discord.Embed()
# Set other fields
embed.set_image(url="attachment://file.png")  # Filename here must be exactly same as attachment filename.

After this, you can send an embed with an attachment to Discord:

await channel.send(file=file, embed=embed)

This example uses discord.TextChannel for sending, but any instance of discord.abc.Messageable can be used for sending.

slate swan
boreal ravine
#

Honestly no idea, why do you wanna livestream something?

slate swan
#

don't update it regularly
Try cacheing it and update it in every n seconds

#

What do you want to livestream with a text message tho

#

So my idea was
To use a satellite API of some sort that returns live images, and I want to make this request continuously and make a message update itself with the new image each second, for 15 seconds straight and then stop it

visual island
#

you cant edit attachments

slate swan
#

are you sure?

visual island
#

yes

#

you can only delete it, not changing it

slate swan
#

that's sad

#

so there is no way to do this huh?

visual island
#

actually, discord will convert message with url with .jpg and other image format to images if you have attach files permission. So you can (probably) save it to a url, then send it to discord, and edit the content to a new url

boreal ravine
visual island
#

it deletes the attachment

#

!d discord.Message.edit

unkempt canyonBOT
#

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

Edits the message.

The content must be able to be transformed into a string via `str(content)`.

Changed in version 1.3: The `suppress` keyword-only parameter was added.
slate swan
boreal ravine
#

but you can edit attachments, discord introduced it couple months ago

slate swan
#

pls show us a live example with you user account

magic ore
slate swan
#

Oh?

magic ore
#

Dpy doesn't have a file/files kwarg for Message.edit but it does for Interaction.edit_original_message

slate swan
#

Bro that's an interaction not a message

magic ore
#

You can change the attachments on a Message and edit new files, just not with dpy itself

#

E.g. if a fork supported it you could do that

proven ore
magic ore
#

Yes

boreal ravine
visual island
#

Starting with API v10, the attachments array must contain all attachments that should be present after edit, including retained and new attachments provided in the request body.

boreal ravine
#

pycord supports it lol

visual island
#

v10..

proven ore
#

thats cool

magic ore
#

Works in v9 (editing attachments)

proven ore
#

but eh i dont think its very useful since u can just delete the file and add the edited

visual island
#

I never tried it yet as I pretty much dont need it

boreal ravine
#

¯\_(ツ)_/¯

slate swan
visual island
boreal ravine
#

ok

maiden fable
#

ahem ahem

visual island
maiden fable
visual island
#

ew flex twice within 5 mins

maiden fable
#

Anything else?

visual island
#

um

#

still code bots?

tawdry perch
#

I broke my remind command smh, I don't even know how

maiden fable
#

Bots are.... boring now

maiden fable
tawdry perch
#

smth went badly wrong in database but nothing makes sense anymore in it

maiden fable
#

Sad

visual island
maiden fable
#

!pypi dash

unkempt canyonBOT
#

A Python framework for building reactive web-apps. Developed by Plotly.

maiden fable
#

Anyways it's OT soo, uhhh

boreal ravine
#

@maiden fable i dont think discdb is that efficient because you have to fetch everything (the data) and you'd have to have to message id at all times (i think, im not sure) unless you have some sort of caching system

maiden fable
#

Well get_json does returns the message content, and I ain't fetching the msg everytime

boreal ravine
#

o

maiden fable
#

Also am saving the msg in self._msg

visual island
maiden fable
#

Well, u can say so ngl. But we didn't pick it cz it was easier. Before we were using flask but since we also want dropdowns and stuff in our webpage and didn't want to add any custom JS for the events like whenever someone interacted with the dropdown, we went with dash

visual island
#

oh I see, basically making an interactive website without using js instead from the backend. That's cool

boreal ravine
#

illegal

craggy cloak
#

os.getenv("LAVALINK_HOST"), 2333, os.getenv("LAVALINK_PASSWORD"),

Where can i find my LavaLink Host and Password?

proven osprey
#

what i did wrong there? help me please!

tiny ibex
craggy cloak
tiny ibex
craggy cloak
#

yes

tiny ibex
craggy cloak
#

2333

tiny ibex
#

And the username is ofc your localhost IP

craggy cloak
#

o lol it if fixed now

#

:bruh:

tiny ibex
craggy cloak
#

i restart my bot and it worked lol

tiny ibex
proven osprey
#

what i did wrong there? help me please! could someone help me please?

quick gust
#

error??

#

we can't magically help u

tall arch
#

hey guys, does anyone know how i can make a user input using replit, so like if i made a question and there could be two answers. One could be yes and the other no. i want the bot to read it and respond either correct or not? so far the bot is able to ask a question but to respond i have to go to the replit terminal

gentle rose
#

Does this if-statement detect @everyone tag?

if message.role_mentions:
calm moat
#

can anyone help me? i try to make a Music bot but i got a error :/

slate swan
#

so i've got a automod thingy which adds words to a database and then checks if any message contains that word by using sets thinkCat so i'm wondering is there any way to avoid reading the database everytime someone sends a message

maiden fable
#

On bot startup, fetch from the db once and set a botvar with the result @slate swan

slate swan
maiden fable
#

Like bot.bad_words = <fetch from DB>

shadow wraith
#

how do you give a command a cooldown i forgor 💀

maiden fable
slate swan
maiden fable
unkempt canyonBOT
#

@discord.ext.commands.cooldown(rate, per, type=discord.ext.commands.BucketType.default)```
A decorator that adds a cooldown to a [`Command`](https://discordpy.readthedocs.io/en/master/ext/commands/api.html#discord.ext.commands.Command "discord.ext.commands.Command")

A cooldown allows a command to only be used a specific amount of times in a specific time frame. These cooldowns can be based either on a per-guild, per-channel, per-user, per-role or global basis. Denoted by the third argument of `type` which must be of enum type [`BucketType`](https://discordpy.readthedocs.io/en/master/ext/commands/api.html#discord.ext.commands.BucketType "discord.ext.commands.BucketType").

If a cooldown is triggered, then [`CommandOnCooldown`](https://discordpy.readthedocs.io/en/master/ext/commands/api.html#discord.ext.commands.CommandOnCooldown "discord.ext.commands.CommandOnCooldown") is triggered in [`on_command_error()`](https://discordpy.readthedocs.io/en/master/ext/commands/api.html#discord.discord.ext.commands.on_command_error "discord.discord.ext.commands.on_command_error") and the local error handler.

A command can only have a single cooldown.
shadow wraith
#

huh i dis/misremembered eit

slate swan
shadow wraith
#

what does rate have to be and per

maiden fable
slate swan
#

lots of work but okie

shadow wraith
maiden fable
shadow wraith
#

huh alr

#

oh yeah and does per have to be specified in seconds

maiden fable
#

Yes

slate swan
#

i have to revamp a whole file Sad CH_Dead

gentle rose
#

How to detect @everyone or @here tag in bot?

quick gust
slate swan
#

can i store a list in a database as a string then return it so its becomes a list when i fetch it ?

whole sparrow
#
def main(key):
    try:
        client.run(key)
    except:
        sys.exit()

api_key = StringVar()
def submit_api_key():
    x = threading.Thread(target=main, args=(api_key.get(),))
    x.daemon = True
    x.start()

idk if this is for here, but im stuck tbf. Im trying to run a tkinter gui and discord bot together and it works perfectly fine if i enter the correct api key first time, but if i make a mistake and then type the correct one it still wont work due to "Event loop is closed". I tried fixing this by doing sys.exit() on improper token but this still doesnt seem to work so oof, any help would be greatly appreciated

#

i might be dumb on this problem tho

whole sparrow
slate swan
#

smart but not smart enough

#

since they have one for arrays

whole sparrow
#

lmao they do?

#

what database is that

#

ive done that cause i was using sql

slate swan
#

oh postgres

#

i'll do your way it sounds easier shrug

whole sparrow
#

yh makes sense.

#

but what are you trying to achieve though, the thing with the method i showed is kinda stupid for the reason i did it as there was a much ebtter way

#

i was trying to store pokemon characters for each user whenever they gained one

slate swan
#

yk a blacklist system that blacklist words , each guild has there own so a guild : array of blacklisted words

whole sparrow
#

ah i see

#

the thing i would do instead of an array is that i would make a composite key of guild and blacklist word and have multiple of them, the two of the same would not exist but you would be able to remove and add new words much easier than the list thing

#

rlly hard to explain ill show a pic

#

im not the best at expalining

#

the user_id is not a primary key and can be repeated, having multiple pokemon names, but not two of the same rows exist

#

that is much much better than a long string seperated by commas imo

#

and you can get all the values back very easily using commands, but this is sql tho

#

idk if this has helped but yh

proven ore
#

its a commands.Bot attribue

gentle rose
#

oh, thanks!

proven ore
#

commands.Bot(... allowed_mentions = discord.AllowedMentions(everyone = False, users = True, roles = False))

proven ore
slate swan
proven ore
#

(works on d.py as well)

gentle rose
slate swan
#

cool message.mention_everyone would be the easiest way to do that

proven ore
slate swan
proven ore
#

cus that applies on all the bot

slate swan
#

It's used while sending messages

proven ore
cold sonnet
slate swan
#

Not checking a message sent mentions everyone

#

!d discord.AllowedMentions

unkempt canyonBOT
#

class discord.AllowedMentions(*, everyone=True, users=True, roles=True, replied_user=True)```
A class that represents what mentions are allowed in a message.

This class can be set during [`Client`](https://discordpy.readthedocs.io/en/master/api.html#discord.Client "discord.Client") initialisation to apply to every message sent. It can also be applied on a per message basis via [`abc.Messageable.send()`](https://discordpy.readthedocs.io/en/master/api.html#discord.abc.Messageable.send "discord.abc.Messageable.send") for more fine-grained control.
cold sonnet
slate swan
#

"what mentions are allowed"

#

!d discord.Message.mention_everyone

unkempt canyonBOT
#

Specifies if the message mentions everyone.

Note

This does not check if the @everyone or the @here text is in the message itself. Rather this boolean indicates if either the @everyone or the @here text is in the message and it did end up mentioning.

proven ore
slate swan
#

That's just for the bot sir , they want to check if a message received from Gateway mentions everyone

#
    @tasks.loop(seconds=30)
    async def my_loop(self):
        data = await self.bot.blacklist_db.fetch("SELECT guild_id , text FROM blacklist")
        ids = [i["guild_id"] for i in data]
        words = [i["text"] for i in data.split()]
        print(dict(zip(ids,words)))        
        ``` sooo confused
https://cdn.discordapp.com/attachments/696888170167664691/924341862012182528/unknown.png
#

What db are you using?

#

Seems like you're using an non-async one

proven ore
gentle rose
#

Can i add special discord role to a user for only 15 minutes? Is there any flag like in message deletion?

proven ore
slate swan
#

Nope , but you can asyncio.sleep for 15*60 seconds and remove the role

proven ore
#

yeah

slate swan
#

^

proven ore
#
user=<user>
role = discord.utils.get(ctx.guild.roles, name = "role name")
await user.add_roles(role)
await asyncio.sleep(60*15)
await user.remove_roles(role)
#

here

#

hold on

#

oop

gentle rose
#

Thanks!

proven ore
#

wait wa

gentle rose
#

i think for me sleep is bad idea

proven ore
proven ore
gentle rose
slate swan
#

Doesn't matter

proven ore
#

orr

slate swan
gentle rose
#

🤔 wow

slate swan
#

So even if two users react on the same time , each session would be continued seperately

proven ore
slate swan
#

that's what async is....

proven ore
#

ehh i dont really know async

#

XD

boreal ravine
#

nice

proven ore
#

A

gentle rose
proven ore
gentle rose
#

aah, thanks

maiden fable
#

It works whenever your bot pings someone, be it on message or command

proven ore
slate swan
#

ugh finally

slate swan
#

almost an hour aPES2_Sweat and 15 mins

#

A bot in an hour and 15 mins?

#

me who's been doing the same for a month

patent surge
#

I have Commands object how do i get the docstring of the command ?

slate swan
unkempt canyonBOT
#

property short_doc: str```
Gets the “short” documentation of a command.

By default, this is the [`brief`](https://discordpy.readthedocs.io/en/master/ext/commands/api.html#discord.ext.commands.Command.brief "discord.ext.commands.Command.brief") attribute. If that lookup leads to an empty string then the first line of the [`help`](https://discordpy.readthedocs.io/en/master/ext/commands/api.html#discord.ext.commands.Command.help "discord.ext.commands.Command.help") attribute is used instead.
patent surge
#

Ok

maiden fable
#

command.brief can also be used tho

slate swan
#

Or. Command.callback.__doc__

#

yea also what hunter said

#

But brief can be different , as the embed above explains

maiden fable
#

Yea

jovial urchin
#

What module should i learn to make a discord bot

#

?

maiden fable
unkempt canyonBOT
maiden fable
#

This is the basic one, but since it's discontinued, u can use some of it's forks like disnake and pycord

jovial urchin
#

which one would you recommend and what knowledge should I have beforehand?

maiden fable
#

Basic asyncio, classes and OOP

slate swan
#

disnake imo , and for knowledge
basic concepts like variables , data types , OOP and a bit of Asyncio

#

pydis_nope_py And staying away from YouTube tutorials

jovial urchin
slate swan
#

*bad

#

if you go through the docs , you can understand everything they teach in a better way

pliant gulch
#

Youtube tutorials teach you through a middle man

#

The docs come directly from contributors and or the maintainer

jovial urchin
#

aha where can i find those?

slate swan
#

Read the channel topic , it's linked there

jovial urchin
#

aha thanks!

slate swan
maiden fable
#

Well yea. Sarthak completed the list for me (;

slate swan
#

!d discord.on_voice_state_update ^

unkempt canyonBOT
#

discord.on_voice_state_update(member, before, after)```
Called when a [`Member`](https://discordpy.readthedocs.io/en/master/api.html#discord.Member "discord.Member") changes their [`VoiceState`](https://discordpy.readthedocs.io/en/master/api.html#discord.VoiceState "discord.VoiceState").

The following, but not limited to, examples illustrate when this event is called...
jovial urchin
slate swan
#

tbh, I'd say just get to the intermediate point of python and then do a dc bot

patent nexus
#

Hi

jovial urchin
pliant gulch
#

Unless you are working internally you won't need to know all that confusing stuff

slate swan
#

well. In case of discord bots decorators are not too confusing

pliant gulch
#

The only thing in discord.py you need to know about decorators is that

slate swan
#

Yea

pliant gulch
#

Functions, methods can be decorated by them

#

E.g @decorator placed over the function, method declaration

slate swan
#

one last thing , use commands.Bot if you're making commands . Not Client. lemon_warpaint

#

Wait imma send a youtube video, I never understood how decorators works until I watched this one, give me 1 min

#

interesting

#

Here, I promise you wont regret

#

It's nothing advanced btw, bare basics

#

skip to 1:09

pliant gulch
#

Decorators are very neat syntatic sugars, I'd give it 8/10 prob

#

Very useful in advance cases such as using decorators as markers via metaclasses and a staticmethod

slate swan
#

metaclasses? omegalul that's very rare tho

#

I dont even know how metaclasses works

pliant gulch
#

Eh, depends on what you are doing

#

I use metaclasses, a lot

#

But mostly you won't need them

slate swan
#

Metaclasses aren't even necessary?

#

Do u just do it, because u can? lol

pliant gulch
#

Using this metaclass I can actually decorate methods in a useful manner

#

Unless otherwise I would be required to use @Class.method(...)

#

But here I can use a special marker, E.g @command(...)

#

Losing the need of access for the Class from earlier

slate swan
#

mY gaWhd haf merhyy 👴

pliant gulch
#

Whilst also marking methods

#

Thus I can later use them when attaching

slate swan
#

Are you making your own discord API wrapper?

pliant gulch
#

Yes

coral harness
#

guys how to make this?

slate swan
#

buttons

#

they are called buttons shrug

#

damint , check the docs of dpy 2.00

jovial urchin
slate swan
slate swan
slate swan
#

yep pretty easy to learn with view

#

if your using disnake just subclass view and add buttons lol

coral harness
#

damn

#

ok

slate swan
#

what fork do you use?

#

or dpy

maiden fable
#

I am thinking of going back to dpy

slate swan
#

just why

fluid spindle
#

Hi, is there a way to get a member object with a user's name?
I know about IDs, but I don't want to use them for some reason...

pliant gulch
#

But I did do a lot of the stuff in the wrapper it's quite hard to maintain

echo heart
#

can I not make my bot dump on disboard for me ?

pliant gulch
slate swan
#

Yeah, what made you wanna do an API wrapper for discord?

pliant gulch
#

Because I didn't like how discord.py was ending, and I didn't like all the shitty forks out there

#

So I took matters into my own hands

slate swan
#

Damn, lets hope your new API wrapper succeeds 🙂

proven ore
#

A

fluid spindle
slate swan
proven ore
proven ore
fluid spindle
proven ore
#

he asked for something just like fetch_user but with username instead of id

slate swan
#

ahhh

#

mb then

proven ore
fluid spindle
proven ore
coral harness
proven ore
quick gust
coral harness
quick gust
#

!d discord.ui.Button

unkempt canyonBOT
#

class discord.ui.Button(*, style=<ButtonStyle.secondary: 2>, label=None, disabled=False, custom_id=None, url=None, emoji=None, row=None)```
Represents a UI button.

New in version 2.0.
slate swan
#

okimii — Today at 6:58 PM
yep pretty easy to learn with view
if your using disnake just subclass view and add buttons lol

quick gust
#

!d discord.ui.View

unkempt canyonBOT
#

class discord.ui.View(*, timeout=180.0)```
Represents a UI view.

This object must be inherited to create a UI within Discord.

New in version 2.0.
quick gust
#

Check both of these

coral harness
#

ok

slate swan
slate swan
shadow wraith
#

hello oki

slate swan
shadow wraith
#

wait how do you add all intents in disnake

fluid spindle
proven ore
#

thats cool

#

!d discord.utils.get

unkempt canyonBOT
#

discord.utils.get(iterable, **attrs)```
A helper that returns the first element in the iterable that meets all the traits passed in `attrs`. This is an alternative for [`find()`](https://discordpy.readthedocs.io/en/master/api.html#discord.utils.find "discord.utils.find").

When multiple attributes are specified, they are checked using logical AND, not logical OR. Meaning they have to meet every attribute passed in and not one of them.

To have a nested attribute search (i.e. search by `x.y`) then pass in `x__y` as the keyword argument.

If nothing is found that matches the attributes passed, then `None` is returned.

Examples

Basic usage...
proven ore
#

oh

shadow wraith
tacit token
#

how to check how many servers my bot ? 😄

slate swan
#

sm0L a

slate swan
shadow wraith
#

!d disnake.Intents.all

unkempt canyonBOT
#

classmethod all()```
A factory method that creates a [`Intents`](https://docs.disnake.dev/en/latest/api.html#disnake.Intents "disnake.Intents") with everything enabled.
shadow wraith
#

im getting this traceback:

Traceback (most recent call last):
  File "main.py", line 11, in <module>
    bot = commands.Bot(command_prefix=["$", 'Diesel, ', 'Deez, ', 'Copilot, ', 'copilot, '], intents=discord.Intents.all())
  File "/opt/virtualenvs/python3/lib/python3.8/site-packages/discord/ext/commands/bot.py", line 98, in __init__
    super().__init__(**options)
  File "/opt/virtualenvs/python3/lib/python3.8/site-packages/discord/ext/commands/core.py", line 1107, in __init__
    super().__init__(*args, **kwargs)
  File "/opt/virtualenvs/python3/lib/python3.8/site-packages/discord/client.py", line 248, in __init__
    self._connection = self._get_state(**options)
  File "/opt/virtualenvs/python3/lib/python3.8/site-packages/discord/client.py", line 265, in _get_state
    return ConnectionState(dispatch=self.dispatch, handlers=self._handlers,
  File "/opt/virtualenvs/python3/lib/python3.8/site-packages/discord/state.py", line 152, in __init__
    raise TypeError('intents parameter must be Intent not %r' % type(intents))
TypeError: intents parameter must be Intent not <class 'disnake.flags.Intents'>
slate swan
#

why isnt it catching that error ?

shadow wraith
#

when i use disnake.Intents.all()

slate swan
#

wtf is that

#
["$", 'Diesel, ', 'Deez, ', 'Copilot, ', 'copilot not closed here, idk whats even this '] -> , ```
shadow wraith
#

wdym, i added a space there so syntax looks clean

slate swan
shadow wraith
slate swan
#

That's a bad practice

shadow wraith
#

💀

slate swan
#

how

shadow wraith
#

time to search replace ig

slate swan
#

!e


import random as discord
print(discord.choice(["hey","i'm","working"]))```
slate swan
shadow wraith
#

ok now it's working

slate swan
#

oh wait

shadow wraith
#

i search replaced

slate swan
#

Great

unkempt canyonBOT
#

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

working
slate swan
#

or is he importing discord aswell

#

he had discord imported too as his error suggests

shadow wraith
#

no i did import disnake as discord and then from discord.ext import commands but now i search replaced

slate swan
#

Yea

shadow wraith
#

wait that makes fucking sense

#

im using replit

slate swan
#

Your commands came from discord

shadow wraith
#

now that makes sense, replit thought i was using discord

#

still don't blame it on replit tho

slate swan
#

just use disnake :p, don't import it as Discord lol it's often confusing

#

Even for yourself

shadow wraith
#

im just changing from discord.py to disnake for no reason lol

tacit token
proven ore
shadow wraith
quick gust
proven ore
quick gust
shadow wraith
#

fuck that makes sense

#

i edited

shadow wraith
#

and that's not bad

slate swan
tacit token
slate swan
shadow wraith
#

tbh even the python bot supports it

#

!d disnake.Member.timeout

unkempt canyonBOT
#

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

Times out the member from the guild; until then, the member will not be able to interact with the guild.

Exactly one of `duration` or `until` must be provided. To remove a timeout, set one of the parameters to `None`.

You must have the [`Permissions.moderate_members`](https://docs.disnake.dev/en/latest/api.html#disnake.Permissions.moderate_members "disnake.Permissions.moderate_members") permission to do this.

New in version 2.3.
slate swan
slate swan
shadow wraith
slate swan
#

reason for it being 0 is , discord.py is a cache dependent library , so until the bot is online almost every cached object is 0

shadow wraith
#

wait im not that familiar with timeouts but what does until=... do

#

the duration already provides the time

slate swan
#

until takes a datetime object instead of seconds

shadow wraith
#

i see why they said one of duraton or until

slate swan
#

you can use it if you don't want to provide duration kwarg

#

Yea

shadow wraith
#

man disnake is so fucking cool already 😍

#

ok ill stop with my weirdness

slate swan
tacit token
slate swan
tacit token
#

0 again

silent portal
#

@tacit token
Try giving the value a variable.

@bot.event
async def on_ready()
    Guild_count = len(bot.guilds)
    print("I'm in "+ Guild_count +" servers")```
slate swan
silent portal
#

are intents even enabled?

slate swan
#

And yes. You didn't use the code I sent

slate swan
silent portal
#

Well if that's the case.. I don't think he used the code u've sent cuz ther's nothing wrong abt it

slate swan
#

Yea

silent portal
#

len always gives an integer right?

#

Or is there a case where you have to convert it?

slate swan
#

len is length , so it's always 0/ a positive integer

silent portal
#

alr ty

sour lodge
#

I am following the one in dark black and idk whats wrong

slate swan
#

It's just replit being weird

sour lodge
#

no way to fix?

slate swan
#

Hover on it and read what It says

sour lodge
fluid spindle
slate swan
#

Your indents

shadow wraith
#

its probably pyflakes being slow again