#dev-contrib

1 messages · Page 164 of 1

gritty wind
#

I don’t know if fastapi reads that

#

But requests has a body parameter in the request function

#

And more conveniently a json parameter

cursive relic
#

oh..

#

Thx, I will try to figure it out

fallen patrol
#

sir-lancebot#778 🥺

dusky shoreBOT
placid ermine
#

@last patio 👉 👈

austere hornet
#

Could a core dev please take a look at sir-lancebot#1000 and maybe approve? Thanks!

dusky shoreBOT
austere hornet
#

(Yeah ik what a milestone haha)

last patio
clever wraith
#

@fervent sage im thinking of switching the name of the avatarmod command because that is already used as a group alias, hows avatareffects?

#

im also considering removing that alias

fervent sage
#

I thought the avmod stuff was meant to replace the existing avatarmod stuff

#

indeed the avatarmod alias was added in the meantime because of the issue i made

clever wraith
#

ah

#

ill remove the alias

fallen patrol
#

!d d

#

why does this not have any output?

patent pivot
#

do we normally say no permission to use this command

#

i forget

fallen patrol
#

ohhhhhhh its an alias

#

nvm

patent pivot
#

yeah

#

delete is aliased to rm and d

#

and removedoc

fallen patrol
#

that makes more sense

placid ermine
placid ermine
#

err

#

if i'm a member of the org should i self-assign an issue

#

okay i see people have done that in past issues

#

that was a lot of setup for a 4 line PR

clever wraith
#

nice test scale

clever wraith
#

Notice that datetime.utcnow() is actually timezone unaware (yeah, I know), which could become a problem since you wouldn't be able to compare the timezone-unaware now_datetime to the timezone-aware duration. In practice this will never happen since duration should always have timezone information.
aaaa

gritty wind
#

Which I've been trying to archive for months now

#

I blame all the nsjail config and cgroup PRs for that

clever wraith
#

lol

#

Github making a PR to upstream by default is a bit misleading, I agree

#

It shouldn't have a default remote and make you select between upstream and downstream tbf

fallen patrol
gritty wind
#

Thanks, noted for next time

gritty wind
#

Aaaaaaaaaaalright

#

Reposiotry archived

#

See y'all for 3.11

simple slate
#

hi

dim pelican
#

Hey! Are you the Krish I assigned the issue to today?

simple slate
#

yes

#

i have forked the repo

#

plz guide me how should i proceed

#

can i join any voice channel to talk

dim pelican
#

There are voice gates in place for voice chat, and I typically don't join there anyways. For the setup, after you fork the repo you need to clone it locally. If you wish to run the bot locally as well there are some other things to set up too (this is usually how people test their PRs)

simple slate
#

yes i have cloned the repo

#

now how should i proceed to test

dim pelican
#

I would recommend using docker

simple slate
#

is there any time limit for contribution !

dim pelican
#

Not at all

simple slate
#

thank you because this is my first contribution i might take time to understand all this

dim pelican
#

We all started somewhere! Take your time and if you hit a wall just ask here, there are usually devs willing to help out

simple slate
#

🔥

molten perch
#

Approved the issue, good luck!

dim pelican
#

Ahhh I should have waited to assign until it was approved

#

Thanks though

molten perch
#

No worries, it's approved and assigned now 👌

fallen patrol
#

@gritty wind smh

gritty wind
#

Was sup

fallen patrol
#

forms forms forms forms dependabot

gritty wind
#

It's there lol?

fallen patrol
fallen patrol
gritty wind
#

I'd suggest comparing the list of repos on that page to the list of repos you get from github before having to click "load more"

#

Everything in that list is either there because it was on the main page, or because I remembered it

fallen patrol
#

smh I mention patsy because I commited to it

#

so I remember it

#

either way, that makes sense

gritty wind
#

Smh the only comments I've gotten on that page where complaints, should've just kept it private lol

#

Anyways I'll add it

#

Just gotta unlock everything 👀

fallen patrol
#

patsy#4 is a direct dupe of patsy#3 so you may or may not want to count it

gritty wind
#

99% of forms-frontend is a bot opening and closing the same PR

#

100% accuracy is not the goal lol

fallen patrol
#

LOL

clever wraith
#

Quick question regarding in_executor in avatarmod, does it return another PIL.Image.Image?

gritty wind
#

It returns the return of the function, which if just a discord.File

#

Technically it returns a future, which when awaited returns the result of the function it's pointing to

clever wraith
#

Ah

#

I'm working on revamping avatarmod which will involve applying multiple effects to a profile picture

gritty wind
#

that sounds... kinda resource consuming lol

#

Was this cleared in an issue?

fallen patrol
#

sir-lunchbot#710

#

sir-lancebot#710

dusky shoreBOT
simple slate
#

Hi everyone i just sported a bug in your documentation ( correct me if i am wrong )

https://www.pythondiscord.com/pages/guides/pydis-guides/contributing/setting-test-server-and-bot-account/#setting-up-a-bot-account

in this documentation
under the section " Setting up a Bot Account "
point no. 6 " In the General Information tab, grab the Client ID. "
instead of " General Information tab " it should be " OAuth2 tab "
if i can improvise it do let me know i / community can create an issue and i / community can solve it.

tawdry vapor
#

I think it used to be in gen info but they updated the site and split it off into its own section

#

Yes, you can open a PR on the site and fix it

simple slate
#

so we should update it

#

ok

gritty wind
#

It's still there no?

tawdry vapor
#

IDK

gritty wind
tawdry vapor
#

But it's called application ID in there now

simple slate
gritty wind
#

It's the same

#

I just checked

tawdry vapor
#

But the guide refers to it as client ID

gritty wind
#

I suppose we should change that

simple slate
#

then we should change one thing

gritty wind
#

I wonder if we should recommend the generator instead

simple slate
#

either the tab or name

gritty wind
#

nah it;s too complex

simple slate
#

so that it removes doubt !

gritty wind
#

Feel free to PR it directly

simple slate
#

ok

#

do i need to follow the complete template in order to raise an issue

tawdry vapor
#

For this? There's no appropriate template anyway.

#

And you don't need to open an issue if you want to fix this yourself. We're making an exception since it's a trivial change.

gritty wind
#

You were welcome to just PR it, but that's alright

#

I've assigned you and you can pr it now

simple slate
#

how much time does this test takes

crude gyro
#

that check means someone has to review it

simple slate
#

Hi is there any one who can help me run sir-lancebot on my test server without docker !

gritty wind
#

Sure, how far have you gotten

simple slate
#

i have the source code on local machine and test server i have also created a bot account and i have my client id and token , i tryed using docker but i dont know why it is not working and my laptop is also not responding fast now so i thought of working on this project without docker ( i have python 3.x and an ide (pycharm) )

gritty wind
#

I’d still suggest docker if you can because it’s so much easier, but it’s up to you

#

Have you seen the instructions on the site

