#dev-contrib
1 messages ยท Page 144 of 1
Heads up don't merge bot#1872 until I review ๐
King Arthur had three pull requests for isort stuff
Shouldn't be, it passed linting locally
Neat
Bear in mind we use a 120 chars limit on the bot
Does anything handle unused imports
Yes, there is a very particular configuration
Handle/fail on
So here I'd rather not warn inside the IDE, so you don't try to fix them manually
Yes, flake8-tidy-import
Hmm thatโd probably be annoying
go to commit, wait half a minute, whatโs that? Failed because import order
With the warning itโs clear before you have to commit
The precommit hook will fix it for you
So like
You just commit and that's it
But then you have to commit twice
It doesnโt fix stuff for me
If pre-commit fails, I have to run it twice
Depending on how you stage you have to run twice, yes
Even if I donโt change anything
What are the alternatives? I think it does its job currently
It does it for every single commit for me, even if I have everything stagedโฆ I accidentally checked out in CRLF
Would you still prefer to manually sort your imports rather than running a command twice?
(I would, running a command twice is unintuitive for me)
Isort*
Well, let's keep the plugin then I guess?
This isnโt even a problem for me, pycharm sorts everything for me before I even get to pre-commit
Iโm fine with keeping it yeah, I just want to keep the flake warning as well
the alternative is nothing, I'm just saying that we removed pre-commit from api because we didn't see a huge use for it
Fair enough, but then we have a GPL dev dep
Tbh pre-commit would be a much better tool if it was configured client side only
GPL dev deps are fine, it's about redistribution, we use gcc in some capacity in a bunch of our images
Eh, honestly it is a decent way to prevent failing linting. If one doesn't want to use it, sure, just don't install it? I personally really like it, I always forget to manually lint
That way everyone can follow their preferences and needs
You mean my own bash script?
Yes, and hook up into whatever precommit system you want
Precommit integrates nicely with venvs and version management, itโs still more convenient than scripts
Also that other thing I told you way back when ๐คก
Or even precommit if it's not used by the repo
I am too much of a ๐คก to remember what you said back then
I donโt want to learn bash or w/e
If you want your own hooks on a repo which doesn't use pre commit I can help you set it up
Yeah, you can make precommit run anything
I believe there is also a way to alter the script precommit creates to use your own config file
Probably that too
So you still have the pyprecommit framework but your own config
Ye
Pre commit is super awesome
I've written my own scripts to check things and they're great :)
I knew the way we cache dependencies would bite us in the arse at some point
Wdym
Yeah, actually why don't we use pre-commit on the API? I just saw that it was removed, but no reason whatsoever.
Because I cannot install dev packages then normal packages
Hmm
Or maybe I can (?)
@green oriole do you use black?
Yeah we only need to check licenses when the cache key changes
Cool
No I don't use black
ah
I am a control freak remember
that's why you used an isort configuration that hates black /hj
I mean, who cares, we don't use black
Who checks git diffs on these imports
Why is that just not default
not sure
I mean, itโll still fail later on because of flake but like
i mean, it could be turned off for pre-commit
but like
for general usage, sorting them with a file that already has errors could cause more :P
I mean, that sounds like a pretty niche case unless you have isort on save
Which again seems pretty useless
How does it hate diffs
It generated a 700 lines diff at first
no trailing commas ๐ฅฒ
But then you break compatibility with my ide and I actually have to use it ๐ฅฒ
review filed
And I cannot look at replies rn
Because as soon as I did so, WINDOWS UPDATE
So do we want trailing commas or not? I know this is in our code style, but it isn't something I personally like, and since isort will try to fill a new line before moving to the next one it is probably something that will only happen every 36th day of the month, sooo
Iโm biased, but no
@static canyon @green oriole
I'm not gonna add periods to the end of the points in where to start because that'll offend my sensibilities
Looks good ๐
Do we maybe want to mention about reviewing PRs?
That's still participating to OSS and is just as important imo so think it fits the tag
I don't think a first time contributor should be reviewing in general
And in #dev-announcements :P
True
bot#1833 tag speedrun time?
@clever wraith yep it's still an issue
[nsfw]||python.com|| is the domain we filter
yeah, we filter python.com but the filter also catches everything ending with it
(... why would you intentionally trigger a known filter?)
sorry, I wasn't sure it was still an issue
FYI this is not the Python website (and is NSFW). (In case you didn't know.)
just to make sure
no, not you doublevcodes
It does, it pings the mods
I absolutely agree, @azure loom
what other tags can I work on now...
Hey! Could someone take a look at api#22? The issue hasn't been approved.
I really wonder who would name their alt "le alt"
@molten perch AoC thingy merged.
๐ Thank you! ๐
I disagree, I think we should encouraging reviews. Anybody can review and it truly helps
Also, I think a first time contributor =/= someone who doesn't know much about code and its quality.
Most first time contributors have adequate experience with Python and even if they can't attest to style as much, they can definitely review on logic, etc.
I think the issue is more that they won't be familiar with how our codebase works
I have no idea how the codebase works and I still do occasional reviews somehow ๐คท
Wait, what's your GH name? decorator-factory?
Is there any harm with a "bad" review from someone that is just getting started though? Seems like a good place to get started really
yes
Is that a not equal sign?
Yep
True! Everyone starts somewhere
And people learn from their mistakes
K just checking
If they have questions about the code, doesn't that mean that maybe the code could be more clear or could use some comments?
I agree. I could argue that you can gain something from even a "bad" review
I agree with this. As Fronto said, even if a first time contributor makes a review and makes a mistake, they will learn from it hopefully and eventually will master code reviews ๐
So I'm in favor of having first time contributors leave reviews
I'm not sure, depends on the person that's reviewing I think
no harm in adding to the conversation innit?
That's okay, in-general you don't need to.
Most changes are new fun commands so as you're looking over the diff you get a complete picture.
Yes I know what you mean, I'm not sure I explained myself well
Ngl I still can't find my way around the bot
I mean I guess for non-staff it's not a massive issue since the reviews don't count for much, but I personally would prefer no review over a bad one
Yeah I can get that, having a bad review could derail the overall PR process.
How come?
In terms of chaos and confusion?
WHOOOOOO
They may not be familiar with style guide etc. I guess, but then that would likely be picked up by someone else who is familiar (and PRs need a core-dev approval anyway so they should notice)
Well let's say I have a PR open and I need some reviews. If there is a "bad" review, it could spawn a chain of conversation that would be more about the errors in the review, rather than focusing on the content of the PR
Yeah BOIIIIIIIIIIIIIIIIIIIIII
Also, the tag is just an entry point. I don't think it needs to cover all possible ways to contribute. More a way to get people here
Which could be a great learning experience for the "new" person leaving the review, but would not be super productive for the person with the open PR
Speaking of reviews, can I please get a second one on bot#1860? I'd like to get it merged before I work on bot#1864
(CC @brisk brook if you're able to ๐ ๐)
I'm still in favor of someone trying to get involved with the whole ecosystem with reviewing though
Nah, I get what you mean if this is someone who comes along and tries to nudge the PR in different ways.
But even someone who opens the PR, reads the code and then asks some questions about different things helps reaffirm the author's beliefs in how things were done.
why does github light theme look so bad
I personally like the light mode lol
My worry here is that the beliefs the user instils in the PR author go against our general dev-flow / style guide (e.g. recommending inline trailing commas etc.)
It's then a pain to have to "correct" them
I don't see that painful, it's a learning experience for everyone involved
Christ, I can see why
oh lol sorry @gritty wind clicked disable automerge instead of merge in main
so now I get the merge credit instead ๐
If my software career doesn't work out I have a backup plan ๐
I didn't see a \s

Your master plan paid off
https://github.com/python-discord/bot/pull/1602 @sleek steppe what's the status of this PR?
!contribute
Contribute to Python Discord's Open Source Projects
Looking to contribute to Open Source Projects for the first time? Want to add a feature or fix a bug on the bots on this server? We have on-going projects that people can contribute to, even if you've never contributed to open source before!
Projects to Contribute to
โข Sir Lancebot - our fun, beginner-friendly bot
โข Python - our utility & moderation bot
โข Site - resources, guides, and more
Where to start
- Read our contributing guidelines
- Chat with us in #dev-contrib if you're ready to jump in or have any questions
- Open an issue or ask to be assigned to an issue to work on
yeaaaaaah buddy
We went from 26 to 21 PRs in the span of an hour
This PR has been in the works for a while. If anyone's available for reviews, please do so.
Hey @static canyon are you around?
want to merge bot#1831 but I want to squash the last commit in it
Yep, gimme a few mins
I can do ๐
๐
I'll also merge main into it in case there's any new getLogger that have been added
Might as well rebase onto main to avoid another merge commit
Already done it but can squash
the magic of our triage lead and friendsโจ
uhhhh
ah yea, I see now
1 sec
What was the changes you made?
just squash the last commit?
uh oh
Yeah, I think so
reflog time?
Which commit did you want to sqush it into?
I've got a copy locally so I can just fix my end and forcepush
"Fix Newlines"
"Address Review"
becoming
"Fix newlines and address review"
CC @vale ibex
Perfect, thanks 
no worries ๐
I believe that's the squash you were after
Just fyi I've been down this path before, which is why I never merge main until the very last second lol
always prefer to rebase onto main
Yeah fair enough lol
How do I do that?
while you have main checkedout git pull
to make sure your local main is up to date
then checkout your branch and git rebase main
Right, thanks ๐
Rebasing onto Main
-
Checkout
mainbranch -
git pullto ensure it's upto date -
Checkout branch you're working on
-
git rebase mainto rebase onto main
.bm rebasing onto main
Did you say you wanted to add the rest now too? if not I can merge this pr
What do you mean by the rest?
this
ah nice
Ah, it's ignoring my approval since I forcepushed those commits
@vocal wolf could you +1 on my behalf?
ye
bot#1831
Tyty
fyi @vale ibex sir-lancebot#889 is just a one-line config change if you could approve that too pls ๐ ๐
It has 2 approvals but one is non-staff
Ah, @vocal prairie beat you to it, thanks ๐
Huh, why isn't it merging. Auto merge is on and all checks have passed.
๐ค
Oh, maybe it's the "Update Branch" thing?
It shouldn't be but I can try I guess
It is because of the update branch button.
mhm, it got merged when I pressed ๐
Well that's 5 of my PRs merged all at once :p
!remind 17h This if it hasn't happened already
Your reminder will arrive on <t:1634308879:F>!
Will also try and find some time to take a look at bot#1721 and bot#1815, not sure if there might be some conflicts between those
I've been avoiding the time utilities one because timezones are hard 
you should totally look at the discord 2.0 migration >_> we already have 2 PRs waiting on it
Oh also a possible feature for sir-lancebot that's waiting for thread support for Python
(Hangman mulitplayer in threads)
I feel like quiz should be in threads too
i'll probably just take a look at the code there and try out a few core bot features, and leave the rest of the testing to prod 
It takes over the entire channel
Looking at the d.py 2.0 PR, it seems we've gone for removing the tzinfo from all of the aware datetimes
instead I think we should use arrow.utcnow() to get the current time
since that can be compared with aware timestamps
Anyway I've been testing and looking around for a bit the past few day, and those two missing tzs in my request are all I've found
has a functionality test of the 2.0 migration happened yet?
That's what I was referring to, I've done a functinoality test of sorts
not sure if that's what you were referring to
Just like, spinning it up and running through all the major commands and scenarios
yea
which stuff have you tested specifically?
filtering, infractions, otn, help channels, defcon, voice gate, slowmode, silence, modlog, mod pings, clean, reminders, snekbox, talentpool, syncers
okay cool cool
Nice work @thorny obsidian !!
Here's your reminder: that and that
[Jump back to when you created the reminder](#dev-contrib message)
.bm 897962493920567316
Your input was invalid: You must either provide a valid message to bookmark, or reply to one.
The lookup strategy for a message is as follows (in order):
- Lookup by '{channel ID}-{message ID}' (retrieved by shift-clicking on 'Copy ID')
- Lookup by message ID (the message must have been sent after the bot last started)
- Lookup by message URL
Usage:```
.bookmark [target_message] [title=Bookmark]
.bm 897962493920567316 Question format
Your input was invalid: You must either provide a valid message to bookmark, or reply to one.
The lookup strategy for a message is as follows (in order):
- Lookup by '{channel ID}-{message ID}' (retrieved by shift-clicking on 'Copy ID')
- Lookup by message ID (the message must have been sent after the bot last started)
- Lookup by message URL
Usage:```
.bookmark [target_message] [title=Bookmark]
if it's not in this channel, you need to do channelid-messageid
IT got deleted
lmao
Idea - could we make @dusky shore react to messages using
when someone write "lemon" during halloween? We already have some much reactions, but currently they are default emojis.
How about allowing several "mods" for the pfpmod? Like first apply 8bitify then spookyavatar?
I do think a contributor should do at least one code review before reviewing, but we are in dire needs of reviews, I think we can agree on that
one code review before reviewing
Can you clarify what you mean by that?
@static canyon can you remind me what PR did you need me to review again?
It was already reviewed! Dawn (iirc) did it last night
If you'd like to review something I do still have other PRs open needing review
bot#1874, bot#1845, sir-lancebot#899 and sir-lancebot#900
Top priority being probably either the top or bottom ^
Yeah I would test this on my school laptop, but that requires Docker and I am not sure whether I want to install that together with WSL.
Fair enough
bot#1874 is ready to be merged now
bot#1874
err, one code contrib
(i.e. someone should do at least one PR before doing a code review)
It hath been merged, thanks ๐
Hope we donโt break the bot lol
Literally where is my code PR
You made bot#1821 so you've done issues
sir-lancebot#873 PR
didn't you contribute to pixels before
Oh right, this was like after 80% of my total reviews lol
Hmm, one big review or Chris' PR and that access token stuff yeah. I think I reviewed quite a lot before that though
Woo woo, 2.0 ready to be merged!
lol, fixing fixing
Haha
Once d.py 2.0 is merged, I'll rebase my two PRs onto main so that I can use the new get logger function, otherwise @static canyon will be mad at me
๐
:p
@vale ibex are you free to help with a query I have RE structuring?
I've got an issue with sir-lancebot#861 in regards to structuring the change of moving all commands to be a subcommand of a new Hacktoberfest cog.
The best thing I've got at the moment (with inspiration from Akarys) is this:```py
...
from hacktoberfest.issues import issues_command
from hacktoberfest.stats import link_stats_command, stats_command, unlink_stats_command
from hacktoberfest.timeleft import timeleft_command
class Hacktoberfest(commands.Cog):
def init(...):
...
@commands.group(...)
async def hacktoberfest(...):
...
@hacktoberfest.command(...)
async def issues(...):
await hacktoberfest_issues(...)
@hacktoberfest.group(...)
async def stats(...):
await stats_command(...)
@stats.command(...)
async def link(...):
await stats_link_command(...)
@stats.command(...):
async def unlink(...):
await stats_unlink_command(...)
@hacktoberfest.command(...)
async def timeleft(...):
await hacktoberfest_timeleft(...)
def setup(...):
...```Does this look good? The idea is that the actual handling will still be done in the respective files, so that we don't end up with one massive file with everything in it
There's nothing inherently wrong with that no
If they do start getting big, you could always split it into two cogs
I mean the idea is that hacktoberfestissues, hacktoberfeststats timeleft becomes hacktoberfest issues hacktoberfest stats hacktoberfest timeleft. All the same top-level command group so really needs to be one cog
The above seems to be the best, so will go with it
๐
Thanks ๐
I'll work on that now since I've got a bit of free time
This is actually gonna be more complicated than I thought, because of class attrs etc.
Currently all the hacktoberfest commands are their own cog. The way I was planning to move all of these into one parent command (.hacktoberfest) was by importing the main function and calling it, but since the functions are within a class I can't do this.
Should I just remove the class from each file? The issue with that is that I need to figure out what to do with class attributes (the hacktoberfest issues class has a bunch of cache attributes). I guess I could just have the cache variables as global variables?
Alternatively I could have a singleton instance for each class which gets imported, so e.g. from bot.exts.events.hacktoberfest.issues import issues then issues.main_function()
CC @vale ibex
you could keep the issues class around as it's own file, remove the commands from it and instantiate it within the cog
So it becomes a normal oop class for storing state
Sure, or have an init task if you need async stuff
So like```py
class Hacktoberfest(...):
def init(self, ...):
self.issues_cog = HacktoberfestIssues()
self.stats_cog = HacktoberfestStats()
self.timeleft_cog = HacktoberfestTimeleft()
...
@hacktoberfest.command()
async def hacktoberfest_issues(...):
self.issues_cog.main_command(...)
That seems overkill
I can't imagine time_left is anything complicated
it's just calculating a timedelta right?
It's 3 functions
"""
Calculates the time left until the end of Hacktober.
Whilst in October, displays the days, hours and minutes left.
Only displays the days left until the beginning and end whilst in a different month.
This factors in that Hacktoberfest starts when it is October anywhere in the world
and ends with the same rules. It treats the start as UTC+14:00 and the end as
UTC-12.
"""```
Yea, those could just be helper functions in another file, no need to have a whole class
But it's already a class is my point (it's its own cog)
There's nothing stopping you from changing that
Right, okay
The goal of this is to merge all 3 cogs into one cog right?
Yes
So ou have a few things here, there's the main cog class, that you will need
then you have the option to have another class which can store state, if needed
and you could also have util functions if it's easier, and those could live in the cog itself, or another file
The thing is I don't want everything in one file
If I move all utils into one file then that's basically all the cogs just moved into a utils file
Sure, then you could have 3, one for the main cog, one for a class that can store state and have class funcs and then a third for utils funcs that don't live in either
Wdym by "store state"?
You said one of the current cogs has quite a lot of class vars for caching right?
That what I was referring to
Yeah, hacktoberfest issuespy def __init__(self, bot: Bot): self.bot = bot self.cache_normal = None self.cache_timer_normal = datetime.datetime(1, 1, 1) self.cache_beginner = None self.cache_timer_beginner = datetime.datetime(1, 1, 1)
Think it's used for caching different issues
Take the talentpool in @stable mountain as an example, it has the main cog file in _cog.py, which has all the commands, then it has the _review.py file which has a class for scheduling reviews
So for this, you could have a cog which contains all the commands, maybe a few helper utils, then you could have another file with a cache class
Each cog has its own helpers is the thing
So if I only have one utils/helpers file, then I'm basically just merging all the cogs which is exactly what I want to avoid
I mean maybe I can semi-tidy by splitting into classes within _utils.py, so like```py
_utils.py
class HacktoberfestIssuesUtils:
...
class HacktoberfestStatsUtils:
...
class HacktoberfestTimeleftUtils:
...```
So the three files would be _cache.py, _cog.py and _utils.py:```py
_cache.py
class IssuesCache:
"""Handles cache for .hacktoberfest issues command"""
...
# _cog.py
class Hacktoberfest:
"""Handles hacktoberfest commands."""
...
``````py
# _utils.py
class HacktoberfestIssuesUtils:
"""Stores util functions for `.hacktoberfest issues`."""
...
class HacktoberfestStatsUtils:
"""Stores util functions for `.hacktoberfest stats`."""
...
class HacktoberfestTimeleftUtils:
"""Stores util functions for `.hacktoberfest timeleft`."""
```
Thoughts? @vale ibex
And then have all the util functions as classmethods (think that's the right term) so that I don't need an instance (can just do HacktoberfesIssuesUtils.get_issues(...) etc.)
Sure, that could work
That's what I'll go for then, unless someone says otherwise before I implement tonight (in ~6-8 hours)
!remind 8h ^ if not already started
Your reminder will arrive on <t:1634329176:F>!
Is it really necessary to namespace them?
It's also preferred to use modules for that instead of abusing classes
๐คจ
So 3 separate util files?
I guess that makes sense, just not sure if that's the tidiest way
what do you mean?
stats has 329 lines of utils (10 methods)
issues has 61 lines of utils (2 methods)
timeleft has 17 lines of utils (2 methods)
Total of 407 lines over 14 methods
Won't the name of the methods give away quite easy what purpose it serves?
I don't mind this being in one file. 400 lines is a quite okay length.
Not always, e.g. there's in_hacktober, build_embed etc.
But I guess I can separate them by just a comment
# _utils.py
## Issue utils
...
# Stat utils
...
## Timeleft utils
...```
So the three files would be _cache.py, _cog.py and _utils.py:```py
_cache.py
class IssuesCache:
"""Handles cache for .hacktoberfest issues command"""
...
# _cog.py
class Hacktoberfest:
"""Handles hacktoberfest commands."""
...
``````py
# _utils.py
## utils for `.hacktoberfest issues`
...
## utils for `.hacktoberfest stats`
...
## utils for `hacktoberfest timeleft`
...
```
build_xyz_embed()
That sounds good
Depends on how many, I'd say they may fit in the utils.py file or just cog.py
There's 11 I think
@brisk brook ^
I'd be fine with it going at the top of one of those two files
Just not sure which
Put it in the file with the least amount of lines then
Here's your reminder: This if it hasn't happened already
[Jump back to when you created the reminder](#dev-contrib message)
Hey! Could a core-dev take a look at api#22? If it's good to go, I'd like to work on it during the weekend.
Is the DB migration part of #22?
It seems not, so whatโs the blocker for the migration
Hey @cold island would you mind if I merge main into your site#591 PR? or would you rather rebase onto main locally?
mostly for the static preview
The lack of approval! ๐
I c
I don't mind either way
๐ I've just merged main into it
The fact you didn't have 3K conflicts is nothing short of a miracle
Are the ๏ฟฝ in that PR intentional
They appear as question marks for me
\ufffd : REPLACEMENT CHARACTER - ๏ฟฝ
It's used as a placeholder to show parts of the config.yml you need to replace
You aren't the first to ask...
@cold island perhaps a comment at the top of the config file is in order
Wait... The config.yml file is not in the bot repo
in the same collapsible element
it only appears once
Here's your reminder: ^ if not already started
[Jump back to when you created the reminder](#dev-contrib message)
Hey! Could a core-dev take a look at api#22 and possibly approve the issue? ๐
(Sorry for the continuous issue bumping ๐ )
Mobile devices place tables of content right at the bottom of the page in the guides on the website (for an example see Hemlockโs code review guide). This makes them sort of pointless for mobile users since they have to scroll through the entire page to click a link on the TOC. Is this something worth making an issue for?
that's funny in python, I really think it's a bug, at least in version 3.8.1:
when I instantiate a class Line, when I call a line.append(token), it instead of appending to the individual list of the instantiated class, it is doing append to the class(object), thus getting all the "line" (instantiated object) with the same elements in the token list.
code:
class Line:
def init(self, number, idx, string, tokens=list()):
self.num, self.idx, self.cols = number, idx, len(string)
self.tokens, self.string = tokens, string
self.ident_level = 0
while string.startswith('\t'):
self.ident_level += 1
string = string[1:]
lines = []
line = Line(1, 0, "test")
line.tokens.append(1)
lines.append(line)
line = Line(2, 0, "test 2")
line.tokens.append(2)
lines.append(line)
for line in lines:
print(line.tokens)
Console:
[1, 2]
[1, 2]
!mutable-defaults
Mutable Default Arguments
Default arguments in python are evaluated once when the function is
defined, not each time the function is called. This means that if
you have a mutable default argument and mutate it, you will have
mutated that object for all future calls to the function as well.
For example, the following append_one function appends 1 to a list
and returns it. foo is set to an empty list by default.
>>> def append_one(foo=[]):
... foo.append(1)
... return foo
...
See what happens when we call it a few times:
>>> append_one()
[1]
>>> append_one()
[1, 1]
>>> append_one()
[1, 1, 1]
Each call appends an additional 1 to our list foo. It does not
receive a new empty list on each call, it is the same list everytime.
To avoid this problem, you have to create a new object every time the
function is called:
>>> def append_one(foo=None):
... if foo is None:
... foo = []
... foo.append(1)
... return foo
...
>>> append_one()
[1]
>>> append_one()
[1]
Note:
โข This behavior can be used intentionally to maintain state between
calls of a function (eg. when writing a caching function).
โข This behavior is not unique to mutable objects, all default
arguments are evaulated only once when the function is defined.
They should show up if you run flake8
TLDR the __init__ line is run once, so a list is created only once, and thus the same list is passed to all of the instances of that class as a default argument
Which is everywhere that file appears :P
it's technically twice tho once in deployment and once in repo
How about moving the explaination of the config to the config on the repo and just embedding that on site?
so we won't need to change it at two places
This file doesn't appear in the repo, the repo only has the config defaults. There are no replacement chars in that.
We don't want to split the contrib guide up into two places, as that would just make it harder for new contribs
Sure thing, you don't need approval for porting issues like this, since the original has been approved and we told you you should port to the new API :)
Cool! Thank you! ๐
no the default_config.yml file which zig included in the guide and added some explanation comments in it.
And we won't be splitting it, we would just embed the file present in the repo on the site, like GitHub does when you link code lines
A guide to setting up and configuring Bot.
Also could we add a go back to top option on the site?
Yea, that's the file that we changed, we added replacement chars to highlight what values need to be changed
So that if someone tried to load the bot without changing it would error
dev_guild:
id: &DEV_GUILD_ID 1234536798 # ๏ฟฝ
categories:
logs: &DEV_LOGS 1234536798 # ๏ฟฝ
something like this?
Or we would need to add a note to the pr template if someone changed the conifg, please change it on site too
That could work, but work requires a lot of comments, since we explain a lot of things about this file in the guide
Since its different if its running locally or in docker
It won't be a problem to include that on the repo?
no just the file, nothing else
like the dropdown part of the section
That's not all of the explanation
Theres more below
When helping a new contrib, I'd rather be able to link them to a page on site and have them read properly formatted sentences and paragraphs, rather than comments in a yml file
Yeah i know lemme explain again what i am saying, currently if we add a new variable we would need to change it in two places on the site (after this pr) and the bot. So rather than changing it on two places if we "embed" the dropdown part of the section i linked above to just show the file contents of the default config file present on the github we won't be required to change it at two places then
rest of the stuff would remain the same
This part of the seciton
Like in my enhance incidents pr, i added a webhook config variable, so i would now need to even add it on the site also
Ah right, I'm not sure about adding more dynamic content back onto the site
offtopic You are back with your OG profile ๐
After the effort we made to make it static
Not sure how we would do it ๐คทโโ๏ธ but was just a idea. If it is possible would be awesome
Yea it does sound like it would be useful for when new vars are added
Just need to weigh that up against the fact that it won't error on boot if a new contrib forgets to change a replacement char
we could just add the replacement chars in comments after the config of this server
Like it is possible to embed github gists, is it possible for files also?
I donโt really think itโs a big deal to have it in two places
Itโs edited once every blue moon anyways
And the number of times we add something a contrib has to edit is even lower
True ๐
I can do it, if no-one else wants to. Have a nice vacation! ๐
Here's how to format Python code on Discord:
```py
print('Hello world!')
```
These are backticks, not quotes. Check this out if you can't find the backtick key.
!run
import request
r = requests.get('https://google.com')
print(r.cookies['1P_JAR'])
!run
import request
r = requests.get('https://google.com/%27)
print(r.cookies['1P_JAR'])
It's !eval but please run that in #bot-commands ๐
@vale ibex looks like I was a bit slow with the comment on the isort PR, should I open a new one for it?
it also looks like isort is only available through it being a dep of flake8-isort which we can depend on but doesn't feel ideal
Ah yea, missed that. that makes sense for sure ๐
Wait, this fails flake8 when running locally
How did it pass in the action
PS C:\Users\Chris\src\bot> poetry run task lint
Check for merge conflicts................................................Passed
Check Toml...............................................................Passed
Check Yaml...............................................................Passed
Fix End of Files.........................................................Passed
Trim Trailing Whitespace.................................................Passed
check blanket noqa.......................................................Passed
isort (python)...........................................................Passed
Flake8...................................................................Failed
- hook id: flake8
- exit code: 1
bot/exts/info/doc/_parsing.py:15:1: I202 Additional newline in a group of imports. 'from . import MAX_SIGNATURE_AMOUNT' is identified as Application Relative and 'from bot.utils.helpers import find_nth_occurrence' is identified as Application.
bot/exts/info/doc/__init__.py:3:1: I202 Additional newline in a group of imports. 'from ._redis_cache import DocRedisCache' is identified as Application Relative and 'from bot.bot import Bot' is identified as Application.
bot/exts/info/doc/_cog.py:26:1: I202 Additional newline in a group of imports. 'from . import NAMESPACE, PRIORITY_PACKAGES, _batch_parser, doc_cache' is identified as Application Relative and 'from bot.utils.scheduling import Scheduler' is identified as Application.
bot/exts/info/doc/_batch_parser.py:18:1: I202 Additional newline in a group of imports. 'from . import _cog, doc_cache' is identified as Application Relative and 'from bot.utils import scheduling' is identified as Application.
bot/api.py:9:1: I202 Additional newline in a group of imports. 'from .constants import Keys, URLs' is identified as Application Relative and 'from bot.log import get_logger' is identified as Application.
bot/exts/info/doc/_html.py:10:1: I202 Additional newline in a group of imports. 'from . import MAX_SIGNATURE_AMOUNT' is identified as Application Relative and 'from bot.log import get_logger' is identified as Application.
Running the exact command from the action ```
PS C:\Users\Chris\src\bot> poetry run flake8 --format='::error file=%(path)s,line=%(row)d,col=%(col)d::[flake8] %(code)s: %(text)s'
::error file=.\bot\api.py,line=9,col=1::[flake8] I202: Additional newline in a group of imports. 'from .constants import Keys, URLs' is identified as Application Relative and 'from bot.log import get_logger' is identified as Application.
::error file=.\bot\exts\info\doc_batch_parser.py,line=18,col=1::[flake8] I202: Additional newline in a group of imports. 'from . import _cog, doc_cache' is identified as Application Relative and 'from bot.utils import scheduling' is identified as Application.
::error file=.\bot\exts\info\doc_cog.py,line=26,col=1::[flake8] I202: Additional newline in a group of imports. 'from . import NAMESPACE, PRIORITY_PACKAGES, batch_parser, doc_cache' is identified as Application Relative and 'from bot.utils.scheduling import Scheduler' is identified as Application.
::error file=.\bot\exts\info\doc_html.py,line=10,col=1::[flake8] I202: Additional newline in a group of imports. 'from . import MAX_SIGNATURE_AMOUNT' is identified as Application Relative and 'from bot.log import get_logger' is identified as Application.
::error file=.\bot\exts\info\doc_parsing.py,line=15,col=1::[flake8] I202: Additional newline in a group of imports. 'from . import MAX_SIGNATURE_AMOUNT' is identified as Application Relative and 'from bot.utils.helpers import find_nth_occurrence' is identified as Application.
::error file=.\bot\exts\info\doc_init.py,line=3,col=1::[flake8] I202: Additional newline in a group of imports. 'from ._redis_cache import DocRedisCache' is identified as Application Relative and 'from bot.bot import Bot' is identified as Application.

pip install --remove-untracked and reinstall poetry lol
There is prooobably a better way to do it
Basically flake8-import-order doesn't get uninstalled while it should
poetry run pip uninstall flake8-import-order perhaps?
ahh
poetry has that now actually
poetry install --remove-untracked
Oh, great poetry has borked installing from cache in windows in the latest release
So now I need to delete my cache any time I want to install something ๐
Noice
Y'all update your poetries?
I installed it when setting up my PC and haven't though about it since lol
I went down to 1.0.8
I never upgrade those until they break
Perhaps I should install them using the Arch package so they get updated
Hey @gritty wind mind if I remake bot#1285? The fork is deleted and it's quite of out date ๐
not sure if you still had that patch that you mentioned around, if not i could take a look
It seems all that's needed it to change the regex you have now (?<!\n)\n(?!\n) to (?<!\n)\n(?![\n\u2003])"
since we use \u2003 in the docstrings we want to break
sir-lancebot | 10/16/21 15:28:40 - async_rediscache.types.base CRITICAL: can't get a pool connection as the RedisCache instance does not have a namespace.
sir-lancebot | 10/16/21 15:28:40 - root DEBUG: Error Encountered: NoNamespaceError - can't get a pool connection as the RedisCache instance does not have a namespace., Command: hacktoberfest stats, Author: TizzySaurus#9615, Channel: bot-commands
sir-lancebot | 10/16/21 15:28:40 - bot.exts.core.error_handler ERROR: Unhandled command error: can't get a pool connection as the RedisCache instance does not have a namespace.
sir-lancebot | Traceback (most recent call last):
sir-lancebot | File "/usr/local/lib/python3.9/site-packages/discord/ext/commands/core.py", line 167, in wrapped
sir-lancebot | ret = await coro(*args, **kwargs)
sir-lancebot | File "/bot/bot/exts/events/hacktoberfest/_cog.py", line 63, in stats
sir-lancebot | if await self.linked_accounts.contains(author_id):
sir-lancebot | File "/usr/local/lib/python3.9/site-packages/async_rediscache/types/base.py", line 260, in wrapper
sir-lancebot | result = await coroutine_object
sir-lancebot | File "/usr/local/lib/python3.9/site-packages/async_rediscache/types/cache.py", line 123, in contains
sir-lancebot | with await self._get_pool_connection() as connection:
sir-lancebot | File "/usr/local/lib/python3.9/site-packages/async_rediscache/types/base.py", line 110, in _get_pool_connection
sir-lancebot | raise NoNamespaceError(error_message)
sir-lancebot | async_rediscache.types.base.NoNamespaceError: can't get a pool connection as the RedisCache instance does not have a namespace.
```does anyone know how I can fix this? I'm not exactly sure what the code causing this error is
Did you enable USE_FAKEREDIS?
How are you creating the redis cache?
Yes
class Hacktoberfest(commands.Cog):
def __init__(self, bot: Bot):
self.bot = bot
# Caches for `.hacktoberfest stats`
self.linked_accounts = RedisCache()```
Ah, it needs to be a class attribute, rather than in the init
class ...:
linked_accounts = RedisCache()```?
Aight
Do you know why that is?
That seems to work, just fixing some other things
Please note that for automatic namespacing, this class MUST be created as a
class attribute to properly initialize the instance's namespace. See
`__set_name__` for more information about how this works.
from asyncredis cache
def __set_name__(self, owner: Any, attribute_name: str) -> None:
"""
Set the namespace to Class.attribute_name.
Called automatically when this class is assigned to a class attribute.
This class MUST be created as a class attribute, otherwise it will raise
exceptions whenever a method is used. This is because it uses this
method to create a namespace like `MyCog.my_class_attribute` which is
used as a hash name when we store stuff in Redis, to prevent collisions.
The namespace is only set the first time a class attribute gets assigned
to a RedisCache instance. Assigning a class attribute to an existing
instance will not overwrite the namespace and the additional class
attribute will act as an alias to the original instance.
"""
if not self._local_namespace:
self._local_namespace = f"{owner.__name__}.{attribute_name}"
Oh, it automatically gives it a name from the class and variable?
yea
Huh
that's if you want to use auto-namespacing
you could also do RedisCache(namespace="foo")
Should I use constants.Client.prefix over ctx.prefix (on lancebot)?
but that comes with a chance of collision
the only time they'd be different is if the user invoked lance via mention
if that matters, then sure use constants
Yeah, suppose I should then
๐
How exactly does detection of a valid hacktober pr thing work for .hackstats? It doesn't seem to being working
I have no idea how taxing that regex is, so I actually opted for "u2003" in ...
Meant to ping there @vale ibex
Though, thinking about it now
This isn't very time sensitive
So it's fine
Also yeah, feel free to take over
Xith poked me about that PR at least 10 times, I feel bad keeping him waiting
I can't imagine it would be more taxing that running all of our filter tokens on every message
since it just runs when you invoke help lol

OT: I'm still not used to your new-old PFP, keeps throwing me off
lol
It took me longer than i care to admit to find it again
Since I never actually saved it
lol did you save it this time
Hah see you back here in 4 months

@thorny obsidian do you have any idea how the .hackstats command is supposed to work? It doesn't seem to work anymore
.src hackstats
It looks like you're supposed to link your github acc to your user, and then it searched for closed PRs via the github api
.hackstats link ChrisLovering
@vale ibex, your GitHub username has been added
.hackstats
No valid Hacktoberfest PRs found for 'ChrisLovering'
yea
I have actually no idea how it works. I know there's a PR or an issue open to fix how it was finding it for last year.
you link your github acc, it pulls all your PRs from october this year, and looks if any have hacktoberfest-accepted label
and don't have invalid or spam
get_october_prs is the important function there
Does it check for repository topics?
Yea
There's still some code in there from last year, since that only happened after oct3
that isn't applicable this year
Yes, it does not work for me too. I have 2 PRs but this show none
Okay, good, so it's not just me
It seems this is the wrong way around https://github.com/python-discord/sir-lancebot/blob/210a97a4eee9a4babc26366f71d13edcd21b6f9c/bot/exts/events/hacktoberfest/hacktoberstats.py#L288-L296
bot/exts/events/hacktoberfest/hacktoberstats.py lines 288 to 296
if jsonresp2.get("names") is None:
log.error(f"Error fetching topics for {shortname}: {jsonresp2['message']}")
continue # Assume the repo doesn't have the `โhacktoberfest`โ topic if API request errored
# PRs after oct 3 that doesn't have 'hacktoberfest-accepted' label
# must be in repo with 'hacktoberfest' topic
if "hacktoberfest" in jsonresp2["names"]:
hackto_topics[shortname] = True # Cache result in the dict for later use if needed
outlist.append(itemdict)```
it's checking topics and continue if there aren't any
In which case I'll just move it and not fix; will leave the fixing up to someone else
there might be more, this function is quite complicated for what it's doing
Might be easier to just refactor it
Yeah, I was looking through the code and just couldn't really figure it out
I think the one I linked above is the issue your seeing
I think it's out of scope for this PR to be fixing it anyway
It doesn't even reach that far
The first if statement stops it
Ah
bot/exts/events/hacktoberfest/hacktoberstats.py line 230
if "message" in jsonresp:```
What is the resp?
It's either that because there's an error or https://github.com/python-discord/sir-lancebot/blob/210a97a4eee9a4babc26366f71d13edcd21b6f9c/bot/exts/events/hacktoberfest/hacktoberstats.py#L242 because there's no matching
bot/exts/events/hacktoberfest/hacktoberstats.py line 242
if jsonresp["total_count"] == 0:```
Before I changed stuff, it was the latter
It just never found anything
My laptop has died so can't really debug anymore
Hah no worries
@vale ibex addressed review in site#591
@thorny obsidian do you want to check out the current state of the guide before it's merged?
@tawdry vapor should docker-compose be capitalized as well?
Not sure. Look at Docker's documentation to see how they refer to it
The docs refer to it as "Docker Compose"
@tawdry vapor how do you define an extension?
The same way discord.py defines it. Those commands operate using load_extension, unload_extension,, etc
I suppose an extension is any module with a setup function that has a certain signature.
Yeah, I'm just thinking that extension is more accurate, but a cog is probably a more familiar term. I'll try just linking to the dpy page on extensions
You can write that it "reloads the cog" but you need to make it clear that the extension's name should be given rather than the cog's
Maybe mention the list command so users can get an idea of which extensions are available
They can be, not necessarily.
Extensions can lack cogs, and cogs can be defined outside extensions.
You can use extensions without cogs and vice versa
Though in practice I do not think we ever do this.
Can you just defer this explanation to "!help ext", or is the documentation not detailed enough for it?
!help ext
!extensions
Can also use: c, cog, cogs, ext, exts
Load, unload, reload, and list loaded extensions.
Subcommands:
!extensions list
Get a list of all extensions, including their loaded status.
!extensions load [extensions...]
Load extensions given their fully qualified or unqualified names.
!extensions reload [extensions...]
Reload extensions given their fully qualified or unqualified names.
!extensions unload [extensions...]
Unload currently loaded extensions given their fully qualified or unqualified names.
!help extensions reload
!extensions reload [extensions...]
Can also use: extensions r, reload
*Reload extensions given their fully qualified or unqualified names.
If an extension fails to be reloaded, it will be rolled-back to the prior working state.
If '*' is given as the name, all currently loaded extensions will be reloaded.
If '**' is given as the name, all extensions, including unloaded ones, will be reloaded.*
Maybe not
Pushed changes
If I'm working on a PR that's about restructuring, and all restructuring is complete but there's an issue with the code from before the restructure, am I okay to still PR knowing there's code in it that doesn't work?
Basically I'm moving all the hacktoberfest commands into one file, but .hackstats is currently broken and so the "restructured" version is still broken (since same actual code for it).
I've tried debugging the issue with .hackstats a bit but couldn't really figure it out, and don't particularly have the time to properly debug and fix it
Just clarify it in the PR
In fact, there's a little bit more refining I may need to do, so will wait until tomorrow
@cold island I can take over the scheduler PR if you and xith don't mind
Too be completely honest I think your two large PRs (enhancing incidents, mod schedule) should be finished before any other large PRs are taken.
Yeah, I was talking after that as I really wanted this feature to be available :D, even preserving unloaded cogs is there ^-^ and my issue on pydis/api. I will wait lol
yeah last year it shouldn't check for topics or hacktoberfest-accepted if the PR is from before Oct 3, this year I'm assuming the before Oct 3 shoudn't exist anymore which would mean it should show more than the valid PRs so I'm not sure why it isn't working
I definitely should've made more meaningful commit messages when I was working on this last year ๐คฆโโ๏ธ
it's checking for the hacktoberfest topic and if the request errored or if there aren't any topics at all we would continue/skip to to next one. Line 294 would just be checking the topic and then "caching" it for that repo
The whole thing can definitely be refactored, just that no one was reviewing the PR at the time so I was more focused on getting it to work well
currently debugging it
ok I found the problem: https://github.com/python-discord/sir-lancebot/blob/210a97a4eee9a4babc26366f71d13edcd21b6f9c/bot/exts/events/hacktoberfest/hacktoberstats.py#L229 seems like it's something wrong with _fetch_url that when I provide the params manually so the line is jsonresp = await self._fetch_url(base_url+"?q="+query_params, REQUEST_HEADERS, {}) it works perfectly
bot/exts/events/hacktoberfest/hacktoberstats.py line 229
jsonresp = await self._fetch_url(base_url, REQUEST_HEADERS, {"q": query_params})```
For it to be actually useful, I wanted it to handle arbitrary arguments in the rescheduling function. I wrote the code for it, but it required changing about half the code in that file, and overall both the implementation and the API felt somewhat clumsy to me, which is why I think I'd rather close it for now. Ultimately it's just a QoL thing and doesn't block anything.
Hmm alright, I would still go through it when I get sometime after finishing few of my PRs. If I get a good idea of the API and implementation, I would give it a go.
.bm hackstats issue
I'll see if that fixes it later tonight, thanks ๐
!remind 11h ^ if not already done
Your reminder will arrive on <t:1634496654:F>!
I could've opened a PR for it but it didn't feel like a neat fix so I'm digging into aiohttp source code to see if they changed something with the params. By the way FYI I've also added = {} to the headers and params arguments for _fetch_url so they're optional, in case you also get an error like I did.
Yeah, I did notice params was missing in 2 cases
Please don't PR though, since I'll have to completely rewrite anyway due to the restructure
If you just send the fix here I'll commit on my restructure branch and add you as co-author to give you credit
@rapid igloo
okay :)
do you want a patch or
it's just changing the line which I've said above and then making headers and params optional
I'd be looking for a fix inside (what's currently) the hackstats file
This will do if you aren't able to find anything "tidier" so to speak
yeah I'll have a closer look tonight (in like 4 hours for me)
np, it was me who did most (60%?) of the hackstats stuff last year anyway so I'm responsible :p
2.0 migration let's go!
please do jump into #763406158522220544 if you wanna hang out with us
๐ฅบ
ty
!echo am I alive?
am I alive?

!int e print(discord.version)
In [2]: print(discord.__version__)
2.0.0a```
@green oriole what theme is that?
k
i keep on changing my themes, don't like staying on one lol
what's going on over there
right now ๐
oh it was 10 minutes ago
we do a little bit of trolling
@vale ibex I'm here what's going on
are we breaking anything at this current time
LOL
hey man, you did it to me before
I'm taking my revenge
smh i wanna break stuff too
black magic
seems like it is working #user-log message
was static previews this or last week
frenzied typing from akarys
for reference
All the merged stuff:
Bot:
https://github.com/python-discord/bot/pull/1875
https://github.com/python-discord/bot/pull/1874
https://github.com/python-discord/bot/pull/1872
https://github.com/python-discord/bot/pull/1867
https://github.com/python-discord/bot/pull/1865
https://github.com/python-discord/bot/pull/1861
https://github.com/python-discord/bot/pull/1860
https://github.com/python-discord/bot/pull/1856
https://github.com/python-discord/bot/pull/1836
https://github.com/python-discord/bot/pull/1833
https://github.com/python-discord/bot/pull/1831
https://github.com/python-discord/bot/pull/1815
Sir-Lancebot:
https://github.com/python-discord/sir-lancebot/pull/908
https://github.com/python-discord/sir-lancebot/pull/904
https://github.com/python-discord/sir-lancebot/pull/889
https://github.com/python-discord/sir-lancebot/pull/860
https://github.com/python-discord/sir-lancebot/pull/857
poetry install --remove-untracked
PS C:\Users\Chris\src\bot> poetry install --remove-untracked
Installing dependencies from lock file
Package operations: 0 installs, 2 updates, 0 removals
โข Updating filelock (3.3.0 -> 3.3.1)
โข Updating discord.py (1.7.3 -> 2.0.0a0 https://github.com/Rapptz/discord.py/archive/45d498c1b76deaf3b394d17ccf56112fa691d160.zip)
Installing the current project: bot (1.0.0)
--remove-untracked Removes packages not present in the lock file.
from the man page
Sorry not man pages, I mean poetry install --help
These are all the PRs merged from the last week @vale ibex
what have we done
We speedy devs
wassup chris
bot#1871
bruh moment
is that your typing speed or random mashing?
@green oriole why do you use git switch instead of git checkout?
xD
xD
lol, most of it is docstring and function name refactor
my, how we can calculate
there's like 4 functional lines changed
I like how WA thinks we cannot do basic maths oh wait, we can't
bot#1876
@desert vessel why did you react to your own message
im jobless hehe
.wa 5-4
XD
.wa 69*69
@cold island Welcome, to Jurassic park
and there he goes
probably because I didn't spell it right
next project
github in the terminal
in rust
isn't gitui already there 
is it
Yeah, I didn't mean to enter Jurrasic park
lol
I mean like PR stuff, not local git stuff
@vale ibex wanna squash modlog ignore channels mods can't view pr
Oh nice
you've done nothing wrong
just wondering
5 commits, idk if you want to or not
yeah chris you broke github how dare you
@vale ibex wait I retract my approval
grammar incoming
oh no, i got merge conflcits
smh
enhance incidents
@vocal wolf can i squash down the PR? It is anyways going to be squash merged
which one
bot#1446
or you would do it while merging
let me stare at diff for 2 seconds
smol diff
nice verdict
words of wisdom, as always
whats wrong with pycharm ๐คฆโโ๏ธ
It's written in Java

lmao
only that line has got these weird errors ๐คฆโโ๏ธ
@short snow why did you resolve https://github.com/python-discord/bot/pull/1446#discussion_r730295509 ๐ค
Cause i am pushing that change right now
We agreed to only resolve stuff when the changes are pushed :\
Yeah ๐คฆโโ๏ธ
@green oriole shouldn't it be either "That's all for now; feel free..." or "That's all for now. Feel free...", instead of "That's all for now, feel free..."?
btw how do you squash all the commtis of a pr
The diff is short so i thought it would be okay
forgot to ping before
Better to squash before merging
@short snow https://www.notion.so/pythondiscord/Squashing-a-Pull-Request-191e8efa2fbb4d72840fd17ca37cf7fa
.bm
ty
this one
but parsed
and sorted
@green oriole archived libraries are a pain, huh
yeah exactly
which is the precise reason it got archived lol
the poor lad
YOU ARE WRONG, it is because the left side of the := walrus operator has to be a NAME and can't be anything else
caps lock alert
that was needed lol
I would usually prefer not to because it messes with the "Mark as viewed" stuff in GitHub. Usually it's fine to just squash when merging.
lmao
@vale ibex oh no don't say that
you said those words
"It should just work"
you've cursed us
what the heck did just happen 
nice, thankyou very much
task test
git merge upstream/main and that happened
gimme a minute, i reset it to my branch, doing it again (correctly)
Is there any tutorial for the 2.0 stuff?
i've found the docs for it, but that just describes the api
Yea, most of my learning was stumbling through the docs ๐ฆ
I just go through the release diff
i did the exact same thing but it works now ๐ except did poetry install before to get the new dep updates
@vale ibex nooooo you can't say thaaaaaaaaaat
Also: My triage report is 1/3 done.
I've forgotten the context already lol
"It should just work"
ah ๐
False*
sorry I've been doing too much rust lately
lol
I'm a bit rusty on python, if you will
blasphemy
@green oriole oof
precommit
bottom is travis
precommit is an actual ci system what you mean
!help tmute
Did you mean:
mute
tempmute
unmute
time
!help mute
!tempmute <user> [duration] [reason]
Can also use: mute
*Temporarily mute a user for the given reason and duration.
A unit of time should be appended to the duration.
Units (โcase-sensitive):
โy - years
โm - monthsโ
โw - weeks
โd - days
โh - hours
โM - minutesโ
โs - seconds
Alternatively, an ISO 8601 timestamp can be provided for the duration.
If no duration is given, a one hour duration is used by default.*
!help eval
!eval [code]
Can also use: e
*Run Python code and get the results.
This command supports multiple lines of code, including code wrapped inside a formatted code
block. Code can be re-evaluated by editing the original message within 10 seconds and
clicking the reaction that subsequently appears.
We've done our best to make this sandboxed, but do let us know if you manage to find an
issue with it!*
!tempmute <user> [duration] [reason]
Can also use: mute
*Temporarily mute a user for the given reason and duration.
A unit of time should be appended to the duration. Units (โcase-sensitive):
โy - years
โm - monthsโ
โw - weeks
โd - days
โh - hours
โM - minutesโ
โs - seconds
Alternatively, an ISO 8601 timestamp can be provided for the duration.
If no duration is given, a one hour duration is used by default.*
!help eval
!eval [code]
Can also use: e
*Run Python code and get the results.
This command supports multiple lines of code, including code wrapped inside a formatted code block. Code can be re-evaluated by editing the original message within 10 seconds and clicking the reaction that subsequently appears.
We've done our best to make this sandboxed, but do let us know if you manage to find an issue with it!*
@cold island should be fixed now, was probably me resolving before I pushed the commit and then doing something. I Will keep that in mind now ๐
Since we're on a merging spree, bot#1795 and bot#1863 are there if anyone is looking for a review ๐
lmao
i just reviewed one without seeing this
amazing timing
@timid sentinel squashing
yo what http_session.get(doc_item.url, raise_for_status=True) i never knew that was a valid kwarg
nice
raises an exception for 4xx and 5xx status codes
oh my god
Sir lance has more PRs open than bot
impossible
yes
at this point I have no idea if that's a joke
or they were actually serious
tell me you use discord too much without saying you use discord too much:
yeah
there's only one way
pog 2 cakes
jesus
12 PRs now
28 to 12 in a week
my god
doesnt feel real does it
can we beat the record low of 11
when you wake up from this dream xith you're gonna be so depressed
no I know this is real because I'm eating cereal at 3am
I have no voice at the moment but hey @green oriole @vale ibex :D
pog no mic
should be soon now
once things are resolved
also someone review https://github.com/python-discord/sir-lancebot/pull/745
(i mentioned bluenix's reviews rn btw)
Do we have Merge Sunday?
apparently haha
Jus to give xith the minimum amount of time for his triage update ๐
Let's do this monthly
Still no strip ๐
the meeting is just gonna be a triage update at this point
twiiter DM to pycares
This is when it all goes to shit
I do hope I wake up in time for the meeting
because it's currently 3am and the meeting is in like 8 hours
go sleep 
now
no I'm having fun
Yeah btw can we review the tag groups PR before the staff meeting?
Literally have went through that code so many times I am going cross eyed. Just needs quite extensive testing but I haven't gotten to that lol
3:07am @green oriole



