#dev-contrib
1 messages Β· Page 113 of 1
so the dynamic questions first take out the dicts from json
then formats those strings
for example, it gets "{} + {} equals?" and "{}", then formats accordingly using dynamic_id's corresponding function, which returns them back formatted (but in a dataclass instance)
i understand that this can be confusing. i will change the dataclass name to FormattedQuizEntry.
nononononononono
hm?
do you see what the issue is?
no, not really
i thought it's just that there's confusion
between quiz entries fetched from json and quiz entries returned by format funcs
@vocal prairie sent .0 at 4:03 PM
I accidentally hit my numpad, ignore me. :poof:
lmao
meanwhile, fix error is typing out an entire essay
Inside of the cog, you do the following things:
- parse the quiz entries from the JSON
- keep track of the game state
- send questions
- watch for answers
it's a little bit crowded.
So what I would do is extract the quiz entry parsing, formatting etc. into a separate place.
For example:
@dataclass(frozen=True)
class QuizEntry:
id: int
question: str
answers: List[str]
hints: List[str]
@staticmethod
def from_json(json_entry: Dict[str, Any]) -> "QuizEntry":
dyn_id = json_entry.get("dynamic_id")
if dyn_id is not None:
formatter = DYNAMIC_QUESTIONS_FORMAT_FUNCS[dyn_id]
q_template = json_entry["question"]
a_template = json_entry["answers"]
question, answer = formatter(q_template, a_template)
answers = [answer]
else:
question = json_entry["question"]
answer = json_entry["answer"]
id = json_entry["id"]
hints = json_entry.get("hints", []
return QuizEntry(id, question, answers, hints)
you can also imagine putting logic for deciding if an answer is correct into here.
but that's another non-small refactoring
right, but some of the code requires getting only the hints, and it's all scattered over the code CONFUSED SCREAMING
ah my head is imploding lol
yeah... what do you suggest i do? i want to leave the refactoring for another pr but that feels a bit irresponsible lol
it's just that this is kinda starting to go beyond my scope of knowledge (and determination and brain power)
It's fine to not do everything at once π
thank you so much for understanding. i'm pretty conflicted cuz one i want to get this pr merged so i can finally try it out on sir lancebot but two i don't want to decrease the code's quality just because i'm eager and i try to do everything as best as i could. so for now you think we can leave this refactoring?
sure
it's just important to keep track of what parts of code might need to be split up into more pieces
would be cool if we could have the code embedding but with diffs
wonder how hard that'd be
π
Im trying to do my testing for the bot. I have python 3.8 but it seems that I only have pipenv for python 3.7. Would this still work? If not how can I get pipenv for 3.8?
got it. so in the meantime would you mind re-reviewing the code? thanks!
done
Sourcery is... not happy.
maybe I should find how to extract methods from here
oh wait, this method doesn't even return anything?..
oh, I can't run unit tests without the database running?
that's... concerning
WOOOOOHOOOOOOOO EXAPOGGERS
one more core dev approval then we doneeee
sir-lancebot#726
Do you have any ideas on what could be broken up?
Also I like how the additions and deletions are close together
I am thinking of that right now
was busy with the other PR
So the cog is responsible for this, right?
.help
Refactoring 1. extract method from this block https://github.com/python-discord/sir-lancebot/pull/718/files/ae3ecb3ac46d90ebab1cb556fdc357848f45abb5#diff-2b56425c5b483af73a4eaf13d49e54eca49dd8338d3b3f6cad5201ecad8d0366R288-R299
Refactoring 2. extract method from this beast https://github.com/python-discord/sir-lancebot/pull/718/files/ae3ecb3ac46d90ebab1cb556fdc357848f45abb5#diff-2b56425c5b483af73a4eaf13d49e54eca49dd8338d3b3f6cad5201ecad8d0366R310-R397
Wait... why is it accessing the private paginator._linecount variable?
sounds fishy

ok. this method is pretty hard to refactor.
why is #dev-voice locked? can only contributors and above be in it?
this method is a good lesson on why mutable state makes it hard to reason about programs.
Pretty much, yeah. It's locked the same reason #412375055910043655 is locked
we need a dev-contrib vc, but open to everyone
- (inside the beast) Extract this into a method https://github.com/python-discord/sir-lancebot/pull/718/files/ae3ecb3ac46d90ebab1cb556fdc357848f45abb5#diff-2b56425c5b483af73a4eaf13d49e54eca49dd8338d3b3f6cad5201ecad8d0366R345-R373 that returns a list of strings. (doesn't really depend on many things)
And this is an example of how comments become stale. Someone inserted the try-catch in a rush.
I think everyone should be able to understand this method, right?
https://paste.pythondiscord.com/fuliyidosu.py
So this is what I came up with @sleek steppe:
https://paste.pythondiscord.com/uziyekanij.py
I think it became much more understandable. Haven't tested it, though π
So if you think it's worth encorporating, encorporate it (also change the quotes and stuff)
my CGSC (compulsive grammar & spelling correction) was acting up but then i saw this lmao
I'm old, I can use the archaic
apparently "encorporate" is a word, just old
lol π€£
I already ignore punctuation and grammar to such an extent where [i/e]ncorporate doesn't really matter
I'll try it in a few, thanks
approaching 200... the record is 229 iirc lol
That's not a record you should try to break haha

How do you set DEBUG to false in site? I'm trying to test PR #486, but I need to be able to see the error page.
I'm running with Docker on Windows, if that matters.
This is what is says right now
https://pythondiscord.com/pages/contributing/site/#2-environment-variables
DATABASE_URL=postgres://pysite:pysite@localhost:7777/pysite
METRICITY_DB_URL=postgres://pysite:pysite@localhost:7777/metricity
DEBUG=1
SECRET_KEY=suitable-for-development-only
STATIC_ROOT=staticfiles
I assume you'd set DEBUG to 0
yeeters. You can now mention voice channels
true lol, i said it as a joke because i didn't know my code had so much mini-flaws that there had to be 188 comments and reviews before it finally got 3 approvals (minus the core dev)
Notion api went into a public beta today
I have tested my new code is there any specific tests that i should try before subbitting the pull request?
This is @stable mountain?
@dusky shore
k thanks
Tests are only there on site and @stable mountain, not on lance
That would be like adding 15 more frames lmao
Ok. I made a new branch on my fork but when I go to start the pull request it is comparing it with the main branch of the parent repository. IS this ok?
Also i accidentally committed to the main branch of my clone. I think i reverted it but im not sure. It still shows up as a commit but I think it changed what branch it was on im not entirly sure.
Piskel has copy and paste
ik
I pushed you can see if i did it wrong there
Did you do this commit on purpose? https://github.com/python-discord/sir-lancebot/pull/733/commits/c4ee8a3bd9eeee61e3a2312f6c8a42f64858c8a6
If you want to fix the linting errors, you can reset to this commit https://github.com/python-discord/sir-lancebot/pull/733/commits/f8c98972e2341fe621bc9b569a4b2fe0d1c5f391
git reset f8c98972e2341fe621bc9b569a4b2fe0d1c5f391 --hard
And then you would force push the changes
git push origin branch_name -f
Also if you want a random true/false you can do this instead ```py
from random import random
if random() > 0.5:
do()
else:
dont()
I find it easier to read at least
I would do
from random import choice
func = random.choice((self.func1, self.func2))
yea, that makes more sense
func = (self.func1, self.func2)[random() > 0.5] to make you both happy
Eww had to use Windows update
LMFAO THIS
here's a smaller version of the gif for you so it takes up less space :)
watching both in sync
Can someone unload the latex cog?
Done
Ty
thank you!! :D
it went async for me :(
now i have to await it to go back in sync
@short snow what do you mean by "Full cog"? https://github.com/python-discord/sir-lancebot/pull/718#pullrequestreview-659533456
hehe
Well, uhh it has just too many of those, so I put full cog π
I can update that in a while
if you want
There aren't any cogs in that file though?
Ah ok
heads up
about to merge dewikification
need to manually override policy bot because it breaks on >250 commits (GH limitation)
noice

Nice
nice, is api now going to be removed from site? and be migrated to the fast api one?
not as part of these changes
This is dewikifiction
IE moving all pages into src control
there are three major changes being made to site: dewikification, api migration and logs migration
so this is 1/3
okay it's starting to go live now
and thats it right?
I'll clear upstream cache once it goes green
umm, i get the first 2, whats logs migration?
So wiki freeze is over?
eyy
Yo wait really?
It deployed I think
@exotic ember you're awesome
Fancy symbols
we need to update the discord icons on guides
it has deployed now, yes
ya we do
π Time to re-do our event pages
... after I finish my final π’
Good luck!
gl, the new guides are awesome, especially the table of contents π€
On the events page, this probably needs to be changed since it says 2020 is upcoming.
mhm, after I submit my final today I'll be going through and updating that stuff
events calender is a thing now? Or still to be done
Our event pages in general need a slight re-do. We're not advertising what we do as well as we could
And yeah, I need some sort of event calendar but I need to think about the best way to display it
a month-by-month won't necessarily be the best way
nah, Notion's is not that helpful since we don't have weekly events. We typically have a big thing each month
Yeah, a month wise, but in squares or line by line?
I have an idea of what I want, just need to make sure it's feasible
and the idea is?
yes
beautiful now i can fix a thing on site
this has annoyed me for 3 weeks :P site#488
config-default.yml line 19
use_fakeredis: false```
it merged
Guess it depends on which bot you look at
this is taken from the bot docs
config file considering it's just referred to a .env file strongly suggests that its referring to .env
You could change it to config.yml maybe?
not a bad shout
will do it in my PR toxic
(Dawn you're busy with forms and if you'd like to work on site front end stuff I have some tasks for you :3c)
yeah
We have channels for each of our larger projects that requires for back and forth convo
locked to staff only (mostly) for the time being since they're fairly important and most aren't ready to accept contributions from outside staff
Why is the privacy policy kept in Notion instead of on the site?
That's a question for joe
super fast for me to edit it, i'm the only one that ever touches the policy
pythondiscord.com - A Django and Bulma web application. - python-discord/site
ya, was just checking that was the site you were on abouut
which is the current website for the changes are live as of now?
Should bot#1580 be transferred to lancebot repo/closed?
closed imo
https://pydis.com has the changes
okay
no lol
Those are shields, aren't they?
we use github ones
sir_lancebot#733
I updated the code here but it says a failed one of the checks. I think that was when i pushed the faultily code and just has not been rechecked but im not sure could someone confirm please.
sir-lancebot#733
I'm guessing it's because you're a first time contributor
yes
noice
Oh ok.
I'm a maintainer 
There we go, sorry again its my first pull request π
It's a pretty decent PR, nice job!
Thanks
This is vaaaguely what I'd like to do for the events page. Although it may be too dynamic for what bulma + html can do. Still have to do research into to.
But I want it to be clear that we do a variety of events and I want to make sure we have a strong call to action for joining the events.
The following things should be clear:
- What events we host and when they happen
- How to join said events
- Basic + required info for events
Yeah, I'm debating it. On one hand I like that some events are on their own pages so we can maybe have a summary for each and have super detailed info there without it overloading this page. But some pages would then be super light or just link to an external website
but... but... my consistency! (That's a valid point though)
What about a brief description in the boxes at the bottom of the page than a button that expands the box with more info. It wouldn't be another page.
oooh, I do like that. I know for the code jams those are information heavy. So I might have it switch between a "view event" and a "show more" depending if it needs to be a whole separate page. That still keeps the experience relatively consistent though.
I can do some stuff now since I have nothing to do
How familiar are you with django/jinja + bulma?
Idk much Django/Jinja, but I've used Bulma.
But Django and Jinja are supposed to be rather straightforward, and they're not to hard to understand
This can be a learning opportunity! Essentially, I want to change how the event pages work. What I'm curious about is if my above mockup is possible within jinja + bulma.
I'm also looking for someone to make our code jam pages better: https://pythondiscord.com/events/code-jams/7/
Right now they don't really give you the info you care about in a good manner
It doesn't look impossible, not sure how easy it is though - yes, that was a really interesting comment
I want the important information to be clear:
- Dates
- Tech
- Qualifier repo
- Actual Jam repo
- Results with us showing it off nicely
- How to get involved next time
Right now it's just... blocks of text
I want to make it more scannable
So, there's a few tasks:
- Prototyping / Proof of Concept the main events page
- Mocking up changes to the specific code jam pages
- Prototyping / Proof of Concept the code jam pages
Sigh. I make my first PR to the site and it failed a lint test.
Btw, who's swfarnsworth on Github?
Steler
omg doxed
well once I submit my final today I'll be setting up the site for the first time too, it'll be a good learning opportunity
Don't forget to setup your hosts file π
The setup for me was update hosts file, run docker-compose up
submit my final today
What on earth are you doing on discord? π π π
Waiting for my computations to run
I can see if I can get a basic version of the home event page
listen, this is my prof's code as a base. I'm at the point where idgaf
Haha
that would be much appreciated!
Could add the env var from https://github.com/python-discord/bot/pull/1529 somewhere in the contrib guides if anyone's free
Yeah I could PR that
There's also an issue for the feature open for lancebot that's be good as a first issue for a new contrib
Actually someone else can do that I have no idea where pages are stored lol
I can do it
Lemme get the site up real quick
127.0.0.1 pythondiscord.local
127.0.0.1 api.pythondiscord.local
127.0.0.1 staff.pythondiscord.local
127.0.0.1 admin.pythondiscord.local
to save you some time
Are you referring to sir-lancebot#715?
sir-lancebot#706
ah
What do you think should go in the required and description parts of the table?
Required is when it's required
When the env var is required?
I'm not very familiar with the site
Yes
I mean, I guess it isn't required at any point, just if you want to change which loggers emit trace logs
What about the description for that one?
Are Lancebot's env vars the same (REDDIT_CLIENT_ID and REDDIT_SECRET)? I can update it in the same PR
And that's the ID of the Reddit webhook?
Yes
how shoot did I forget to add those in the reddit migration PRs
I'm not sure which section it would go in for the environment variable referencce
you couldn't π This is on the site, which was in a freeze
Probably Tokens/APIs
ah peace : D
@vocal prairie are you taking care of it or should I add em
alright π , thanks
Specifies which loggers emit trace logs through the listed names, should also mention the ! * prefixes that are commented somewhere in the pr
The description in bot#1529 should give enough info for that
I'd suggest mentioning that its a comma separated list
@green oriole tbh I was just burned out from trying to set up an environment from the bot yesterday and I gambled that a text-only change would be fine
Updated to say: "Comma separated list that specifies which β¦"
hey folks
nevermind lint failed
oh kosa added tests for redirect code SMH
only kosa would do this....
or was it ks...
smh, lint and test before pushing joe
I updated the Bot and Lance env vars on site, so I can pr that now
yeah it was ks
but it was kosa who changed the expected response to 302
I remember seeing this discussed in #dev-core yesterday I think
maybe a few days ago, the days have melted
yeah
Not sure why there's a test there, if we were intending to switch back after it all went well
oh well, easy fix
if sir-lancebot#706 is approved then I can implement that
okay CI passed :)
Done π
thanks
I'll checkout and test it now
I'm gonna give implementing the new git action concurrency options a go tomorrow
It'll allow us to cancel actions on a branch/PR if another commit comes in
Since we don't care about the old action at that point
nice
That's pretty fair. I'm going to bed right now, but if you need any help tomorrow it would be with pleasure.
Should the logging stuff go in bot/__main__.py or bot/__init__.py or another file?
Night night π
Night Akarys
π π
If it any consolation stel, the site is a lot easier to setup
You just need to update your hosts file and run docker compose
bump
Is there anything to do with logging in either of them right now?
I faintly remember there being something in one of the files
It should go in there imo
:+1:
hey folks, minor note: we're doing some tracing requests to try figure out if we've missed any paths to redirect with dewikification, but if anyone gets a 500 code or a cloudflare error please let me know so I can trace it down, cheers.
On the site, we use British English spelling, right?
yeah
A quick search and I've found some American that's slipped in there
but mostly British spellings
I bet it was Kat
(I'll send you virtual cookies if you can sneak in an american spelling or two)
It was definitely kat, they're all in the events path
:3c
I don't need browsers knowing more about me, so I'll have to pass.
pffft, Chris hasn't even taken me up on the cookie offer. My cookies are nut free unless you specifically request nuts =P
Sounds like a good deal to me
@eternal owl Let me know when you have time to chat re: User Event Management PR. I'd like to talk through what I'd like to convert it to and what would be easiest for you considering the existing codebase and work.
@thorny obsidian For the events page under the "Upcoming Events" section, would you prefer a list (top) or a table (bottom)?
Table Looks nice
.ext unload latex
:ok_hand: Extension successfully unloaded: bot.exts.evergreen.latex.
@patent pivot does lance's redis have peristence on?
shared
Cool
reason i ask is sir-lancebot#734
there's sir-lancebot#705
i read through every issue
and am blind
4th stupid fuck up ive done in the last day
just perfect
π dont feel bad about it
it's an interesting problem, i've been thinking about it for a while
because exts load before bot connects
in theory there's no reason cogs shouldnt be able to be loaded from the async def login function right?
cogs should make the assumption they may be loaded or unloaded at any time, so they shouldβ’οΈ be able to be loaded dynamically at any time
theres the problem of renaming cogs, the bot should alert when the cache holds a name that doesnt match any existing cog, since that indicates a potential problem, but it cannot alert before it connects, so that information has to be stored somewhere
i'm not sure, but I don't think it'd solve the problem entirely
whatever loads the cogs has to be able to tell the extensions manager that there was a problem
that information could live on the bot instance, but idk whether it should
In Django, is there a specification on how to link to a specific part of a page, or is it just the normal page/#id as it is in HTML?
are you talking about our site pages specifically, or django in general?
PyDis site specifically
you can just use a regular markdown link, ie [Python Discord Code of Conduct](/pages/code-of-conduct/), the link portion can be an absolute path starting at /pages/, or a relative path to the location of your page in the directory
then adding the id is just #id at the end, yeah
oh, you just use a regular <a> tag, but the href should use django's url template tag, see https://docs.djangoproject.com/en/3.1/ref/templates/builtins/#url
for reference, check out the navbar links at /pydis_site/templates/base/navbar.html
Got it, thank you!
https://github.com/python-discord/sir-lancebot/pull/595 really short PR needing core dev approval
I donβt think my comments were ever addressed
How does one run the site now
it feels like JS isn't being loaded for me
started using manage.py runserver 8000
have you tried hard refreshing?
Yes
I normally run on host using pipenv run start
It's mainly that because that's the default pycharm django runner
but I'll try that too
Alright that's working
I wonder if it's the debug flag
possibly
I'll give that a shot
Thank you
Does the content app have auto reloads?
It's possible it does and I just have it misconfigured
Because django does watch for changes afaik
Nevermind me
it reloaded, I just didn't see it
should be fixed now
Sure, lemme know you are free and we can talk about it
what does github-ref return on main
π
I'll throw that in a comment
hmm
shouldn't it return refs/heads/main
that's what the docs say
it'll work either way, but it makes the or redundant
hmmm
The branch or tag ref that triggered the workflow. For example, refs/heads/feature-branch-1. If neither a branch or tag is available for the event type, the variable will not exist.
I took this is it wouldn't be there
yeah it's redundant
I wonder what forks return
Fixed one, and left 3 more 
Gotta admit that's pretty funny
yea lmfao
@gritty wind I could remove the change in the emojis if needed, and keep only the .ttt log show <id> change
it basically moves this into a embed, so that it won't ping
@trim cradle aha you in green 
I wear green clothes almost exclusively in real life, so it's just as well
CONGRATS
oop caps
lol
Congrats on wearing green?
on
no, that's the right amount of hype
well no wearing some kind of color π€
getting the role and that it matches your green clothes
idk
The thrift store I used to go to made it easy. It was an lgbt thrift store and they used rainbow gradients for the clothes rack
That suit is black actually. Must be a lighting thing
anyway, I am curious what is this new project
@short snow what project are you talking about?
the one steler is leading
different projects
Vester is working on a video series
I think the site needs a better Game Jams page. It has one right now, but all it says is "Sorry, this page is not ready yet." I think that's up for grabs.
cc: @thorny obsidian
The Game Jam page can honestly be archived. With PyWeek we won't be doing our own separate one.
Okay. We still want a summary of the 2020 one though, right?
Also, is there a Code Jam logo that fits any year or time of year?
I don't think we have an overall generic generic code jam logo. I can try to come up with one over the next week or so. Feel free to use last year's
mmmmmm, we should probably include somethin4ge bute i THINK we can excluDe it for now
FIANCE Is very helpful with typING
lmao
I won't include it on the events page for now, but I'll leave the 2020 page. Do you want me to move the url out of /events/game-jams/game-jam-2020 to /events/game-jam as a record?
I gotta run to the grocery store before Seb's talk, so I'll be back later. And also yes, that sounds like a good idea
aha, looking at @dusky shore actions
it looks like each workflow will need to be name spaced
otherwise each workflow will cancel each other
and only 1 will run
o no
I'll do that now
@sleek steppe what was the decision on ```py
await ctx.send()
return
vs
```py
return await ctx.send()
The first
k
This seems like it'll work group: ${{ github.workflow }}-${{ github.ref }}
instead of manually setting the names
yea, it makes sense when you think about it
Hmm, IG we can merge this change and see if they get cancelled
Sure
Should I use GitHub's "fetch upstream" feature that pops up on my fork (site)?
Yea, that'll update your fork with changes from the main repo
ok, this looks promising
it looks like the sentry and lint flows run in parallel
and since they're dependencies for the build flow, it didn't run
there're a bunch of really old issues on lance which havent been touched in years, should some of them be closed?
Yes.
I've been meaning to go over all issues in both the sir lance and bot repo
just haven't dedicated time to it
Maybe we give it a few days on lance and then push to other repos?
this concurrency workflow thing that this
bot#1580 can be closed, it isn't even on the right repo
chris too fast
I'm sad, I don't have a sonic emote
lol
there are other issues like sir-lancebot#338 which im sure a bunch of people whould be happy to do, but has so much stuff attached like the previous 2 PRs that it might be a bit overwhelming to work on (it certainly is for me)
imo that could do with being closed, and a new issue opened with a tl;dr of the proposed implementation and comments from previous PRs
Um actually I'm not sure
who added it lol
me lol
I think when resolving merge conflicts I messed something up
I'll fix that
I have it in my review
dw
you'll be able to commit through the comment in like 3 years when I'm done
Ah Ok
I wonder if you could've just used sed to do like
almost all the single to double quote conversion
I'd rather not deal with the regex though
What does this mean? π€
which action?
It was lint but I don't see it anymore
sir-lancebot#425 can probably also be closed and I can just stick it in sir-lancebot#710
those are not thr right way round in the embed lol
I thought we said we didn't want that π€
not that i can see/recall
Well we talked about it here https://discordapp.com/channels/267624335836053506/635950537262759947/832329867743723550
@green oriole for https://github.com/python-discord/sir-lancebot/pull/718#discussion_r632977867 do you mean matches[0]?
Do I?
leftovers is a string
maaaaaaaaayyybe
Oh, I see it
There's a conversion
embed_title = "But there's another one!"
leftovers = str(matches)
embed_text = f"You have another match, this being {leftovers}."```
-> ```py
embed_title = "But there's another one!"
embed_text = f"You have another match, this being {matches[0]}."```
Yep
@gritty wind i think you missed this.
@sleek steppe finished review.
Thanks
I don't know
is my review mentioned toxic?
I feel like the review policy should be 1 staff/contrib approval since all core devs are staff π€
Oh true, I wasn't thinking lol
Yea π We always want at least 2 trusted people to approve a PR
and we want at least 1 core dev approval on everything
I'm guessing this is because sir-lancebot#705 isn't finished
.help latex
nice
And we often forget to unload lol
!s
!site
Can also use: s
Commands for getting info about our website.
Subcommands:
!site faq
Info about the site's FAQ page.
!site help
Info about the site's Getting Help page.
!site home
Info about the website itself.
!site resources
Info about the site's Resources page.
!site rules [rules]...
Provides a link to all rules or, if specified, displays specific rule(s).
!site tools
Info about the site's Tools page.
It's suggesting s
but then it appends the rest of your message
since it assumes those are parameters
yup
filters come first
if a message matches a filter then it's deleted before a command is ran
@sleek steppe I reviewed the things and the stuff again. I think I may just fall over and sleep after reviewing so many files lol
lmao, I'll check it out
oh no
You've became the same thing you swore to destroy
Ahh it's because I just took away the f string
Could we use a formatter like black in our pre commit config to convert single quotes to double?
We could, but we don't follow the same style guide as black, so it make things more difficult than not
I think we can configure it to format specific stuff
not sure tho
reviewing your PR now, let me set a stopwatch to see how long it takes, lol
Ah didn't realize that
is there a way to target non-modified files/lines during a review
No
If we used black to format stuff, I think even if we configured it a lot
it would still explode
and flake8 would be mad either way
also black really likes putting anything within brackets on different lines
for instance, ```py
embed = Embed(title="something")
would turn into
```py
embed = Embed(
title="something"
)
yep
@sleek steppe I've looked over as many things as I could. It looks fine to me.
thank you for the PR
sir-lancebot#718
I'll just commit your suggestions now
@clever wraith will you be doing something about this soon?
stuff and things need to be resolved.
are you merging it?
the spring cleaning?
ye
not atm, no
okay
Conflict #6
@vocal wolf one of the bots use black in its pre-commit iirc
which one?
Doesnt Lance?
let me check
Nope
pretty sure it doesn't
Pipfile lines 20 to 30
[dev-packages]
flake8 = "~=3.8"
flake8-annotations = "~=2.3"
flake8-bugbear = "~=20.1"
flake8-docstrings = "~=1.5"
flake8-import-order = "~=0.18"
flake8-string-format = "~=0.3"
flake8-tidy-imports = "~=4.1"
flake8-todo = "~=0.7"
pep8-naming = "~=0.11"
pre-commit = "~=2.1"```
^ those are all of the dev packages
I'm secretly using black somewhere. Don't tell anyone.
lol
hahaha
is it in ||[redacted]||?
@patent pivot Congratulations! You've been randomly selected to review the Spring Cleaning PR! This isn't a choice, you must do it now.
oh lord
lol
Lmao Xith is my fave domain lead now
:D
xith > *
which editor do you use @sleek steppe
right
so in pycharm, it is showing me some type annotation errors which could be useful for this PR
error highlights
and typos
We can't be strict with typing when using discord.py lol
I mean, incorrect function return type annotations, etc
I will include some of them in the review if not all
I have a question
if its regarding python/python libs, you can check out #βο½how-to-get-help, if its regarding our projects on github, you can ask here
!docs refreshdoc
It is 11pm
@vale ibex it moved to https://flask.palletsprojects.com/en/2.0.x/testing/
spring cleanup is merged TODAY
u have 45 minutes
Yeah
There are a couple of comments to solve from iceman, if you can please
Yep
I'm not entirely sure how to manage the docs, I think this is right, can someone double check? !docs setdoc flask https://flask.palletsprojects.com/en/2.0.x/ https://flask.palletsprojects.com/en/2.0.x/objects.inv
Seems correct
That looks right to me, but you might need the /api/ on the end
Since you want the docs to redirect to the API reference
According to the API, your request is malformed.

Sad
According to the API, your request is malformed.
π€
There is no logging anywhere
thatβs so helpful
I assume a validator isnβt liking it
You can see on the site log it is returning 400
I mean, we could run the validators manually
@eternal owl https://hackmd.io/@Y1bKKDhaRoeTMz_bW9jEOg/SkqibsT_O for the last comment, did you link the wrong thing?
ah
Does it return a 400 if it already exists?
We could del and add
What is its pk
package name
That could be it
!d
!docs deletedoc flask
Successfully deleted flask and refreshed the inventories.
Added the package flask to the database and updated the inventories.
@eternal owl do you wanna give it a last look? No obligation, we have enough reviews
!d flask
which
Looks like it's appending the /api/ itself
Spring cleanup
!docs deletedoc flask
Successfully deleted flask and refreshed the inventories.
Added the package flask to the database and updated the inventories.
I haven't done all files, but you can merge it I guess
This part of the documentation covers all the interfaces of Flask. For parts where Flask depends on external libraries, we document the most important right here and provide links to the canonical documentation.
since there are enough reviews
I'm gonna move over to spam
Thatβs up to you, I wouldnβt want you to feel like you lost your time before you didnβt submit your review
I think I'll test more so nothing's broken
;-;
I prolly won't find time or energy again, if I sit for a review, it will prolly be in like 24-48 hours π¬
you have 23 minutes (/s)
so you can go ahead and merge when ready, no need to wait for me
Alrighty, thanks for the review!
ye merge
push the button
only core devs can merge?
If I was able to merge then it would be green
I was presuming Ak wanted to do the honours lol
YES
true
nice finally π©
lol
its 3:12 AM here, tmw sunday, so no sleep time
nvm, its already sunday
@short snow reviewed the wiki guess PR, just a few changes and bugs detected.
you sure did haha
The conflicts on sir-lancebot#683 a big
||I think I can delete my fork now||
Maybe the object.inv had it already
wait did we merge cleanup ποΈ
Apparently
YES!
Yea, probably π
I should prolly do that too
I have been working on my fork forever
ah nice it got to 1500 additions/deletions before the merge
gn bois
pog
aye, sir-lancebot#738
The thing about optional is that if the converter is failed, is that it's silenced. Maybe the error should say "valid message" or something
done
initially i had that wording, then went down a massive rabbithole of trying to do smart converty stuff to make the converter work normally with that error and eventaually i gave up and went back to this
lol
that was rejected multiple times by joe
no it wasnt?
Well here's my take:
- The issue is approved
- Very few people use the bookmark command
- Very few people who use the bookmark command will use the reply
- Those few people are likely the ones who will turn off pings anyway
- It can be undone pretty fast anyway
lol
i think both of those are opinions
and ya, I think it's fine & am fine with it being implemented π
if I had objections the issue probably wouldn't be approved, or we would have discussed it
I was looking to merge those files, and keep them into separate classes just, I don't really like the jumping of contributors from file to file.

just launched lance in docker
why are both enabled
ik
just wondering why both are enabled
rather than the one
also its may
so neither task should have starting π€
oh wait
They aren't sending it
nvm i understand how it probably works
yeah
because in theory the bot could be on all year round
without ever turning off
so the tasks need to be there, just not sending?
bot/utils/decorators.py line 35
def seasonal_task(*allowed_months: Month, sleep_time: t.Union[float, int] = ONE_DAY) -> t.Callable:```
@fallen patrol ^
so if you set DEBUG=true in your .env file, you would see that it's sleeping for a day
ah.
So means scripts like that only work on 3.8??
Because I don't get that error when i run that Same script without the shortcut name
Or when I run it in the pipenv venv.
Wait I know the cause nvm
My system python 3.7
So when I do pipenv in the environment it's actually running on 3.7
Even if I also have 3.7 for the bot
try installing pipenv on your 3.8 environment, or try using pipx
I'm more curious why I get that error altogether
If I enter the venv and then try it it works fine even though it's a 3.7 venv as well
@vale ibex hey :P you around to quickly look over the boomark pr
sort of, request my review and I'll give it a look when I can
Hey @vale ibex if you've got time, I replied to your comment on the 3.9 PR
I saw and resolved π
schweet
Does 1.6 bring anything breaking?
I'm not against bumping
shouldnt break anything
Discord will take care of breaking it, don't worry
I could make a PR to bump dpy to 1.6
We subclass commands.Paginator which has adds a linesep kwarg which broke the paginator when we were upgrading to 1.7 in sir-lancebot#683
ahhh yea
... I cannot process this sentence, I need some coffee
should i put my pr on hold until we're beyind 1.6 so we dont need to ever have any annoying workarounds in the bot
Frick, I don't drink coffee
Yeah, probably
nahh, that was just a bad sentence lol
I think we should re-do sir-lancebot#683 with just the changes required to upgrade to 3.9 and bump versions
without the extra changes in there
will make it easier to review & test
We can change type hints etc as we come to them
I disagree, updating type hints is part of the upgrade
It also has a billion conflicts right now lol
We should migrate to the nicer interface
Honestly we should do some freezes when doing major reworks like that
If lance doesn't get any merge in a week, there's no harm
oh shit, I completely forgot about the PR
do you want to fix them? π
@short snow since your here, feel free...
oh god on god
My lord
Your reminder will arrive in 12 hours!
and die in peace
The ellipsis at the end makes it funnier lol
I think the type hinting shouldnβt be done in a PR
I don't like this because it leads to more huge PRs, we should stick to one overall change per PR and since typehints are non-breaking they don't need to be changed in the same PR as CI and dev tools amendments
This is spring cleanup all over again
Letβs just add this to the poetry PR
So itβs poetry and deps
That's just worse lol
If we really wish to we can generate a PR and make sure that they are enough people online to merge in like 42 minutes
I donβt think we should make an explicit effort to upgrade type hints
We gain nothing from it
And just waste time
Type hints can be upgraded implicitly over time
As you change code or add new code
Uniformising them is nice
Not really worth the time though
Perhaps, yeah
I like this approach
Have you gotten a chance to update the 3.9 poetry branch yet
We should really use feature freezes more
Not yet, I won't be able to look at it until the end of the week, but any staffer is free to take it over, just let me know
Having a 1k lines conflict is not okay
Hi, I'm having issues with LinePaginator. I get varying lines between pages, and not because there are no more items. I want to display 10 lines per page but can't get it to work, other than with ImagePaginator, but that feels like the wrong tool.
I think it's a good idea to just upgrade discord.py in the poetry PR
I hate the idea of using feature freezes, they should be a last-ditch effort when there are no other solutions.
Shutting down enthusiastic contributors isn't a good idea
We can always have ready to merge PRs but just hold them for a bit
but then we have several PRs which are just gathering conflicts
As long as we keep freezes short and spare, it should be alright in my opinion
It will generate conflicts either way
We just should aim not to have PRs which change hundreds of lines, that's the solution, we don't need to open a PR changing hundreds of type hints.
I'm not talking about this one in particular, but some PRs will have to generate big changes, like when we had the wiki freeze
We donβt usually do huge migrations
Some version bumps can also cause that (although here it doesn't since it is optional)
Those are special cases we should minimize
Even if we minimize them, we would run into one one day or the other
We should better be prepared next time we do
That's all I'm saying
Weβll handle those as the need arises
I donβt think weβll often be surprised by us having to make large migrations
Those things are usually known in advance, or donβt immediately go into effect
Yeah, we can handle them, I just don't think we should have a policy of using more freezes, iirc we've only ever used 2 in PyDis history for the move to Django and dewikification, and both of those were fairly annoying to deal with
if this is gonna be a fairly big thing can i just bump d.py to 1.6 in my pr so it works better, since it wont break anything
then whenever the poetry thing happens it can go to 1.7.2
bumping to 1.7.2 shouldn't be a large PR should it?
isn't the modification only in the paginatior
yeah it shouldn't be a large PR
we can probably put it in the poetry PR then since it's already touching dependencies
but yeah, I won't be able to get to that until Friday
joe when do your a levels finish?
so the update sir lancebot to 3.9.4 by me and toxic is not needed?
I'm gonna resolve conflicts in the poetry PR and commit a version bump
Make sure to delete the lock file
Thatβll update sub dependencies
(Also makes locking faster
)
I think I've done it
Friday lol
a week before mine 
Go study Alec smh
Iβve got a feeling something went very very wrong Chris
Oh I was looking at the wrong diff lmao
lmfao
kk so the poetry PR is ready
once this is merged we should do the deps bump
Hmmm, it's asking for builldtools to install multidict
Do we need to bump one of the deps?
I'd rather not have gcc in the image if poss
Can you post the traceback
We shouldnβt need them
Also post the result of the poetry graph
!paste
Pasting large amounts of code
If your code is too long to fit in a codeblock in discord, you can paste your code here:
https://paste.pydis.com/
After pasting your code, save it by clicking the floppy disk icon in the top right, or by typing ctrl + S. After doing that, the URL should change. Copy the URL and post it here so others can see it.
I was going to do them seperatly
Interesting
in different PRs to make it easire ot review & test
but now that I've bumped d.py to 1.7.2 it's fine
So I'll update the paginator now too
Ah that makes sense
I was wondering why we didn't need that on python
it already used 1.6
1.6 supports python 3.9 but 1.5 doesn't