simple slate
#

yes

gritty wind
#

Alright, what have you done

simple slate
#

last 2 steps left

gritty wind
#

Right, right have you started on those steps

simple slate
#

yes

#

i have all the token and id as stated in doc all server set i just need to run the bot but how !

vale ibex
#

Have you installed docker?

simple slate
#

yes

vale ibex
#

Do you get an error when running docker-compose up?

simple slate
#

yes

vale ibex
#

Can you send it?

#

Would help us help you.

simple slate
vale ibex
#

Did you create a .env file?

#

This explains it

#

Along with the linked page "Learn how to set environment variables here."

simple slate
#

no

vale ibex
#

Cool, if you follow the steps on that page it should get you past this issue.

#

If you have further issues after that feel free to post here again

simple slate
#

ok , ty

fallen patrol
simple slate
#

"docker-compose up " after running this command it has stoped/not responding over here , should i wait ?

gritty wind
#

The bot is started now

#

Try running a command like ping

#

@dusky shore ping

dusky shoreBOT
#
:ping_pong: Pong!

Gateway Latency: 136ms

simple slate
dim pelican
#

Yup! Make sure the prefix is the same (default is . I think)

#

.ping

dusky shoreBOT
#
:ping_pong: Pong!

Gateway Latency: 115ms

simple slate
gritty wind
#

I usually start people off with the ping because it’s guaranteed lol

#

But the dot is fine

#

You can’t see it at all, or it’s offline?

simple slate
#

i can't see it at all !

dim pelican
#

Might need to add it to the server, I think the last time I did it I went to the Developer Portal -> Applications -> OAuth2 -> URL Generator

gritty wind
#

Did you follow the steps for adding the bot to your server?

simple slate
#

i just create a bot accout and a server

gritty wind
#

Okay, make sure to invite the bot to your server too

#

You can do so by following the steps bras suggested

dim pelican
#

Replace <CLIENT_ID_HERE> in the following URL and visit it in the browser to invite your bot to your new test server.

https://discordapp.com/api/oauth2/authorize?client_id=<CLIENT_ID_HERE>&permissions=8&scope=bot

Optionally, you can generate your own invite url in the OAuth tab, after selecting bot as the scope.

#

Ah how do I escape that hyperlink

gritty wind
#

Just quote it

simple slate
#

ig it's still not working

dim pelican
#

Looks like it is online

simple slate
#

put the ping commad is not working

#

but*

dim pelican
#

Did you create that channel name and update the ID in the .env file?

simple slate
#

ok so i should update all the id's

dim pelican
#

Yes, the .env file will be specific to your server

simple slate
#

bingo i just sported the error in channel name i used " " insted of "-"

#

where can i find list of all sir-lancebot command

dim pelican
#

.help

simple slate
#

every time i need to use docker-compose up or poetry run task start command to make my bot online

dim pelican
#

For testing changes you can just reload the cog (the script name) with .c r realpython

#

That would reload the realpython cog, and if you have made changes to it they would then be active

austere hornet
simple slate
#

why is this not running

dim pelican
#

Try .challenge python fibonacci

#

Or just .challenge

dim pelican
#

Reddit uses an API, and you would need a special token for it

simple slate
#

is it imp

static canyon
dim pelican
#

In the quote it wouldn't let me escape it with <>

#

Since that particular one has placeholders to show where to insert the Client ID

simple slate
#

ok

simple slate
#

on an avg

dim pelican
#

.ping

dusky shoreBOT
#
:ping_pong: Pong!

Gateway Latency: 123ms

dim pelican
#

That many milliseconds, but when it is working with other services there can be a delay based on your connection

simple slate
#

how can i reduce this !

sleek steppe
#

fwiw, it's not that much of a delay (especially for a test bot)

simple slate
#

ok

dim pelican
#

Do you have a role in that test server?

simple slate
#

yes

dim pelican
#

You should be an admin

simple slate
#

how can i change that setting !

dim pelican
#

In the server settings I believe

simple slate
#

ok done now its working

dim pelican
#

I think Roles -> Edit -> Manage Members

simple slate
dim pelican
#

👍

simple slate
#

just one last question for the day i have disturbed u guys a lot so the issue no #1001when we run this command .realpython it should show a url ( https://www.pythondiscord.com/ ) instead of this error

dim pelican
simple slate
#

ok

#

thank you

dim pelican
#

No, thank you!

austere hornet
dusky shoreBOT
clever wraith
#

hi all

#

keeping in mind that the PfpEffects.apply_effect function returns a discord.File, how am i supposed to apply multiple effects to an image?

sleek steppe
clever wraith
#

probably

#

i can set up a custom function to call multiple effects

sleek steppe
#

sounds good

gritty wind
#

You could also… edit that file or change the return type lol

clever wraith
#

im gonna work on this a lot tomorrow

placid ermine
gritty wind
#

It is not

#

I wasn’t even aware you could set the actual expiry date directly

vocal prairie
#

you can, I learned that the hard way. Trying to ban some scammers and put the date of the day first...

placid ermine
stable mountainBOT
#

bot/utils/scheduling.py line 68

If `​time`​ is in the past, schedule `​coroutine`​ immediately.```
tawdry vapor
#

IIRC the original implementation was like that. Furthermore, it's inspired by call_at from asyncio's event loop, which behaves in this way.

#

Also, it calls datetime.now() within the function. Not sure if the resolution is small enough to make a delay between creating the time argument and the function calculating the delay internally.

#

So the time argument is essentially saying "execute the coroutine no earlier than this time". In general, this makes more sense than erroring out because the time has already passed. If you had a case where you needed a coroutine to execute within a specific time frame, otherwise it's no longer relevant, then I think a more specialised function would be in order.

placid ermine
#

hmm

#

management.py uses the stdlib datetime
_scheduler.py uses arrow
cool cool cool cool cool cool cool

tawdry vapor
#

Well I guess I gotta give it up

placid ermine
#

okay there's only one other usage of datetime in management.py, should i upgrade it to arrow

tawdry vapor
#

I have a PR that moves a bunch of stuff to arrow. Been open since August last year.

#

I've kinda been curious to see how long it would take to get that reviewed without me mentioning it

#

TBH I got kind of screwed over by other PRs being merged after mine

placid ermine
#

aaa i can't even request reviews without misclicking

fallen patrol
placid ermine
#

:hmm:

gritty wind
clever wraith
#

Re: bot#1960 @timid sentinel are both parts approved? In hindsight I should've made two different issues

tawdry vapor
#

It is marked as low priority anyway

#

If anything I'm more annoyed at another PR getting merged that caused a lot of conflicts

timid sentinel
trail pilot
vale ibex
#

nomination["User"]["ID"] should get you the user id

#

worth testing to be sure tho

trail pilot
vale ibex
#

nominate someone

trail pilot
#

just nominate someone then edit it?

#

alright

vale ibex
#

👌

magic arch
#

@vale ibex @cold island how's this? or should I hardcode the actual expected dict instead? ```py
ctx.send.assert_called_once()
self.assertEqual(ctx.send.call_args.args[0],
'@LemonLemonishBeard#0042 :yay!: Return code 0.\n\n\n[No output]\n')
allowed_mentions = ctx.send.call_args.kwargs['allowed_mentions']
expected_allowed_mentions = AllowedMentions(everyone=False, roles=False, users=[ctx.author])
self.assertEqual(allowed_mentions.to_dict(), expected_allowed_mentions.to_dict())

