#dev-contrib
1 messages · Page 100 of 1
Got an issue open for that
hmmm, that is interesting
!pypi jishaku
A discord.py extension including useful tools for bot development and debugging.
hmmmmmm
no experience with osx, but on windows you can just have it check and auto sync
bringing on a dep for utils like that feels a bit off
your internal timing is out of sync with discord's, which leads to oddoties with datetime
usually not noticeable with most datetime ops
but when you work in ms, it matters
I can't confirm if this works, but https://superuser.com/questions/369852/force-date-time-clock-sync
oh, comments say it doesn't
it links to
sudo sntp -sS pool.ntp.org
do at your own risk and all the shebang, but this should be fairly innocuous
have you?
no
giving it more resources is somewhat last resort
we should figure out what is going on first and see if we can mitigate another way
Nah, hoping to finish it up today if I can get a clarification on a comment from Akarys
No worries, situation has been resolved. Take your time
what pr is it?
sir-lancebot#673 I know this won't work
@patent pivot
Here's your reminder: changelog.
[Jump back to when you created the reminder](#dev-contrib message)
!remind 24h changelog doc changes if no one else has
Your reminder will arrive in 1 day!
nice Oh
Ok, so, currently when there's an error in a command you try to time this happens:
however
exams lol
ctx = getattr(ctx, "subcontext", ctx) 
The lancebot int e is what Scale was referring to. I don't know what number it is
yes, ik
it was your pr so i thought you would know
anyways, found it and submitted my review
I linked it though lol
A duplicate review?
i learned a bit more on how to use github*
suggested changes > reviewed
because i did suggest changes in the first one
just not well.…
Oh, I already made the fix locally. I don't think the duplicate suggestion was necessary
@vale ibex
Here's your reminder: try again <[#dev-contrib message](/guild/267624335836053506/channel/635950537262759947/)>.
[Jump back to when you created the reminder](#dev-contrib message)
So pillow-simd doesn't seem like an option as far as I can see rn
had to install gcc and build tools on the docker container, since there doesn't seem to be a wheel around
Docker isn't being friendly https://paste.pythondiscord.com/amiyejakit.less
I have sir-lancebot running but can't stop it 😩
a wheel is a pre-built python dependancy
wait nvm it just stopped 
ahh that sounds about right
yeah
hm
wait
why no wheels
oh
because they just don't have wheels lol
yea lol
Anyways, I'm going to leave that for another day, so that this pfp PR actually gets merged this year
I think after this PR, we should refactor it to be a generic folder for image processing cogs
Don't underestimate procrastination lol
there are some very old PR's that haven't been merged yet lol
sir-lancebot#677 will someone approve?
uh
Someone needs to make a PR for that lol (I meant the repo#num thingy)
done, I'm going to add a comment with checkboxes of functionality so we can add things gradually
done
yay
i probably won't look at it anymore until at least start on it next week, this week is a once in a lifetime special to me
🙂 i've had my bone marrow transplant for one year now
and been cancer free for also about that long
.ping @patent pivot
would an issue to port over most of the @stable mountain or create a new ping command for @dusky shore likely be okayed as well?
just realized its non-existent
hmmmmm
don't think we need it
ping has a genuine use on python for checking the status of services, not just as a generic ping pong
but we could use it anyways, ya?
!otn a generic-ping-pong
:ok_hand: Added generic-ping-pong to the names list.
Command processing time
69.230 ms
Discord API latency
111.634 ms
it would be nice to see those on lancebot as well
it's not necessary, I don't think we should be duplicating that
after all, that's what's on python and that isn't any more than a typical bot
maybe a very generic .ping to "Pong! 🏓" message, but I'd be fairly against anything else
ah, could you explain more in detail why?
because I don't fully understand what part of the replied is useful for @stable mountain which wouldn't be for @dusky shore
it's not that it isn't useful for Lancebot, it's just that it's a duplicated feature
why is that?
we use ping to determine if the site is up, API is responsive, among other things, lancebot doesn't need that functionality because if python reports an error then lancebot is likely susceptible (and lancebot is much less dependent)
@fallen patrol I've specified the issue
which one
colours
ah
colo[u]rs
yeah
(what I'll probably do is code everything as color and then replace it all with colour)
welp
I've split up the features into implementable segments if you want to go through multiple PRs
that will be my last commit
4 PRs sounds like a decent spread of the work, in order I suggested colour information, random colours, conversions and naming
yep
add label 🥺
joe's just fast ¯_(ツ)_/¯
faster than my internet
brb adding it to the discussion
Some of the features would be:
embedding an image of the color using pillow to create it converting the color to other formats using colorsys giving the closest matching name from one of these two lists (xkcd and this one suggested by joe), merged and stored locally.
Embed should include:
The colour itself as both the embed colour and as the thumbnail. Colour conversions (see below). Colour name (see below).
*color
This kind of colour image?
Except with other info, of course.
pretty much that! I'd say thumbnail instead though
!d PIL
one second
Yeah, that would be cleaner.
i'll generate a mock embed
And the embed color should definitely be the color.
yep
lmfao. Joe said this and then instantly my modmail thread closed
that was on a timer lol
Who knows
topic use color
how'd you create that 🥺
ah, i'll dm you
And yes, I'm calling it that just to annoy you.
I'll provide an actual response on the issue but
Okie
could also consider uhhh
this one is better imo
nah its the fields aren't in line anymore which is imo better
I think that's the one to work towards
i really really wish there was a way to have two fields in line
fwiw most of what you just sent is like
late game
late game?
This is cleaner
right, yeah, but it's good to specify anyway
The other one is too wide imo
first i have to process the color and everything and then make the embed which is like
really easy to change
added to issue
the reason I used function notation is because it's fairly standard syntax for CSS
I think 2x2 is better, as long as you can limit width to 2 units instead of 3
Then full function notation would be fine
That doesn't work very well
Why
On pc yes, but on mobile there's a big gap
#1
Yeah because there isn't any inline on mobile
#3
Bikeshedding occurs when a development team spends a disproportionate amount of time and effort on a trivial or unimportant detail of a system, such as the color of a bikeshed
Eh, this is fun
But this is still fun
@patent pivot Do you have an example of 2x2, just to see?
how do I do 2x2
its impossible
yeah
Wait really? I swear I've seen it before.
Wait, you can add fake fields.
!charinfo \u200b
You are not allowed to use that command here. Please use the #bot-commands channel instead.
zero width space
Mobile has no inline...so it'll just be a blank field. So it's gonna look bad
oh shit i just realized
@patent pivot …did you mention anything about redis catching because its color generation
caching should probably be in the spec
should be low resource enough to be fine, we can think about that later
ah
redis will not cache image data though, so we'll have to do a volatile FS cache in that case
well
Oh I see.
i just learned that creating an image of a specific colour is as simple as img = Image.new('RGBA', (300, 300), (228, 150, 150, 255)) so i think caching won't be too much of an issue
yeah, it should be fine
hm
the basis of the color command might be easier than i thought
…
no one saw that did they?
#mod-logs
It shouldn't be too hard.
Conversion might be fun.
But not too bad.
is the algorithm that complex to implement outselves?
No
I looked in the source of the library
It's like
3 lines
But I also thought it was part of the stdlib
!d colorsys
Source code: Lib/colorsys.py
The colorsys module defines bidirectional conversions of color values between colors expressed in the RGB (Red Green Blue) color space used in computer monitors and three other coordinate systems: YIQ, HLS (Hue Lightness Saturation) and HSV (Hue Saturation Value). Coordinates in all of these color spaces are floating point values. In the YIQ space, the Y coordinate is between 0 and 1, but the I and Q coordinates can be positive or negative. In all other spaces, the coordinates are all between 0 and 1.
Yeah
It's part of the stdlib
@patent pivot it's up to you if you want me to copy the relevant methods out of the stdlib
Part of it is, yes
So for that we use stdlib
but I thought you were referencing a package for CMYK
My goal is not to add any dependencies, so whatever is already there is what I'll use
Ah, no
that logic is here
Go for it :P
YAY
it should only be necessary for CMYK
Oh wait, that's in colorsys.
CMYK is not, no
So only one formula?
I guess it's two if you count to and from
RGB --> CMYK --> RGB
It's late. That's my excust
I haven't looked too much into it but I was going to use either hex or rgb to represent every number
Probably rgb
Why rgb instead of rgba?
We don't need to support transparency
Right I was gonna actually use rgba 
We can't
Why?
Our color models, HSV, HSL, RGB and CMYK do not support transparency
Ah
RGBA is not relevant in this conntext
True
Right
Got it
Pillow can just support RGB
I mean, it supports RGBA
It does, but we don't need to use that.
For the initial iteration, we probably need to support only RGB/Hex input, since they are identical and can go straight into Pillow
I would strongly advise breaking it up into separate PRs to avoid huge PRs and long review processes.
Google is giving me conflicting answers on what K is in CMYK.
And how to calculate it.
Is it just 1?
Black
So do I just put 1?
Yeah, but what do I use in calculations?
I linked the SO answer from above which seemed to have a good impl
let me test it
alright so
#C763BD is 199, 99, 189 in RGB and 0, 50, 5, 22 in CMYK
Wait, if that answer exists, there's really no reason for me to write a formula, is there?
In [1]: RGB_SCALE = 255
...: CMYK_SCALE = 100
...:
...:
...: def rgb_to_cmyk(r, g, b):
...: if (r, g, b) == (0, 0, 0):
...: # black
...: return 0, 0, 0, CMYK_SCALE
...:
...: # rgb [0,255] -> cmy [0,1]
...: c = 1 - r / RGB_SCALE
...: m = 1 - g / RGB_SCALE
...: y = 1 - b / RGB_SCALE
...:
...: # extract out k [0, 1]
...: min_cmy = min(c, m, y)
...: c = (c - min_cmy) / (1 - min_cmy)
...: m = (m - min_cmy) / (1 - min_cmy)
...: y = (y - min_cmy) / (1 - min_cmy)
...: k = min_cmy
...:
...: # rescale to the range [0,CMYK_SCALE]
...: return c * CMYK_SCALE, m * CMYK_SCALE, y * CMYK_SCALE, k * CMYK_SCALE
...:
In [2]: rgb_to_cmyk(199, 99, 189)
Out[2]: (0.0, 50.251256281407045, 5.0251256281406995, 21.96078431372549)
other than the rounding required, it got it there
What's all the ...:?
So I don't really need to write a formula.
If a formula already exists.
It just needs to round.
yep
To an int.
So just```py
return round(c * CMYK_SCALE), round(m * CMYK_SCALE), round(y * CMYK_SCALE), round(k * CMYK_SCALE)
With that line, it returns:(0, 50, 5, 22)
Even review my PRs 
Which ones
here they are
Here,
- https://github.com/python-discord/sir-lancebot/pull/673#discussion_r611180044
- https://github.com/python-discord/sir-lancebot/pull/673#discussion_r611180290
These two variables are getting used at multiple places, so would they be constants?
Ah ok
pillow simd didn't complain for me, hmmm
lemme try that in docker
Btw, would anyone like to solve https://github.com/python-discord/sir-lancebot/issues/549 with me?
I'd be willing to.
Can we upgrade to discord.py v1.7.1 too?
I don't have context, but I doubt it's that bad.
apparently @dusky shore keeps dying because of the latex
lol
Just a few times
I think @patent pivot mitigated it somehow
sure, which seasons would you like to handle
Okie
Can I do evergreen then lol
Why not
push changes thro PRs to my fork, do you want to fork my fork, or would like to have push access?
i think i have a fix to the latex consuming too much memory
i can't reproduce the problem on my test bot though
I like the sound of forking your fork better lol
so even you want to help?
Yeah
we coulddd just raise our set resource limits on sir lancebot
although, do you know how much memory the latex command can take?
actually forking sounds not too good I'd like push access
lol, tell me one option.
cc: @vocal prairie
it looks like the memory usage just spikes as soon as there is bad input
it jumped from 63MB to 112MB and then to 159MB
and it doesn't drop down either
for proper input there is hardly any change
hmm
hmm alrighty, that would probably be something you’d want to look into then
I think I should handle this error in the cog itself instead of raising BadArgument
are you storing the image as a image or in bytes?
in bytes for sending, also saving it as a png in cache
if we store it as bytes in cache, would it reduce the space, and is that possible
I don't think that would reduce RAM usage
If I had to guess, the problem is that the figure isn't removed from memory when there is an error
this could be done, if thats the case
try raising multiple errors, and does it increase with every error?
yes
.
I can fork the fork
Option of what?
oh
fork the fork, or get push access to fork
I've seen something about this issue before
Fork the fork.
We're not closing the figure after generating it
perfect
@staticmethod
def _render(text: str, filepath: pathlib.Path) -> BytesIO:
"""
Return the rendered image if latex compiles without errors, otherwise raise a BadArgument Exception.
Saves rendered image to cache.
"""
fig = plt.figure()
rendered_image = BytesIO()
fig.text(0, 1, text, horizontalalignment="left", verticalalignment="top")
try:
plt.savefig(rendered_image, bbox_inches="tight", dpi=600)
except ValueError as e:
raise commands.BadArgument(str(e))
finally:
plt.close(fig)
rendered_image.seek(0)
with open(filepath, "wb") as f:
f.write(rendered_image.getbuffer())
return rendered_image
i tried plt.close(fig)
Did you use finally: to ensure it fires regardless of exception status?
Try firing a gc.collect() after plt.close
You will probably have to import gc in there to do so
For temporary debugging only, this is not a serviceable default fix
nope, still doesn't drop
I would try rewriting it to use the base class method, rather than pyplot, next then
It should be fairly straightforwards since I don't see complicated stuff here
joe said that was a last resort
yeah, that's what i'm thinking as well
I would fire up a fork myself but I am about to be passing out
hopefully that link is helpful
!remindme 12H ^ check on
Your reminder will arrive in 12 hours!
smh chainsaws tho
I have earplugs
lol
A fork? I would personally use a knife.
fire up a fork == flaming pitchforks
What, knives are sharper.
fire up a knife == ???
A knife lit on fire.
will look into it, thank
@sleek steppe lets just use forks then
@short snow - christmas, easter, pride
toxic - evergreen
@vocal prairie - utils, halloween, valentine
sounds good?
That works.
YES
latex fixed
it never crosses 110MB anymore
not matter how many times you give bad input
Yay!
for some reason using matplotlib.figure.Figure instead of matplotlib.pyplot.figure fixed it
Weird. But that's good.
go figure
ahhhh, it has been locking past 10 minutes
updated all dependencies to supported latest, for supporting 3.9
on lance
@short snow @vocal prairie @sleek steppe So all of you will work on sir-lancebot#549 together?
yeah, since it is kinda big issue, and needs lot of testing
Okay, I can assign you already, others need to comment in issue first before I can assign.
wait why didn't lance put the issue embed?
Toxic and dawn i think it might be easier to do the changes according to the libraries rather than cog wise
it's not that
this is actual OOM
I need to add some emojis to my server for the stackoverflow command, but if I store them on my server and use my server's emoji_id, then it won't work on this server right?
You can use the local config to override the IDs for local development, and keep the production config as is
If you're adding new emoji you can ask a staff member to add them to the production emoji guild and give you the IDs so that you can configure the prod env
okie thanks!
Hey, this channel is for pythondiscord projects, not for advertising your own. If you'd like to discuss your own, try the off-topic channels, or the relevant topical channel
sir-lancebot#583
it is a pydis project
I deleted a message
no worries
weird why is sir lancebot failing on this
yeah I was wondering the same
Yup, in that sense
only on on_message right?
I do not know
so uh the way i fixed the memory issue is pretty weird
i have to clear the figure, del the figure and run gc.collect()
removing any of those makes it stop working
Are you working on the latex thing?
yes
I already have a fix that just limits memory
But if you also have a memory cleaner, that would be a nice addition
hmm
turned out there's a memory usage spike whenever there is improper input
why is that though
Even if you managed to clean up input perfectly, you shouldn't give people a function that runs code internally without any memory protections
I'm not sure what Bast's reason is, but that's the reason for my fix
yeah i'm not trying to clean the input, i'm just trying to make sure the memory is cleared even for bad input
The problem isn't clearing it i don't think
the problem is it tries to allocate more than is available
no amount of cleaning will matter if you never get past the allocation
well the memory usage does seem to stay within a certain limit now
hasn't crossed 110mb
although tbh i don't really know whether the way i'm measuring it is right
i'm just looking at the memory usage for the python process in task manager
hmm, any logs?
Sir-lancebot basically logs nothing
There is no error except for the ones introduced in the PR
with parsing or whatever
I literally have no idea, I haven't been keeping up
ok no worries, i will look into it
hmm, on updating it to python3.9 and discord.py1.7.1
i get this error
can't seem to understand it
bot/utils/pagination/LinePaginator subclasses paginator
looks like in the new version of d.py there's a new attribute, that .close_page() is looking for, and it doens't exist
it needs a super.__init__(), since we calling close_page(), which we have not written i.e. doesn't exist, and there is no linesep in our init, so it is looking for one
so should i add linesep or do super.__init__()
depends if you want to overwrite it, or use the default
linesep is added in 1.7, ahh that's why
yea, there's going to be a bunch of new things added in the new version of d.py
so I imagine there's going to be more things like this
👍
was there a reason for not subclassing HelpCommand in lancebot?
that'd be the standard way of making a help command for a bot, so the current way feels a bit more complicated than it needs to be
Not entirely sure on the reasons for the decision, I wasn't around back then
I think there is issue for migrating
ah right
@vale ibex #dev-log message yes we are upgrading to python3.9.4
Cool, I'll update the issue title
due to python's dependency hell, we'll be upgrading to... nothing 👀
hah the description is so accurate
Haha yeah
Yes, I'll go ahead and comment.
so right, it is 🤯
leftpad
According to Pipfile, discord.py is version 1.5.1, and python is version 3.8
Oh, so we're not upgrading that much.
Now I have to go read the changelogs.
I have no idea what came when.
@short snow If I'm forking your fork that means I have to delete my fork right?
Just delete your fork of PyDis Lancebot, and then fork Jason Lancebot.
Hmm, other way is that Jason give you write access to his fork, so changes can be pushed directly to there
yeah i asked them which one they would like, they went with forks, so i was fine
i updated them to be 1.7.1 and 3.9 on Pipfile
see my fork's update/python3.9 branch
Hahaha
!pypi leftpad
that source is really helpful btw
i have used that code to learn how to rjust strings rather than find the docs 
leftpad was a npm thing, almost every npm package used it and t hen the author deleted it
what followed was a glorious clusterfuck of breaking builds
because of a 12-line npm package
yea
Yarn is better.
dawn you want push access or still want to work with fork?
advantage with push is, you won't need to pull and rebase everytime
and you won't need to delete the pydis fork
👀
Then pushing is fine.
why would you need to delete any forks? just add the other fork as a seperate remote, manually merge over the changes, make your changes and ask the other person to merge back, or PR into the other persons fork
there you go @vocal prairie @sleek steppe
and you could work on branches like: update/python3.9/dawn
what is going on on your fork?
also why not PR into the fork from a different fork?
investigating update to python 3.9.4
that would be tiring, rebasing and pulling everytime
Yes, because fancy new features.
@stable mountain uses 3.8
Sebastiaan explained it in the issue.
better than having to merge because origin changed while you were editing
[edited]
sir-lancebot#549
ohhh there's an issue for it
i dont see how that's relevant to the leftpad stuff?

it worked now 👀
No
Typing generics is worth the cutover. Lancebot doesn't need to match Python exactly
ah ok
so i need to look into the regex it seems
regex fix still hasnt been merged ig
we discussed it extensively yesterday but i had to go
!remind 10H fix the issue with automatic issue mapper
Your reminder will arrive in 10 hours!
Who was going to PR the regex fix? I don't remember
no clue, i had to go
i will delete the reminder if thats the case
laundmo probably should since iirc he did most of the work in beefing up and making the regex better
no one lol
if it was just the regex, i would, but people kept wanting to add additional checks and i just dont wanna bother with that
i think the regex is most important right now to make it work
i'd say fix the regex and any additional features can be added later
^
people can add all the checks they want after the fact, but currently a very useful feature is totally broken
it would be nice for it to repeat the repo and issue/pr number in a later pr
fair, just gonna PR from the web editor then lol
so that's a later fix
That's probably best.
^
lul
hah, my PR passed flake8 even though i literally have no linter in the web version
Noice
now just need a review

i don't know what i was expecting
not yet lol
i didnt realise how important that feature was to us until it broke
? (context: someone added 10 'youtried' emojis)
That's a lot of stars.
pls 
we have reached peak rotat banan
someone approve it even if the regex doesn't always work
but it works in more cases than it should
it allows a--b/a--b#123
yeah
Is it supposed to allow *s?
allow *s?
asterisks
where does it do thaT?
python/cp*ython#4865 returns ython#4865 for me.
its supposed to work for now
oh wait, that'll return invalid.
^
So it doesn't matter.
yeah because asterisk isnt allowed in github
Okie, then it's fine.
the problem is if it matches above a /
basically it should error somehow
but
this is to make it usable
.issue 555
i
that command should really be allowed here
would be a bit of a solution to the auto linker
Why does the pr say that linting wasn't done?
Is there just no point?
Since it's the same?
because i literally cant lint, i did this all in the web
because linting wasnt done
yes
if you dont do something dont say you did /shrug
But eh, ig it doesn't really matter.
and i mean the actions auto-lint so
i did commit a second time to make sure linting has a better chance of passing
kinda wanna see if i can get the review done instantly if i ping akarys, because akarys is the one that bonked it
🎶 git blame tightens
jo @vale ibex any chance we could speed-merge https://github.com/python-discord/sir-lancebot/pull/680
because sir-lancebot#680
@short snow you made commits to evergreen 😦
could be restarting
there's no ping command
nop
nope take it up with joe
@patent pivoteeeeeeeeeeeeeeeeeeeeeeeeeeee (lancebot ping command when)
atjoe ping command ples
would be redundant to python is what he said
if something is affecting python it would be affecting sir lance as well
Reasoning: to see if lancebot goes brrrrr
nice to check whether its bonked
off messages n messages 🥴
we use ping to determine if the site is up, API is responsive, among other things, lancebot doesn't need that functionality because if python reports an error then lancebot is likely susceptible (and lancebot is much less dependent)
Yeah, but like, the latex sometimes screwed it up, what says something else can't.
i like to always have ping commands and always have them public because even if you dont care about ping it can show you if the bot is dead
I didn't say no ping
literally just respond with pong
ok ping command pr in 10 :)
also while your here joe can you merge https://github.com/python-discord/sir-lancebot/pull/680
or something short
pong
oh you meant for the bot
ok then
make it embed at least
Can I pr the ping, or does someone else want to?
Go ahead
@whole forge done
sir-lancebot#680
won't have deployed yet
Didn't deploy yet ig.
takes a few minutes at least
you'll see it restart in #dev-log
but yeah I agree a ping command would be nice to have, it's just that when I was approached about it the proposal was to rip the one out of @stable mountain
which is total overkill
agree
i'm just gonna create an embed that says pong + ws latency
sounds good
since thats all thats really needed
mayyyybe uptime?
sure
.uptime
just thinking to know when this actually did deploy
sir-lancebot#680
kinda a useful thing sometimes
I started up 22 seconds ago.
lol
nevermind then, just pong + ws latency
!uptime
Noice one laundmo
Why, when you can check #dev-log?
why not, when sir-lancebot has it
it would be nice to include uptime and hit SHA
Maybe we add an !about command
!about
include some details on the bot project
.about
test with a full repo name julvo/reloading#11
nice
interesting
Should I open an issue for reference?
nah it's fine to just PR
Time to set up a test server.
While y'all here
how do you feel about a fix to the latex which doesn't make 100% sense but works?
!otn a joe's-issueless-PR's
short and simple
That sounds good to me.
A link to this conversation and a summary of what we decided and why wouldn't go amiss in the PR
@fervent sage maybe use lancebot green colour
ok
your colour SUCKS worst blue ever
Nah it doesn't suck
doesnt suck as much as you 
@fervent sage gimme hex
87ceeb
say it again and I'll find you
now thats some mosh pit hair
U look like the least threatening teen I have ever seen
has been my main pfp colour on most of my pfps so its useful to know
haircut booked April 20th
if you grep -r "87CEEB" . basically any of my bot repos you'll probably find it somewhere 
dont cut it off, let it grow into a mane
@short snow @sleek steppe Want to set up a test server for the upgrade?
lmfao
I need to book mine in soon
!ot
Off-topic channels
There are three off-topic channels:
• #ot0-psvm’s-eternal-disapproval
• #ot1-perplexing-regexing
• #ot2-never-nester’s-nightmare
Their names change randomly every 24 hours, but you can always find them under the OFF-TOPIC/GENERAL category in the channel list.
Please read our off-topic etiquette before participating in conversations.
bot.constants.Colours.green?
kk
I think
That took at least 8 seconds
AttributError
The light green or the dark green?
it might be like soft_green or something
it has green in it 😄
ah yea, light_green or dark_green
class Colours:
blue = 0x0279fd
bright_green = 0x01d277
dark_green = 0x1f8b4c
orange = 0xe67e22
pink = 0xcf84e0
purple = 0xb734eb
soft_green = 0x68c290
soft_orange = 0xf9cb54
soft_red = 0xcd6d6d
yellow = 0xf9f586
python_blue = 0x4B8BBE
python_yellow = 0xFFD43B
grass_green = 0x66ff00
take your pick
YOU wIll NeveR UNseE iT
lol looks good
i was so close to committing this
lol
100% didnt copy the file :)
Lmfao
but its my code anyway so its fine 
actually i dont see a single embed using that green
its a darker one for the ones that are gree
Me neither
scrolling though #sir-lancebot-playground
They all use default or dark green
bot#1
Nvm
I imagine there may be a few constants that just aren't used anymore
Search for ittttt
Use a color picker and mouse over it
At least for me.
!raw #dev-contrib message
You are not allowed to use that command here. Please use the #bot-commands channel instead.
at some point im going to create a reference counting class that works exactly like the arguemnt it gets, but counts how often and where its accessed in any way
Someone pls do it it's relevant
Color: 0x1d277
!raw #dev-contrib message
== Raw embeds (1/1) ==
author:
name: GitHub
url: https://github.com/python-discord
color: 0x1d277
description:  [Add "Now playing" status](https://github.com/python-
discord/bot/pull/1)
type: rich
There's the color
I rep the file too
If you want to grep it again, please talk to a union representative
actually bright green is even less common than soft_green - it's used solely in the issues cog once
then do soft
bright looks nicer tbh
I'm against having colours named as their colour IE soft_green
well if we're going to
We should have success/failure etc
colour is less typing and less typo prone
yea, having the colours named after their function
Colours.ping
hah
Yeah, that would be easier imo.
from bot.constants import Colours
Colours.ping = 0x1d277
monkey patch go brrrr
lol
why update files when you can monkey patch classes 
one 16k line file that monkeypatches every other file
Colors.bikeshedding = 0xff0000
Colors.color = green
dir(Colors)
color
yes.
class Colours:
def __getattribute__(self, name):
return 0x87ceeb
Also how do you update python for pipenv 
#9cfff1 is the color I use for embeds on my bots.
*color
Colour
colour
Color
its colour in the repo currently
color, but colour is used more
embed = Embed(
colour=randrange(0, 0xFFFFFF),
...,
)
It's wrong. Use color.
pipenv is a package against a python version. So you update python and then install pipenv on the new environment
Or update python with pipenv lol
uh, this feels quite aggressive...
Ah I see
Color is the only answer
> py -3.8 -m pip uninstall pipenv
> pip install pipenv
I'm guessing
Let's chill out with the color vs colour argument.
No one saw that I just realized I had a typo
so py -x.x will choose which python environment you use you use
But pipenv creates a virtual env within the dir when you init it
I don't even have pipenv on 3.8 
so you'll need to delete the virtual env for that folder and make a new one with the new python version
if you activate your pipenv shell
you can do pipenv --rm
then you can do pipenv --python 3.9 or whatever
Should the ping command have a 🏓 ?
That would be nice.
wait how many people are working on the ping command right now?
just vco
okie ping command is sir-lancebot#681
done
LGTM
we need that cloudflare worker that filters github events to do something else too
it needs to translate :shipit: into
for the webhook

@patent pivot with the gateway thing every other time i've made ping commands people complain to me that they dont know what the gateway is, this is one of the only times i havent used it, i guess there's no winning either way 
hmmm, I prefer gateway to just WS, alternatively "Discord WebSocket" or "Discord Gateway" might be good
oh yeah, i definitely prefer more discord-y terms
but apparently not everyone enjoys reading the developer docs for entertainment 
(they should)
Agreed
I still have a pr open to them
They're quite interesting.
Anyway, "Discord Gateway" sounds clear to me.
i'm just gonna leave it at 'Gateway' - again that's secondary to the main purpose which is just seeing that the bot isnt dead
Doesn't github send them directly to here?
No, it doesn't
Then
LOL NOT A BAD SHOUT
I love it
i got about as far as actually opening the worker's index.ts before i realised i had no idea what i was doing and went back lol
Lmfao
Does it reformat them for discord?
Like?
uhhh
Ah
I thought you could filter that with githubs options
So how exactly is the chain configured?
Coveralls, stuff from bots (cloudflare pages), all dependabot stuff, bot PR approvals, empty review comments
you can't filter with that granularity at GitHub
You can only say "I want all push events"
not "I want push events but not from X users"
Ah
So now we go from GitHub into a Cloudflare Worker
which forwards on to Discord
dependabot?
Updates dependency versions on some projects
Oh for the colour command, in 1.7 they support rgb(x, x, x)
I replied and pinged you guys earlier than it would be easier doing the changes library wise.
holy shit you can now mention voice channels and join them by clicking
Another git process seems to be running in this repository, e.g.
an editor opened by 'git commit'. Please make sure all processes
are terminated then try again. If it still fails, a git process
may have crashed in this repository earlier:
remove the file manually to continue.
Ooof how to fix it
yes that is true
rm -rf ./git /s don't
Sure just bot commands should be enough
Or do I just delete this file -> .git/index.lock
¯_(ツ)_/¯
Lol I was just like you until yesterday, when all my hard work got cut in 5 minutes
Ah yeah that worked
@sharp timber
Here's your reminder: ^ check on.
[Jump back to when you created the reminder](#dev-contrib message)
authenticate(): return True
Or should I comment it on the original issue on the sir Lance repo
I guess that would work
I changed asyncio.ensure_future -> asyncio.create_task and loop.run_in_executor -> asyncio.to_thread
Hmm should I PR now
Dunno, if you have tested it right and it works perfectly, a push should be good
I changed typing.Iterable to collections.abc.Iterable since it's deprecated in 3.9
👍
I know I can get assigned if I comment but what do I even comment lol
lol
also
it has even been done for,
from collections.abc import Mapping, Sequence, Callable
you could update those too
@short snow You're likely going to need to upgrade dev dependencies as part of the python upgrade too
i just gave a bump to dev dependencies, other dependencies are to be updated as they introduce support for python3.9
Alright cool, just checking as I saw they were missing from your table on the issue
If they're dealt with, then no worries
AttributeError: 'LinePaginator' object has no attribute 'max_lines' that's an interesting error
hmm, it worked for me lemme see the code one minute
I don't know if I should click the link…
no, i by mistake removed self.max_lines = max_lines
does it work after adding self.max_lines = max_lines, toxic?
yep
cool, you can just add it with your commit
best_board, _count = min(current_board_counts.items(), key=operator.itemgetter(1))
current_board_count is an empty iterable
I can just except the ValueError
yeah, since there no boards given to it