austere hornet
trail pilot
#

huh, getting this error when trying to start the Python bot locally

ERROR: for redis  Cannot start service redis: driver failed programming external connectivity on endpoint bot_redis_1 (ef9c9fc0b3a5c962e8cce8e8026aa846ee5e7c7c81a9437c1c987581d3e0fab5): Bind for 127.0.0.1:6379 failed: port is already a
llocated
magic arch
#

Means you already have redis running somewhere else I think

trail pilot
#

hmm, i started web first if that changes anything

gritty wind
#

it shouldn''tttttt

#

Try just changing the port

austere hornet
gritty wind
#

nah

austere hornet
#

Isn't it on sir-lancebot though?

gritty wind
#

I'll let you in on a secret: sir-lance works in both

austere hornet
#

Ah

gritty wind
#

It's kinda pointless rn

austere hornet
#

Ah I see, ok

gritty wind
#

Do we actually need to test it? It looks fine though

trail pilot
#

oh wait

#

is sir lance running?

#

oops

magic arch
trail pilot
#

docker automatically starts on my computer on startup, that explains it 🤦‍♂️

gritty wind
#

You wrote it already, it's fine

#

You don't need to test it in all three functions though

magic arch
#

Ohhh ok gotcha, will get that done soon

austere hornet
magic arch
#

tada, bot#2041 tests passing now

dusky shoreBOT
thorny obsidian
#

doop doop, did you still want to write up an issue for this?

summer garden
gritty wind
#

Why do these tests all use single quotes

#

Bleh

thorny obsidian
magic arch
#

idk don't blame me lol

gritty wind
#

@vale ibex ^^^^^^^

vale ibex
#

eh?

magic arch
#

You wanted to see what the tests would look like for eval allowed mentions, now you can ✨ 🎉

vale ibex
#

oh, right

#

I'll give it a look when I'm at pc

#

github is telling me there are merge conflicts, but not where they are, so can't merge it

magic arch
#

Weirddd, I’ll take a look on command line when I get home in like half an hour or so

vale ibex
#

wait

#

wtf has happened

#

The commits are in the history of main

#

yet the PR is still open

#

and no actions were triggered

#

@patent pivot @vocal wolf I see you're both online

#

can you please check I am not seeing things

magic arch
#

I see it too and there’s even a merge commit 😂

vocal wolf
#

which what where?

vale ibex
#

but is still open

#

and no actions have been triggered on main

vocal wolf
vale ibex
#

yea that's what I see too

#

now check commit history on main

vocal wolf
#

what the hell lol

#

what if I hit merge again?

vale ibex
#

can't merge, it has conflicts lol

#

conflicting with itself

vocal wolf
#

the fuck

magic arch
#

I’m so confused

vocal wolf
#

oh I thought that may have been bugged

vale ibex
#

arthur deploy restart bot

vocal wolf
#

so I tried to merge

radiant merlinBOT
#

:white_check_mark: Restarted deployment bot in namespace default.

patent pivot
#

uhhhhhh huuuuuuuh

vale ibex
#

ok, anyone have the thing that this PR was fixing?

vocal wolf
#

joe we borked github

vale ibex
#

lets see if the change is actually in there

magic arch
#

Yeah check bot commands in the test server

vale ibex
#

!e ```py
print("@\u0300" * 160 + "`\u0300`` <\u0300@196664644113268736>")

stable mountainBOT
#

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

@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@̀@@@@@@@@@@@``` @vocal wolf
vale ibex
#

did that ping you xith?

vocal wolf
#

yes

magic arch
#

Well that’s not good 😂

vale ibex
#

Ah, yea, bot is on 3824ddb

#

of course, since new one hasn't been built

patent pivot
#

wait what how did that ping xith

vale ibex
#

since the build action didn't run

magic arch
patent pivot
#

xith did not run the command

#

even before the change, that should not happen

#

it's role pings, not member of role pings

vale ibex
#

by default member pings are true, if not set

magic arch
#

It wasn’t limited to the person running yet, that’s what this PR is

vale ibex
#

in allowed_mentions

patent pivot
#

ahhhh

magic arch
#

Previously just limited to mod roles and technically any users, now it’s just the one user

vale ibex
patent pivot
#

uhhhhh

vale ibex
#

IG the other option is to wait, or manually build and push to ghcr

patent pivot
#

yea 1 sec

#

pushed

vale ibex
#

sick

patent pivot
#

oh that merged it

#

wtf lol

vale ibex
#

yea no clue lmfao

patent pivot
#

lmfaoooo it says i merged???

#

actually wild

vale ibex
#

lol

#

I might try to repo this

magic arch
#

Today I broke GitHub with a simple PR

summer garden
gritty wind
#

AOC_MONTH

summer garden
#

unless this check was added some time when I wasn't paying attention because I see
bot.exts.events.advent_of_code._cog | WARNING | Could not find the AoC completionist role; cancelling completionist task.

#

Unless this is for something else

#

I'll give that a go

#

mm I don't see it anymore

fallen patrol
#

does the docker compose file for site make the database have a volume so if the container is removed the database still has persistence

clever wraith
#

hello

reef tinsel
#

The epoch command I did essentially nothing 🙂 - the credit is all bones’!

austere hornet
#

So what you could have done if you didn't want to work on the issue anymore is unassign yourself, that way you won't be mentioned in #changelog

sleek steppe
#

They were mentioned because they committed multiple times in the PR

reef tinsel
#

I did commit - but they were both very slight if I remember

summer garden
#

we had some good discussions

#

Nobody said they have to be coding contributions

#

haha also I was going to apologize for polluting your repo with random prs. I couldn't figure out how to push directly to yours 🤣

reef tinsel
#

True

#

Lol

#

Dw

#

You should be able to do git push upstream branch

#

Not 100% sure tho

#

Aah and upstream might point to pydis’ copy anyway

vale ibex
#

Fairly small fix to AoC join check sir-lancebot#1008

dusky shoreBOT
short snow
#

@brisk brook here, re your comment on modpings pr

brisk brook
#

Ah, right.

placid ermine
#

Hello

#

I have thought of a fix for latex

#

will open issue

#

soon™️

simple slate
#

hi can i ask a doubt related to github ( this is a little bit of track not related to our repos)

simple slate
#

can any one explain me how to solve this

tawdry vapor
magic arch
#

Interesting edge case for code block detection in @stable mountain, it thinks you're using the wrong character for a block because of a docstring

#

For example, this:

def test():
"""
description here
"""

print(test())

fallen patrol
magic arch
#

Oh weird, well here's the actual example that I first noticed triggering it:

def is_even_with_return(i):
"""
input: i , a positive int
return true if i is true , otherwise return false

"""

print("with return")
remainder = i % 2
return remainder == 0

is_even_with_return(3)
print( is_even_with_return(3))

fallen patrol
#

okay, now i see it

magic arch
#

Yeah I swear I was able to get it with that smaller example, maybe I was just too tired to tell 😂

#

Anyways not sure if this is even something possible to fix or worth it, just a little thing I noticed in pygen last night

static canyon
#

I suppose a partial fix would be to see if it's indented

#

And if it is, then it's a docstring

#

The only thing is you can have non-indented docstrings (e.g. module docstrings)

#

But at least it would happen less

placid ermine
#

sir-lancebot#1010 is ready for review (i think)

dusky shoreBOT
fallen patrol
#

i was thinking, since there's two regexes IIRC is to match both and check if the unfenced regex match is longer than the fenced match

cold island
placid ermine
#

i wasnt aware of that

cold island
#

Does it work if you try to render something like a matrix with lots of divisions? not sure if you have a way to replicate the memory constraint

placid ermine
#

sigh
matplotlib doesnt recognise \begin

gritty wind
#

The bigger problem we had was creation not clean up

#

Can you put mem limits on asyncio processes

brisk brook
#

...no unless it runs in snekbox jail

#

I think?'

patent pivot
#

any reviewers in chat peepoArrive

gritty wind
#

Latex may just be doomed to fail, and maybe that's fine

fallen patrol
gritty wind
#

nO

patent pivot
#

lol

#

aren't we gonna end up with interbot for bk anyway

#

though i suppose we do not want to put snekbox and lance on that same relay

gritty wind
#

It’s not even about interbot

#

If we wanted snekbox on lance it’s about 1000x easier to do that

#

But we don’t want to add more to lance

patent pivot
#

yea

magic arch
vale ibex
#

yea, the AoC cookies have expired

#

we'll sort it

placid ermine
gritty wind
#

If you want to write a wrapper and can find a good api, go for it

placid ermine
#

don’t have a real use on the server
i mean, i've definitely noticed more than one occasion where someone would go to the math server to get the bots there to render latex and then copy/paste that image for a conversation here

#

and well

#

would using a web api be all that different from what i currently have

#

not like i'm doing the typesetting manually in either case

gritty wind
#

I mean, I assume the API will have it's own resource limits so our bots wouldn't OOM

cold island
#

It'd be nice if matplotlib could tell you in advance what array size it's going to try to allocate

#

A mitigating step could be to limit the length of the input, or parse the input into a tree and limit its depth

gritty wind
#

It'd probably have to be a combination of both, since you can have very small, memory consuming complex input, and very long, memory consuming simple input

#

When I was looking into it last, determining all that info before running seemed very difficult, but I have minimal experience in the world of latex. My research showed that enforcing limits its easier than testing though

fervent sage
#

If I could provide a latex rendering API would we be able to use it? I want to run one for the infrastructure management challenges of running services and to learn shit like nomad and terraform, so I'd be happy to host something useful rather than just another useless service only I use

tawdry vapor
#

Long ago I did suggest using an actual latex install

#

Apparently it's possible to make your own minimal distribution

#

Though some do exist as well

gritty wind
fallen patrol
#

oh black knight

#

moderation tooling between the two bots

#

neat

patent pivot
fallen patrol
#

smh @placid ermine sir-lancebot#1009 was never approved

dusky shoreBOT
austere hornet
#

Keep in mind that hsp is a mod and I'm pretty sure mods are allowed to make PRs without an approved issue but if I'm wrong please correct me

tawdry vapor
#

No one is exempt from our wrath

magic arch
#

except like tiny fixes, mostly if they're brought up here first and are like one line of code

austere hornet
#

Ah I see

#

Ok then

tawdry vapor
#

I effectively approved it anyway. Maybe I wasn't formal or explicit enough about it

austere hornet
#

Maybe

fallen patrol
dusky shoreBOT
fallen patrol
#

i've been waiting for explicit, but now i'm not sure if it was or not

tawdry vapor
#

Sure if you're not already working on too many other things

#

Well it was approved

#

You asked but sort of got ignored

stable mountainBOT
#
Can do!

Your reminder will arrive on <t:1641869659:F>!

placid ermine
fallen patrol
#

true

#

!remind edit duration 3891 30M

stable mountainBOT
#
Sure thing!

That reminder has been edited successfully!

fallen patrol
#

I think I touched that within 2 seconds of when it was gonna go off

stable mountainBOT
short snow
#

who is rf20008?

gritty wind
#

(And a damn good one at that)

vale ibex
#

huh re-requesting my review on bot#1721 removed Akarys's requested review somehow

dusky shoreBOT
austere hornet
#

I've seen that username on GH but doesn't seem like it's anyone on staff

short snow
#

I am just asking in general

short snow
#

and that was the first edit since ak's leave

#

sir-lancebot#745 is needing one core-dev approval, would be awesome if someone can review it :D

dusky shoreBOT
dim pelican
#

Hey all, random issue I'm getting running locally. I've tried to pull from upstream and rebuilt docker with docker-compose up --build but I'm getting this message on a loop:

Traceback (most recent call last):
  File "/usr/local/lib/python3.9/site-packages/discord/ext/commands/bot.py", line 672, in _load_from_module_spec
    setup(self)
  File "/bot/bot/exts/utilities/realpython.py", line 100, in setup
    bot.add_cog(RealPython(bot))
  File "/bot/bot/bot.py", line 81, in add_cog
    super().add_cog(cog)
  File "/usr/local/lib/python3.9/site-packages/discord/ext/commands/bot.py", line 551, in add_cog
    raise discord.ClientException(f'Cog named {cog_name!r} already loaded')
discord.errors.ClientException: Cog named 'RealPython' already loaded

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

Traceback (most recent call last):
  File "/usr/local/lib/python3.9/runpy.py", line 197, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/local/lib/python3.9/runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "/bot/bot/__main__.py", line 13, in <module>
    bot.load_extension(ext)
  File "/usr/local/lib/python3.9/site-packages/discord/ext/commands/bot.py", line 732, in load_extension
    self._load_from_module_spec(spec, name)
  File "/usr/local/lib/python3.9/site-packages/discord/ext/commands/bot.py", line 677, in _load_from_module_spec
    raise errors.ExtensionFailed(key, e) from e
discord.ext.commands.errors.ExtensionFailed: Extension 'bot.exts.utilities.realpython' raised an error: ClientException: Cog named 'RealPython' already loaded
sir-lancebot exited with code 1
tawdry vapor
#

Does git status list any untracked files?

dim pelican
#

Looks like I had two realpython.py files

fallen patrol
#

bot#2046, simple pr, explained in detail, the diff may look intimidating but its just a copy paste of code

dusky shoreBOT
vale ibex
#

Very small fix for something we found in #aoc-bot-commands sir-lancebot#1011 would appreciate a quick review

dusky shoreBOT
molten perch
#

Done, at least placement_board is used for something other than the actual placement command 🙃

vale ibex
#

hah yea, it was a very nice format for what I needed

fallen patrol
#

@static canyon I didn't notice the updated review on bot#2017, I've updated it..
and since I also just noticed the "p: high" here's an update message 😅

dusky shoreBOT
simple slate
#

can some one help my why is this not working

#

i am trying to print a url on this command !

#

and when i am keeping other constaints optional the command is not responding

#

no response over here

short snow
#

amount is never None, you have set to 5 as default

#

oh in the second screenshot you keep it None

#

uhh

#

amount spelling in the if statement

#

which editor is that? it should have underlined it with red

simple slate
#

vscode

short snow
#

you have configured the python extension and venv?

stable mountainBOT
#
It has arrived!

Here's your reminder: @molten perch seems like sir-lancebot#743 and sir-lancebot#968 are about the same, I'd like to work on aspects of 968, but some of it can be removed and return back to 743 if you are wanting to do them

If you aren't, I can.
[Jump back to when you created the reminder](#dev-contrib message)

fallen patrol
#

welp 778 is still not merged so

fallen patrol
stable mountainBOT
#
I got you.

Your reminder will arrive on <t:1644732264:F>!

stable mountainBOT
#

Hey @clever wraith!

It looks like you tried to attach file type(s) that we do not allow (.exe). We currently allow the following file types: .gif, .jpg, .jpeg, .mov, .mp4, .mpg, .png, .mp3, .wav, .ogg, .webm, .webp, .flac, .m4a, .csv, .json.

Feel free to ask in #community-meta if you think this is a mistake.

static canyon
stable mountainBOT
#
You got it!

Your reminder will arrive on <t:1642080464:F>!

fallen patrol
#

!remind 5h tell tizzy hope their interview went well

static canyon
#

😄 🤞

green oriole
#

@static canyon good luck! I'm sure you'll nail it

static canyon
#

30M to go 🤞

short snow
#

good luck tizzy!

dim pelican
static canyon
#

@fallen patrol I'd like to get bot#1924 resolved soonish (say, by end of January / mid Feb). Do you think you'll be able to do that, or would you like me to look into it a bit and help out?

dusky shoreBOT
stable mountainBOT
short snow
#

also tizzy, i would love a rereview on modpings enhancement pr

#

and how did the interview go?

cursive relic
#

I have nearly everything set up after a while for pixels but I still don't understand what kind of post request am I supposed to pass into /authenticate endpoint?

vale ibex
#

/authorize -> /callback will issue a refresh token

#

You then send your refresh token to /authenticate to request an access token

#

Which is then used with the other endpoints

cursive relic
#

So I have to pass some kind of headers to /authenticate

vale ibex
#

Not headers, but in the body of the post request

cursive relic
vale ibex
#

Yea, that looks about right

cursive relic
#

ooh now I got it working

#

I kept passing headers ;-; and that's why it did not work

static canyon
static canyon
short snow
#

bot#2001

dusky shoreBOT
static canyon
#

!remind 1h Re-review bot#2001 & bot#2017 after dinner

stable mountainBOT
#
Absolutely!

Your reminder will arrive on <t:1642098110:F>!

rapid swallow
stable mountainBOT
static canyon
stable mountainBOT
#
Sure.

Your reminder will arrive on <t:1642101760:F>!

stable mountainBOT
tranquil karma
#

hello guys sorry to interrupt, just wanted to ask, if i wanna get into game dev, should i go for C# or python (pygame), or C++

gritty wind
fallen patrol
#

disnakedev/disnake#224

dusky shoreBOT
fallen patrol
#

!remind 4d look into why this has the draft emoji and not the merged emoji

stable mountainBOT
#
Absolutely!

Your reminder will arrive on <t:1642452569:F>!

austere hornet
fallen patrol
#

doesn't impact that

#

.src gh

#

...

#

there's code somewhere on github

gritty wind
#

Nah it’s the GH api being shit

#

It does in fact say draft

stable mountainBOT
#

bot/exts/utilities/issues.py lines 142 to 150

if pull_data["draft"]:
    emoji = Emojis.pull_request_draft
elif pull_data["state"] == "open":
    emoji = Emojis.pull_request_open
# When 'merged_at' is not None, this means that the state of the PR is merged
elif pull_data["merged_at"] is not None:
    emoji = Emojis.pull_request_merged
else:
    emoji = Emojis.pull_request_closed```
sleek steppe
#

might need to move that first if condition below open/merged

fallen patrol
#

lets... see

#

api also returns state "closed"

gritty wind
#

I don’t think you can merge drafts can you

fallen patrol
#

and it returns a merged_at

fallen patrol
gritty wind
#

Right

fallen patrol
#

the api is returning a merged_at and closed_at, and state for the api request

#

although hmm

gritty wind
#

Yes

fallen patrol
#

i see it now

gritty wind
#

It doesn’t say merged or just closed does it

fallen patrol
#

it does

#

& the api returns null for merged_at on prs that haven't actually been merged

#

aight I'll make a change to my bot which implements this feature and add it upstream once sir-lancebot#778 is actually merged 👀

dusky shoreBOT
fallen patrol
#

thanks scale

sleek steppe
#

since that linked PR already changes some parts of it, can't it fix the check as well?

fallen patrol
#

no

#

I talked with chris about this, and have a seperate list of changes to make to the github cog

#

that one should just be merged, its been open for 6 months

dusky shoreBOT
fallen patrol
#

sir-lancebot#968 iirc

dusky shoreBOT
sleek steppe
#

Ah I see

sleek steppe
austere hornet
static canyon
stable mountainBOT
#
You got it!

Your reminder will arrive on <t:1642169683:F>!

simple slate
#

i just noticed that one of my PR on the site repo is still not complete ! issue no #639 PR no #640 , last few days i also reffered realpython web page over there also ig they have updated this change https://realpython.com/how-to-make-a-discord-bot-python/ under Adding a Bot to a Guild section

In this step-by-step tutorial, you'll learn how to make a Discord bot in Python and interact with several APIs. You'll learn how to handle events, accept commands, validate and verify input, and all the basics that can help you create useful and exciting automations!

fallen patrol
static canyon
#

!remind 6h maybe able to

stable mountainBOT
#
Of course!

Your reminder will arrive on <t:1642168349:F>!

stable mountainBOT
dim pelican
stable mountainBOT
static canyon
#

@short snow have just reviewed bot#2001 👍

dusky shoreBOT
static canyon
#

@fallen patrol bot#2017 looks good to me, but don't want to approve until I get around to testing

dusky shoreBOT
fallen patrol
#

yes github exactly what I wanted to press

fallen patrol
#

lol @gritty wind I wrote my comment b4 you replied

#

but didn't submit it

gritty wind
#

@timid sentinel at this point, I’m more or less convinced the latex command in its current form is doomed to fail. I’m going to close the issue tomorrow if no one has any further comments, and we’ll leave it closed until someone finds an api that just handles this for us

#

I’m not sure who the PR author is on discord

vocal prairie
#

ShakyaMajumdar is hsp btw

gritty wind
#

Thx

#

Cc @placid ermine

timid sentinel
#

That is weird. It doesn't seem to actually use much memory, but still seems to want around 1gb to run (at which point it can run pretty much anything). Almost feels as if it checks it has a certain amount of memory before doing anything, but not sure how that would be the case

gritty wind
#

@ 1 gb it’s 100% a no-go

#

We’d saturate our node lmao

#

But yeah, similar experience on my branch

#

It’ll try to claim a ton of mem to import matplotlib

#

And resources was breaking for some reason and propagating the OOM outside the process

#

The branch was scrapped, but kept for reference

timid sentinel
#

ah yeah it does seem to be the import

#

idek

#

doesn't seem like fun though

gritty wind
#

I suppose you could start patching matplotlib to not claim the mem on import but at that point

#

God

timid sentinel
#

AHA I think i've managed to patch matplotlib to not claim the mem on import

#

lmao

#

still seems to need around 200mb though

gritty wind
#

Do you think this is worth pursuing for this feature over an APi

timid sentinel
#

well given the PR already exists I thought it was worth looking into. Adding

import os
os.environ["OMP_NUM_THREADS"] = "1"

means a 200MB mem rlimit would allow it to work (at least for me). If that's too much we'd probably just want to use some api, yeah

fallen patrol
#

are you

#

its been approved

#

all checks are passing

#

but kutiekat did not hit the merge button when she approved 🥲

#

this is extremely disappointing to me as i didn't notice for 2 weeks and hoped it would have been here a little sooner during aoc

fallen patrol
#

oh well in that case

patent pivot
#

don't name staffers like that please

#

not a fan of it

fallen patrol
hoary haven
thorny obsidian
patent pivot
#

not all staff have write access to the main branch

#

If your repository requires approving reviews from people with write or admin permissions, then any approvals from people with these permissions are denoted with a green check mark, and approvals from people without these permissions have a gray check mark. Approvals with a gray check mark do not affect whether the pull request can be merged.

#

all staff reviews will show as green, a green review does not necessarily mean they can merge a given PR, unless there is an enabled auto-merge, in which case the core dev who triggered the auto-merge will perform the merge action

tawdry vapor
timid sentinel
#

Yeah that could probably work, although I'm not sure how large a minimal latex installation is, could be a bit heavy to bundle along with sir-lancebot. Could probably make it optional or something though, not too sure how these things work

tawdry vapor
#

IIRC it's like 80 megabytes

#

And yes, it can be optional. It'd just be installed in the Docker container.

#

If people don't want to use Docker, then they don't get the latex command, and that's not a big loss.

timid sentinel
#

Ah that would probably work pretty well then

summer garden
#

how does the @everyone mention filter work? Surely the message is only deleted after the ping is sent

vale ibex
#

Users don't have perms to ping everyone or here

#

We delete on top of that to avoid the conversations that happen afterwards

summer garden
#

Oh yes, of course. I somehow forgot about the whole permissions thing

static canyon
#

@fallen patrol I've been working on implementing bot#1924 with regex and have had a fair amount of success

dusky shoreBOT
static canyon
#

I think I've got almost everything but timezone support done

#

Currently the following works:```
year/month/day hour:minute:second

year-month-day hour:minute:second

year-month-day hour.minute:second

all of above without second

all of above without date (when time has passed today, does specified time tomorrow)

all of above with AM/PM specified```

#

Can you give me write access to the branch on your repo so that I can commit? Email is tizzysaurus@gmail.com

fallen patrol
#

sir-lancebot#969 could a core dev merge this? it's approved, checks are passing, no review is necessary. just needs a lil merge commit made

fallen patrol
#

ty!

placid ermine
short snow
static canyon
fallen patrol
#

oh i was asleep

static canyon
#

No worries lol

#

Whenever you're free to add me I'll commit

fallen patrol
#

ikr? me sleeping at night?

static canyon
#

Thanks

#

So if I want to push to this, do I need to clone it locally? @fallen patrol

fallen patrol
#

should just be able to add me as a remote

static canyon
#

Hmm

#

What does that mean?

fallen patrol
#

like git remote

static canyon
#

idk what that is

fallen patrol
#

🥲

#

do you use the github cli?

static canyon
#

Nope

fallen patrol
#

kk won't go that route

static canyon
#

I just use PyCharm's git tooling

fallen patrol
#

lmao i'm so bad at git's cli that i'd rather edit the git config

#

I either use the gh cli utility or would add this to my git config file

[remote "arl"]
    url = https://github.com/onerandomusername/bot.git
    fetch = +refs/heads/fix-issue-1924:refs/remotes/origin/fix-issue-1924
#

i don't know how to do it in pycharm ui

static canyon
#

What file do I put that in?

#

.gitattributes? @fallen patrol

fallen patrol
#

git config -e

#

which will open an editor of the git config

#

oH

static canyon
#

Yeah, that works

fallen patrol
#

make sure that you don't call it remote "origin"

#

since you already have that

#

I updated the above to say "arl"

static canyon
#

Right yeah

#

Thanks

#
[core]
    repositoryformatversion = 0
    filemode = false
    bare = false
    logallrefupdates = true
    symlinks = false
    ignorecase = true
[remote "arl"]
    url = https://github.com/onerandomusername/bot.git
    fetch = +refs/heads/fix-issue-1924:refs/remotes/origin/fix-issue-1924
[remote "origin"]
    url = git@github.com:python-discord/bot.git
    fetch = +refs/heads/*:refs/remotes/origin/*
[branch "main"]
    remote = origin
    merge = refs/heads/main
[branch "incident-archive-msg-improvements"]
    remote = origin
    merge = refs/heads/incident-archive-msg-improvements
[branch "fix-bot-2034"]
    remote = origin
    merge = refs/heads/fix-bot-2034
```so this?
#

@fallen patrol

fallen patrol
#

yeah

#

then git pull

static canyon
#

Okay, now what?

#

Aight

#

Says already up to date

short snow
#

You can also do git remote add arl https://github.com/onerandomusername/bot.git

#

inside your bot clone DIR

static canyon
#

I've already done the git config thing

short snow
#

then pull there branch as git pull arl branch-name

static canyon
#

But gtk that's an option

static canyon
short snow
#

yeah, okay 👍

#

np

static canyon
#

Will it be under the remote ones?

short snow
#

yeah

#

local branches are what you have pulled locally

#

once you pull the remote branch of arl's repo

#

it would be showed in local branches

#

found it?

#

or if you are using pycharm, you can go to git tab on top bar and you will see an option named remotes

#

you can directly add the remote name and url in that

static canyon
short snow
#

cool np

static canyon
#

Errr

#

I made a boo boo

#

How do I undo a pull

#

I pulled into a PR instead of main

#

So I've now got 19 files with a diff

short snow
#

is the PR uptodate globally?

fallen patrol
#

git log ; find the commit hash that you want to reset the branch to ; git reset --hard <hash>

static canyon
#

git reset --hard HEAD~1 I think should work?

fallen patrol
#

probably

#

wait

short snow
#

depends how many commits are pulled

fallen patrol
#

git checkout <my-branch>

#

after you fix the above

#

don't pull it into main

fallen patrol
static canyon
#

Eh idk what I've done

fallen patrol
#

pull is fetch + merge

static canyon
#

git log --oneline says I'm on the head but I've got loads of unstaged changes

short snow
#

log only shows the commits, if you have unstaged it won't show there

#

you could just do git reset --hard HEAD

static canyon
#

Yep

#

That's what I was just gonna say

#

I think I've got it sorted

short snow
#

cool 👍

static canyon
#

Thanks guys 👍

#

Just realised this code is in no state to be pushed because it's like not even in dpy format or anything, so I should probably change that first

short snow
#

btw, if you wanna use the pycharm UI to fetch and checkout to the branch, you could just find the branch in branches tab on bottom right corner, press the arrow and checkout, ig you already know this

static canyon
#

Yeah

#

I'm familiar with that part

static canyon
#

Btw @short snow added some more details to one of my review points on bot#2001 along with a suggestion regex.

Most of the review is small nitpicks that aren't overly important, so feel free to ignore the ones you don't think are necessary

dusky shoreBOT
short snow
clever wraith
stable mountainBOT
#

bot/exts/moderation/verification.py line 84

if member.pending:```
timid sentinel
stable mountainBOT
#

bot/exts/moderation/verification.py lines 80 to 83

# If the user has the pending flag set, they will be using the alternate
# gate and will not need a welcome DM with verification instructions.
# We will send them an alternate DM once they verify with the welcome
# video when they pass the gate.```
fallen patrol
#

now, every member that joins is set to true IIRC

short snow
#

Wookie include this also in your PR review drive lol sir-lancebot#745, needs one more approval

dusky shoreBOT
timid sentinel
#

Ah, I might be able to do it today, if not I'll try and do it some point this week

fallen patrol
#

could someone merge sir-lancebot#969?

fallen patrol
#

it's approved, reviewed, ready to go

#

just needs core dev to boosh that merge button

static canyon
#

^ volcy has merged for you

#

!remind 6d bot#2031

stable mountainBOT
#
I'll allow it.

Your reminder will arrive on <t:1642881796:F>!

dusky shoreBOT
hoary haven
#

i am trying to set up my own test server for bot, if i have any feedback or questions i can just drop them here?

my previous run-through of the setup guide was using the staff test server, so this time i'll be doing it using the server template.

#

to start with, i wasn't sure what to put here in the config.yml

#

the server template just gave an empty NEWS category

#

and what to put here for the webhook IDs?

gritty wind
#

For news, you can just leave it empty

#

why do you have missing symbols

#

You need to create the webhooks yourself, but you only need to create one

hoary haven
gritty wind
#

And yes, you can ask here

#

ah, right

fallen patrol
#

(if you don't wanna answer dont)

hoary haven
#

plenty (maybe even a majority?) of our contributors aren't staff, and i only became staff a couple months ago. wanted to see what it's like for non-staff

#

also i like using the ! prefix

#

also what if i somehow completely fucked up the staff test server? blobgrimacing that would be not fun

thorny obsidian
thorny obsidian
hoary haven
#

i used the server template on the contributing guide, so it looks nearly? identical to the staff one

cold island
tawdry vapor
hoary haven
#

lemon_sweat ok good

#

i didn't finish so will resume setup tomorrow

#

also why is yaml such a strange format?

tawdry vapor
#

I don't know. It's a monstrosity in its full form.

remote wigeon
#

still better than toml

#

or iml

tawdry vapor
#

I disagree. TOML is nice when something simple is needed.

remote wigeon
#

it quickly gets out of hand

#

yaml scales pretty well even for large configs

#

though imo hcl is still my fav

fervent sage
#

hcl my beloved

cursive relic
#

is this supposed to happen?

gritty wind
#

the link and name are backward

#

where is this

cursive relic
gritty wind
#

A recent PR flipped it

#

Would you like to PR a fix?

cursive relic
#

I'm just going to school in ~5 minutes

#

I can try to find a moment to write a pr in there.

gritty wind
#

There is no rush

#

PR it when you have time, and feel free to ping me

cursive relic
#

👍 .

#

mind to link me the file where that message is being sent

stable mountainBOT
#

bot/exts/filters/antimalware.py line 22

f"Please use our [{URLs.site_schema}{URLs.site_paste}](paste bin) instead."```
cursive relic
#

and it's supposed to be (link)[text] instead, right?

gritty wind
#

it's [name](link)

stable mountainBOT
cursive relic
#

ooh right

#

When ever I have time today I'll open the issue and pr

gritty wind
#

Just PR

cursive relic
#

oh ok

cursive relic
cursive relic
#

good, I'll try to write some kind of commit message and pr message for it

cursive relic
short snow
#

yeah

#

"Fix pastebin hyperlink to use correct markdown syntax" could be good

#

also don't bike-shed upon commit messages a lot, think once, if it fits the rule and is understandable, commit it

cursive relic
#

The current commit message looks like this ```
Fix pastebin hyperlink to use correct markdown syntax

Fixed format from [link](text) to [text](link) so that the link will
be formatted as it should be.

gritty wind
#

Seems good

cursive relic
#

I had to create a new branch to commit the changes, right instead of the main branch

gritty wind
#

Yeah

cursive relic
#

what should it be called as there is no issue number I can link to it

gritty wind
#

That's fine, you don't need to name your branches after issues

#

the name is mostly meaningless, you could try something like fix-hyperlink

cursive relic
#

that seems good

#

and done

fallen patrol
#

smh

#

I actually learned that if you use / in a name you can't make a branch name of only the part at the beginning

#

which makes sense

gritty wind
#

probably why people use their own names

fallen patrol
#

yeah

gritty wind
#

but, this isn't on the main repo

#

it's a fork

#

go wild

fallen patrol
#

just please don't use whatever the default branch is as your pr branch

gritty wind
#

What? Merging main into main isn't hip anymore

fallen patrol
#

Best is merging main into master :3

trim cradle
timid sentinel
#

botcore is heeeeere

hoary haven
#

woo

sleek steppe
#

Need some more reviews for bot#1602, thanks!

dusky shoreBOT
brazen charm
stable mountainBOT
#

bot/exts/utils/snekbox.py lines 91 to 100

@staticmethod
def get_results_message(results: dict) -> Tuple[str, str]:
    """Return a user-friendly message and error corresponding to the process's return code."""
    stdout, returncode = results["stdout"], results["returncode"]
    msg = f"Your eval job has completed with return code {returncode}"
    error = ""

    if returncode is None:
        msg = "Your eval job has failed"
        error = stdout.strip()```
stable mountainBOT
#

snekbox/nsjail.py line 180

return CompletedProcess(args, None, "ValueError: embedded null byte", None)```
vale ibex
brazen charm
#

ah didn't notice that one

vale ibex
stable mountainBOT
#

snekbox/nsjail.py lines 184 to 190

except UnicodeDecodeError:
    return CompletedProcess(
        args,
        None,
        "UnicodeDecodeError: invalid Unicode in output pipe",
        None,
    )```
hoary haven
#

this happened in a modmail thread

#

the reminder didn't go off?

cold island
#

I think there's a PR from scal to deal with reminder issues

placid ermine
#

the one i was looking at only does pdf

dim pelican
placid ermine
opaque star
#

Are there any plans to move @stable mountain over to slash commands?

thorny obsidian
#

But majority of commands will likely not migrate to slash commands

fallen patrol
thorny obsidian
#

No. Most likely moving to one of the maintained forks.

simple slate
pallid mulch
#

it hasn't got any traffic in 28 days

#

same for site#482 although I can understand this one more

dusky shoreBOT
pallid mulch
#

well I'd like to get all the pydis stuff out of the way, so if someone can look at site#624 I'd appreciate it

dusky shoreBOT
molten perch
pallid mulch
#

I assumed

#

what about 624

#

it is a really simple PR and has been stale for like a month

molten perch
#

Indeed, but as of now, there is nothing more to add. When the bot side implementation is done, (or at least partially) it will be continued. (I'm planning to do so)

pallid mulch
#

624 is a content update though

#

totally different from the new filter schema

molten perch
#

I thought you were talking about 482. 😅 Can't read.

patent pivot
patent pivot
pallid mulch
#

Yes, that's why I'm saying it has been going stale :P

patent pivot
#

Right, sure, but it's stale waiting for updates from the PR author

#

So we're probably not going to do anything with it until review comments are addressed

pallid mulch
#

poke poke @hoary haven

placid ermine
#

poke poke bot#2039

dusky shoreBOT
placid ermine
#

also @timid sentinel i think your "requested changes" review is blocking checks from running on the rewrite (sir-lancebot#1010)

dusky shoreBOT
vale ibex
#

It'll be the merge conflicts blocking the actions

placid ermine
#

oh

#

fuckin poetry.lock

#

how the fuck

vale ibex
#

dependabot bumped pillow up due to a vuln

#

I usually just git rebase main choose the version in main as correct, then relock, commit and squash that commit to the commit that originally edited poetry

placid ermine
#
<<<<<<< HEAD
content-hash = "6e2fd70bb8b92763ee3bd93f5eef323a96179e8e04de4d6c2ace5f6fa3a4042d"
=======
content-hash = "e824a5fa909d43e861478178ad7e77ee04be05a60cd3028bda8bd4754c848616"
>>>>>>> dc8c63fa92fbf8b74aafb17b5f58d67e079633b4

what am i supposed to yeet and what am i supposed to keep pithink

vale ibex
#

keep which ever hash is the one from main

#

you could git rebase main --theirs poetry.lock

placid ermine
#

error: unknown option `theirs'

vale ibex
#

oh, is that not an option on a rebase

#

lemme look

#

Ah, its --theirs on git merge aparently

#

it's -Xtheirs on rebase

#

but that might apply to the whole rebase, rather than just the poetry lock

#

if you do a plain git rebase main and then get to the conflicting part with poetry.lock

#

you can choose all current changes, rather than incoming

#

that will trash all of your changes on poetry lock

short snow
#

you can just copy paste the poetry.lock from main

#

its much simpler

#

mpl isn't needed now right?

placid ermine
#

it is not

hoary haven
#

i need to set up site on my work machine so i can actually view the effects of my PR and see if the page is still cohesive as a whole, as you can lose sight of that when reading the same paragraphs over and over again. i also converted this PR to a draft because while it's important, it's not urgent and i wanted to make changes that would make sense and not have to be changed again soon down the line @patent pivot

#

went to tag lauren but she's no longer on the server?

vale ibex
#

Sure, draft PR makes sense for this. You could also close the PR and reopen it in future if you didn't want people to comment on the progress as it's still WIP

#

also, let us know if you need help setting up site.

clever wraith
stable mountainBOT
#

bot/exts/help_channels/_cog.py line 556

async def notify_session_participants(self, message: discord.Message) -> None:```
vale ibex
#

Is this for getting the claimant's original message?

clever wraith
#

yep

vale ibex
#

_caches.question_messages will have the messageID for the original question in each channel

clever wraith
#

ah, and then I can just run a fetch_message, yeah?

vale ibex
#

I'd try a get first, but yea

#

since it's likely to be in the cache if the session is still active

clever wraith
#

ic ic, ty

short snow
#

isn't there a get fetch message utility function?

vale ibex
#

I know there is for members, not sure about messages

#

there might be

short snow
#

whelp yeah, it is for members

clever wraith
#

Is there a high-level abstraction for getting a message from the cache?

#

All I could find was bot._connection._get_message

#

I'll just call the MessageConverter manually

vale ibex
#

Yea that'll work. Or you can discord.utils.get(bot.cached_messages, id=search_id)

#

bot.cached_messages is the list of cached message objects

clever wraith
#

I'll use the message converter since it handles both cases

sleek steppe
#

My PR is close to the bottom so it's easy to miss, but I'm waiting for reviews on bot#1602 😄

dusky shoreBOT
clever wraith
#

For editing the help dm messages after the help channel is closed I'll need to keep track of the message ids, I was thinking of storing userid-messageid

Do I make a new redis cache for that or repurpose the session_participants cache to actually store those messages ids

The only difference is in readability and ease of access I suppose

molten perch
clever wraith
#

session_participants is currently being used to keep track of the members we've already sent the help dm message to

#

That would still be achievable by storing userid-messageid, we'll just have to do some extra parsing to get the userids

molten perch
# clever wraith session_participants is currently being used to keep track of the members we've ...

Yes, but it keeps track of them by using the help channel's id as a key and the user id's as values.
if I understand correctly, you would change this structure to instead of using the help channel's id, it uses the user id as a key and message_id as the value.
I wouldn't remove this structure, otherwise how would unclaming a channel would look like?
(I might have misunderstood your approach though. 😄 )

clever wraith