#dev-log
1 messages ยท Page 24 of 1
GitHub Actions run 9537118429 succeeded.
GitHub Actions run 9542464571 succeeded.
GitHub Actions run 9545978103 succeeded.
GitHub Actions run 9546210659 succeeded.
GitHub Actions run 9547813911 succeeded.
GitHub Actions run 9547824165 succeeded.
GitHub Actions run 9547875604 succeeded.
Connected!
GitHub Actions run 9549817463 succeeded.
baba4e4 Bump docker/build-push-action from 5 to 6 (#1552) - dependabot[bot]
GitHub Actions run 9553131834 succeeded.
GitHub Actions run 9553119758 was cancelled.
Connected!
GitHub Actions run 9556068557 succeeded.
GitHub Actions run 9556066477 succeeded.
GitHub Actions run 9556096612 succeeded.
GitHub Actions run 9556107125 succeeded.
GitHub Actions run 9559323343 succeeded.
GitHub Actions run 9561259626 succeeded.
Currently the thread archive state is only synchronized on startup. This means
that the archived flag on threads in the database slowly runs out of sync.
We should probably listen for
on_thread_update
or
on_raw_thread_update
here and update the database accordingly.
When starting metricity, the following deprecation warning (?) is printed to the log:
Warning: 'start' is an entry point defined in pyproject.toml, but it's not installed as a script. You may
get improper `sys.argv[0]`.
The support to run uninstalled scripts will be removed in a future release.
Run `poetry install` to resolve and get rid of this message.
We need to check whether we have to action this.
[python-discord/metricity] New branch created: chris/154/deprecation-warning
e68d83d Bump ruff from 0.4.8 to 0.4.9 (#152) - dependabot[bot]
[metricity] Branch chris/154/deprecation-warning was force-pushed to `4cb410c`
We listen to the former of the two events here https://github.com/python-discord/metricity/blob/main/metricity/exts/event_listeners/guild_listeners.py#L56-L62
Have you seen an example a thread's archive state not being updated? we might need to start listening to the second if so.
I didn't bother listening to the second event originally as my understanding was an active thread should always be in the bot's cache, so archiving a thread should mean that it always triggers the first event.
[metricity] Branch chris/154/deprecation-warning was force-pushed to `4ad841e`
Thanks for the quick reply!
We listen to the former of the two events here https://github.com/python-discord/metricity/blob/main/metricity/exts/event_listeners/guild_listeners.py#L56-L62
I missed this, thank you for linking to it.
Have you seen an example a thread's archive state not being updated? we might need to start listening to the second if so.
Yes. I've done some data exploration on lovelace in metricity earlier
today, and found this:
metricity=# SELECT COUNT(*) FROM thre...
Thank you for the quick fix!
GitHub Actions run 9569749939 succeeded.
b49dd53 Ensure thread archive state is also synced when... - ChrisLovering
[python-discord/metricity] New branch created: sync-archived-threads
currently we will synchronize each of the current threads on the guild on any thread update
Yeah just spotted this too, seems quite heavy handed, but as you say it's still a small number of queries as far as postgers is concerned
Wouldn't this happen for a thread in a channel with no category?
That's true, I'll remove the case entirely
[metricity] Branch sync-archived-threads was force-pushed to `9219d84`
Thanks! I assume the bug was the lacking support for forum channels in older versions then?
Thanks! I assume the bug was the lacking support for forum channels in older versions then?
Nah, the bug was that sync_thread_archive_state wasn't called when syncing channels, it was only called on startup.
The other part of this change isn't relevant to this issue, but added confusion to the function due to now being relevant anymore now that d.py supports forum channels
(and sync_thread_archive_state is needed because the db_thread.archived = thread.archived line was not sufficient as archived threads are not in guild.threads)
When metricity starts up and synchronizes the users, all users temporarily have
their in_guild field set to false.
From looking at the code I am currently unsure how this can happen. As far as I
understand, the complete upsert is run in a transaction that is committed at
the end of each individual insert.
Demonstration as taken during a metricity restart (whilst User upsert:
messages can be seen in the logs):
metricity=# SELECT in_guild, COUNT(*) FROM users GROUP BY in_guild; ...
Looks like it's currently written to set all to not in the guild, then set those in the guild to true after
https://github.com/python-discord/metricity/blob/e68d83de9bb3027085c4f72e3da4699eefdc1546/metricity/exts/event_listeners/startup_sync.py#L39
[metricity] Branch chris/154/deprecation-warning was force-pushed to `bff7586`
Thank you for the quick fix!
[python-discord/metricity] branch deleted: chris/154/deprecation-warning
[python-discord/metricity] branch deleted: sync-archived-threads
[python-discord/metricity] New tag created: v2.6.2
ahhh, I missed that.
Could we maybe do the whole update operation in a transaction or would
that bust some limits with regards to PostgreSQL's transaction memory?
Maybe alternatively we could collect the IDs of all users where we set
it to true and then do a single (batch of) updates after the initial
sync to set in_guild=False for anyone who's not in that set.
At the moment no messages are inserted for the time when metricity is not available, rendering statistics during that time empty.
It would be nice if metricity could backfill this data on startup. For example, we could check something like SELECT channel_id, max(id::int) FROM messages GROUP BY channel_id, iterate over the history of each channel using after=message_id, and then insert any messages. From my understanding duplicate inserts should mostly be a no-op (possibly needing a `ON C...
7389936 Improve user in-guild sync process - ChrisLovering
[python-discord/metricity] New branch created: improve-user-in-guild-sync
Closes #157
Previously we set all users in_guild to False, and relied on users being set back to in_guild when iterating through guild.members
However, this caused two problems
- For a short window a users in_guild status was incorrect
- It required an update for all users in_guild to be sent to postgres to update in_guild back to True.
This diff changes that, so instead only users who are not found in the guild have in_guild set to False
https://github.com/python-discord/metricity/pull/159 sems like a way we could fix this. I haven't been able to test that postgres is ok about serialising that many strings in a single query though.
sqlalchemy.exc.InterfaceError: (sqlalchemy.dialects.postgresql.asyncpg.InterfaceError) <class 'asyncpg.exceptions._base.InterfaceError'>: the number of query arguments cannot exceed 32767 will need to relook at this approach
My only thoughts on how to make the above PR work would be to create a TEMPORARY table with ON COMMIT DROP and somehow bulk insert all in-guild users into it.
It might be easiest to select all in guild users from the database and then do db_in_guild - guild.members and mark them as not in guild with another query.
It's not quite as nice as doing it all on the database but in practice I don't think it makes a difference for our case.
[branding] Branch improve-status-embed-workflow was force-pushed to `902162e`
[python-discord/branding] branch deleted: improve-status-embed-workflow
GitHub Actions run 9584301551 succeeded.
It might be easiest to select all in guild users from the database and then
dodb_in_guild - guild.membersand mark them as not in guild with another
query.
Won't this run into the same parameter issue?
I have an alternative idea, although it might be a bit crazy:
First we sort the list of user IDs to update ascending. Then we move the data in chunks, with special handling for the first and last chunk to incorporate an update for anything outside our known range as well.
Pseudocod...
My suggestion was to do the comparison against guild.members on the Python side rather than the database site, so basically what we currently do but only change the users we need to. Something like this:
async with async_session() as sess:
in_guild_users = await sess.execute(select(models.User).filter_by(in_guild=True)).scalars().all()
guild_member_ids = {member.id for member in guild.members}
for user in in_guild_users:
...
GitHub Actions run 9595501838 succeeded.
GitHub Actions run 9597510652 succeeded.
GitHub Actions run 9600050956 succeeded.
This is an excellent and super clean implementation - thank you very much!
[python-discord/site] New comment on pull request #773: Add guide for working with Python on Windows
I prefer getting the user to have python on ther PATH for the reasons I mention here https://github.com/python-discord/site/pull/773#discussion_r1160869869, so personally I'm quite happy with leaving the PR mostly as is, though I could make some of the changes to make py a bit more visible as an option.
I can't really comment on this as I do not run Python on Windows but your reasoning makes sense to me, and we should leave it mostly as is.
GitHub Actions run 9608812429 succeeded.
Connected!
GitHub Actions run 9611647200 succeeded.
GitHub Actions run 9611660060 succeeded.
Connected!
GitHub Actions run 9611654350 succeeded.
Connected!
GitHub Actions run 9611668232 succeeded.
GitHub Actions run 9611696691 succeeded.
GitHub Actions run 9611664303 succeeded.
GitHub Actions run 9611702849 succeeded.
Connected!
GitHub Actions run 9611702458 succeeded.
GitHub Actions run 9611731627 succeeded.
3f64ea9 Bump ruff from 0.4.8 to 0.4.10 (#1557) - dependabot[bot]
baba4e4 Bump docker/build-push-action from 5 to 6 (#1552) - dependabot[bot]
88f665a Bump sentry-sdk from 2.5.1 to 2.6.0 (#1556) - dependabot[bot]
07ccfcb Bump urllib3 from 2.2.1 to 2.2.2 (#1555) - dependabot[bot]
a8f5094 Bump taskipy from 1.12.2 to 1.13.0 (#1554) - dependabot[bot]
3f64ea9 Bump ruff from 0.4.8 to 0.4.10 (#1557) - dependabot[bot]
d66977a Add poetry-plugin-export plugin to fix CI warni... - wookie184
[python-discord/sir-lancebot] branch deleted: fix-poetry-export-warning
GitHub Actions run 9611750143 was cancelled.
Connected!
GitHub Actions run 9611743375 succeeded.
GitHub Actions run 9611761538 succeeded.
Connected!
GitHub Actions run 9611761991 succeeded.
Connected!
GitHub Actions run 9611773897 succeeded.
GitHub Actions run 9611876568 succeeded.
GitHub Actions run 9611942786 succeeded.
abe62e2 Skip line if no match against inventory line regex - jb3
[python-discord/bot] New branch created: jb3/doc-parser/ignore-bad-lines
We currently have an issue on bot (BOT-3VH on Sentry) which is failing to parse
the sympy docs due to a malformed object inventory.
This looks to be caused by multi-line figure descriptions or something similar
which are creating lines that do not match our regex.
Ignoring these lines is fine as they likely provide no additional context
anyway, and the relevant symbol is still parsed as normal and links to the
original docs.
GitHub Actions run 9615543605 succeeded.
d04cd1a Bump urllib3 from 2.2.1 to 2.2.2 in the pip gro... - dependabot[bot]
7ba415f Skip line if no match against inventory line re... - jb3
[python-discord/bot] branch deleted: jb3/doc-parser/ignore-bad-lines
GitHub Actions run 9616328322 was cancelled.
Connected!
GitHub Actions run 9616334702 succeeded.
388572a Update internal eval & latex to use the new pas... - ChrisLovering
[python-discord/sir-lancebot] New branch created: use-new-paste-service-API
Relevant Issues
Description
Did you:
- [ ] Join the Python Discord Community?
- [ ] Read all the comments in this template?
- [ ] Ensure there is an issue open, or link relevant discord discussions?
- [ ] Read and agree to the contributing guidelines?
GitHub Actions run 9619573918 succeeded.
Hi Chris! Thanks for the contribution!
Please could you complete the checklist in the issue body before we can review and approve this PR. Thank you in advance!
Hi Chris! Thanks for the contribution!
Please could you complete the checklist in the issue body before we can review and approve this PR. Thank you in advance!
Ah, the checklist, a true masterpiece of human achievement! Because who wouldnโt want to spend their precious time meticulously checking off items like "Did you use a semicolon?" or "Did you sacrifice a rubber duck to the coding gods?"
Fear not, dear Joe! My contribution is like a diamond in the rough, waiting for the m...
BREAKING NEWS: Universe narrowly escapes doom! Local hero Chris, armed with a checklist and questionable taste in rubber duck sacrifices, single-handedly prevents cosmic collapse. We salute you, Chris! Now, onto less dramatic matters โ your PR. Let's see if this code can survive a review from yours truly, the world's leading authority on (mostly) helpful feedback. Prepare for battle (with comments, not rubber ducks)!
[python-discord/bot-core] New branch created: jb3/update/discord.py-2.4
Upgrades discord.py to 2.4, this will allow for polls to be visible to our bots
and, when deployed to bot, should allow the restoration of the polls permission
state after a channel has been silenced.
Once merged, we should bump the project to version v11.1.1 (no breaking changes
looking at v11.1.0..main, just dependency bumps, but we could also go for
11.2.0).
We should also merge the other dependabot PRs that are open before releasing a
patch version.
8968d94 Upgrade discord.py to 2.4 - jb3
67092d8 Bump dev deps to latest - ChrisLovering
3fe3eae Bump project version to 11.2.0 - ChrisLovering
[python-discord/bot-core] branch deleted: jb3/update/discord.py-2.4
[python-discord/bot-core] New tag created: v11.2.0
03157db Deploying to docs from @ python-discord/bot-cor... - ChrisLovering
Changed the status to planning as it's not clear to me what needs to be done here. AFAIK there's nowhere in the bot where we ban in a loop, so there's nowhere obvious to replace.
For manual bans using int eval we could use it, but I'm not sure it'd be worth it for a few reasons:
- We've managed so far using the single ban api, even for very large raids.
- Normally we intentionally put in a sleep between bans to make them run slower so we can cancel if we made a mistake.
- It would be co...
GitHub Actions run 9638768462 succeeded.
GitHub Actions run 9640216126 succeeded.
GitHub Actions run 9643671041 succeeded.
Connected!
GitHub Actions run 9643943730 succeeded.
Connected!
Connected!
Connected!
Connected!
Connected!
Connected!
Connected!
Our applications are resilient and reliable.
oUr APpLIcATIONS ARe resIlient ANd rElIAble.
This command will operate similarly to the !modpings command in Python. The goal is that anyone with the Events Team role can run this command. It will either remove the "Code Jam Support" role or add it. ... That's it.
Spec:
- Only someone with the Events Team Role or an Admin should be able to run this role. Fail silently for everyone else
&cj support onwill apply the role&cj support offwill remove the role- The role id to use is: 1254657197535920141
Hi @vivekashok1221 i would like to work on this issue. I went through modlog.py I guess we need a bit changes in it to make this work.
Description
Add a devcontainer configuration to the repository to make setting up the development environment easier and more consistent for all contributors.
Reasoning
A devcontainer ensures that all contributors have a consistent development environment, reducing setup time and potential errors. This makes it easier for new contributors to get started and helps maintain productivity.
Proposed Implementation
- Create a
.devcontainerdirectory in the repository. - A...
Hello, I would like to work on this issue.
Relevant Issues
#1497
Description
When the hangman command times out, reply to the original message saying that you lost, the game timed out, and what the word was.
Did you:
- [x] Join the Python Discord Community?
- [x] Read all the comments in this template?
- [x] Ensure there is an issue open, or link relevant discord discussions?
- [x] Read and agree to the [contributing guidelines](https://pythondiscord.com/pages/contributing/contrib...
GitHub Actions run 9664078464 succeeded.
Description
Update badge on README file.
Reasoning
The current badge link is not functioning properly.
Proposed Implementation
Replace the non-functional badge URL with a new working badge URL
Would you like to implement this yourself?
- [ ] I'd like to implement this feature myself
- [x] Anyone can implement this feature
Connected!
GitHub Actions run 9665519492 succeeded.
GitHub Actions run 9665767933 succeeded.
dade8b0 Bump docker/build-push-action from 5 to 6 in th... - dependabot[bot]
GitHub Actions run 9679838564 succeeded.
Fixed issue : #3077
Now we can check the replies to a deleted message to provide a better context as well as, if the deleted message is a reply to some parent message, it will show the respective parents message it was replying to in #mod-log channel
References :
Parent Message delete will provide the replies to that message (Limit is set to 10)
Reply Message delete
5cfed">
GitHub Actions run 9679861571 succeeded.
Hey @typhonshambo !
Our contributing guideline states that an issue should be approved and assigned by someone with the core-dev role before a pull request can be made (I'm not a core-dev btw)
For getting approval, drop a message in the #dev-contrib channel of our server.
I've lightly skimmed through the code and left a few comments.
But there are two main things that I feel should be discussed:
- Do we really need
gather_replies()? i.e, should we really be displaying the messages that are in reply to a deleted message? It is a very useful information to show but I'm not sure if it's worth combing through the channel's message history every time a message gets deleted.
(BTW when I made the issue, I only had adding a link to the message being replied...
async def gather_replies(self, message: discord.Message) -> list[Message]:
If you don't need this newline, you should remove it, not comment it out.
content = reply.clean_content
if len(content) > 10:
content = content[:10] + "..."
reply_lines += f"\n- {format_user(reply.author)}[Jump to message]({reply.jump_url}) {content}"
You should shorten resolved_message_text + resolved_message (while ignoring the length of the jump url) . Usernames can be loooong.
Also: Is username a necessary information? A mod can find the username by clicking on the message.
Although, yeah, it is nice to see the name of the person being replied to within the log embed itself.
We don't need this information since the reply will be in the same channel as the deleted message.
Unless I'm missing some edge case (probably with threads but it looks like you can't reply to the starting message in a thread within that thread itself anyway)
alright @vivekashok1221! ill message there thanks for your response
GitHub Actions run 9683532822 succeeded.
No! I think its not necessary to provide the channel name, rather i think we should to keep the username because maybe it give a bit of the context who posted it without opening the message.
I'm not sure whether to keep it or remove it. I think keeping it will make it bit easier for the mod to check who posted it without the need of clicking it.
I'll add the shortener for the username!
[python-discord/sir-lancebot] New branch created: br/gh1560
This is a possible implementation of #1560
GitHub Actions run 9685352201 failed.
GitHub Actions run 9685383297 succeeded.
@hasty island what is this branch name!!!!!!!
GitHub Actions run 9685797638 succeeded.
GitHub Actions run 9691444960 succeeded.
GitHub Actions run 9691990103 succeeded.
Connected!
GitHub Actions run 9695061310 succeeded.
[python-discord/king-arthur] New branch created: devops-motivation
fe03436 Send daily motivation to the devops team - ChrisLovering
LGTM! Hopefully an easy team morale booster!
[python-discord/king-arthur] branch deleted: devops-motivation
GitHub Actions run 9702486306 succeeded.
GitHub Actions run 9702515559 was cancelled.
GitHub Actions run 9702544124 succeeded.
GitHub Actions run 9702583617 succeeded.
[python-discord/sir-robin] New branch created: modernise
This updates the repository to be more inline with our other bots.
I'd suggest reviewing commit-by-commit.
GitHub Actions run 9703729800 failed.
GitHub Actions run 9703745811 succeeded.
21bcc00 Add codejam suppport command group to toggle Co... - AbooMinister25
[python-discord/sir-robin] New branch created: cj-support-command
Adds a command group called support to the code jam cog to enabling toggling of the Code Jam Support role for admins and event team members.
Closes #126
GitHub Actions run 9704297642 succeeded.
1f9a403 Add codejam suppport command group to toggle Co... - AbooMinister25
[python-discord/sir-robin] branch deleted: cj-support-command
GitHub Actions run 9704384607 succeeded.
Connected!
GitHub Actions run 9704376626 succeeded.
[python-discord/site] New branch created: hsp/cj24
Adds information about Code Jam 2024
GitHub Actions run 9709003849 succeeded.
GitHub Actions run 9709059890 succeeded.
GitHub Actions run 9709121222 succeeded.
GitHub Actions run 9709336869 failed.
GitHub Actions run 9709688190 succeeded.
fcd7654 Bump sentry-sdk from 2.6.0 to 2.7.0 (#1564) - dependabot[bot]
f4c2876 Bump coverage from 7.5.3 to 7.5.4 (#3102) - dependabot[bot]
Connected!
GitHub Actions run 9710863140 succeeded.
Connected!
GitHub Actions run 9710850383 succeeded.
GitHub Actions run 9710851586 succeeded.
GitHub Actions run 9710877125 succeeded.
GitHub Actions run 9711016518 succeeded.
GitHub Actions run 9716550181 succeeded.
GitHub Actions run 9725914651 succeeded.
I assume most PyDis maintainers already have an incredibly large flurry of Dependabot notifications. There is a problem there IMO, which is that GitHub itself offers no way to filter notifications based on the author, so you need to do this on your end somehow. I do this via a Sieve script, but I'm not sure other maintainers have similar solutions and I think it would be beneficial to maybe group updates into smaller PRs. Do you think we should use something like that here?
I amde sure not to add python dependency dependabot here, since it's jsut going to spam PRs, this config will just bump CI and DOckerfile deps, which are rarer
[python-discord/sir-robin] branch deleted: modernise
Connected!
GitHub Actions run 9726177087 succeeded.
I made sure not to add python dependency dependabot here, since it's just going to spam PRs, this config will just bump CI and Dockerfile deps, which are rarer
Ah, I did not see that. That sounds good. Thank you!
05e7053 Improve user in-guild sync process - ChrisLovering
[python-discord/metricity] New branch created: in_guild-sync-perf-improvement
Previously we set all users in_guild to False, and relied on users being set back to in_guild when iterating through guild.members
However, this caused two problems
- For a short window a users in_guild status was incorrect
- It required an update for all users in_guild to be sent to postgres to update in_guild back to True.
This diff changes that, so instead only users who are not found in the guild have in_guild set to False.
The bottleneck for this query is the number of users...
99ddabc Bump ruff from 0.4.9 to 0.5.0 (#164) - dependabot[bot]
[metricity] Branch in_guild-sync-perf-improvement was force-pushed to `b8a6198`
c298d9a Add dependabot config for docker & CI - ChrisLovering
Shouldn't the condition be if user.id _not_ in guild_member_ids, since
guild_member_ids contains the users that are on the guild? From my
understanding this currently sets in_guild=False for all users that
are on the guild (and found in the queryset).
Also, nitpicking but it would be nice to remove the space before %d in
the log.info line.
[metricity] Branch in_guild-sync-perf-improvement was force-pushed to `e47b967`
[metricity] Branch in_guild-sync-perf-improvement was force-pushed to `c2fe170`
Shouldn't the condition be
if user.id _not_ in guild_member_ids, sinceguild_member_idscontains the users that are on the guild? From my understanding this currently setsin_guild=Falsefor all users that are on the guild (and found in the queryset). Also, nitpicking but it would be nice to remove the space before%din thelog.infoline.
Yeah, should have marked this as draft as there were a few more things I wanted to do. I've pushed some new commits and updated the PR descr...
[metricity] Branch in_guild-sync-perf-improvement was force-pushed to `db22e38`
GitHub Actions run 9742678709 succeeded.
Chris, this is fantastic, and changes everything. Thank you for everything you do.
769e9a9 Add dependabot config for docker & CI - ChrisLovering
7898288 Improve user in-guild sync process - ChrisLovering
f69fb12 Improve user in_guild sync query time by only l... - ChrisLovering
db22e38 Add debug performance logs for in_guild sync - ChrisLovering
95d2227 Merge pull request #165 from python-discord/in_... - jb3
[python-discord/metricity] branch deleted: in_guild-sync-perf-improvement
[python-discord/metricity] New tag created: v2.7.0
GitHub Actions run 9765063812 succeeded.
GitHub Actions run 9765486121 succeeded.
GitHub Actions run 9765560333 succeeded.
GitHub Actions run 9765582871 succeeded.
Can confirm it works as expected now, no more dips are visible in statistics.
Thanks for the fix!
GitHub Actions run 9765857885 succeeded.
<strong>The core of your project must focus on and incorporate Discord Applications.</strong>
GitHub Actions run 9767797862 succeeded.
I like having these, but they currently look like this in dark mode:
<img width="801" alt="image" src="https://github.com/python-discord/site/assets/50042066/8039f1c5-4b30-43c2-ac83-47169b1f11c5">
<img width="800" alt="image" src="https://github.com/python-discord/site/assets/50042066/676390f9-211f-464e-8fb3-ae7a1f71d475">
It might make sense to have background color for this callout adjusted in settings.py to be a little easier to read, e.g. "success": "#31815D",.
How about we use the new logo and update the title to match the event title here?
diff --git a/pydis_site/templates/events/scheduled_events.html b/pydis_site/templates/events/scheduled_events.html
index 0e70de6e..8acee557 100644
--- a/pydis_site/templates/events/scheduled_events.html
+++ b/pydis_site/templates/events/scheduled_events.html
@@ -3,12 +3,12 @@
<article class="media">
<div class="media-left">
<p class="image is-64x64">
- ...
Looks great! Two suggestions.
GitHub Actions run 9772690982 succeeded.
GitHub Actions run 9776004884 succeeded.
GitHub Actions run 9777820578 succeeded.
39801cf Add new field for capturing timezones - jb3
[python-discord/forms-frontend] New branch created: jb3/components/timezone-field
Add a new field for automatically capturing the users timezone.
This should be fairly reliable on most browsers and timezones, I've included all recognised UTC timezones from Wikipedia. Of course, the component allows for manual overriding if the user is not correctly categorised.
[forms-frontend] Branch jb3/components/timezone-field was force-pushed to `0b697ff`
[forms-frontend] Branch jb3/components/timezone-field was force-pushed to `2f24f22`
a069df4 Add timezone question type - jb3
[python-discord/forms-backend] New branch created: jb3/fields/timezone-question
Adds the question type for timezone fields
Needed for python-discord/forms-frontend#632
[forms-backend] Branch jb3/fields/timezone-question was force-pushed to `bbc4607`
Connected!
GitHub Actions run 9781505676 succeeded.
0ff1283 Better format copy about timezones - jb3
[forms-frontend] Branch jb3/components/timezone-field was force-pushed to `1b25aa2`
Also for reference, the display if for some reason the client reports a non-recognised UTC offset.
ad36098 Update site for Code Jam 2024 (#1353) - ShakyaMajumdar
[python-discord/site] branch deleted: hsp/cj24
GitHub Actions run 9782121226 succeeded.
GitHub Actions run 9796172840 succeeded.
cdfd0bd Bump ruff from 0.4.10 to 0.5.0 (#1565) - dependabot[bot]
4498481 Bump sentry-sdk from 2.7.0 to 2.7.1 (#3108) - dependabot[bot]
Connected!
Connected!
GitHub Actions run 9800599496 was cancelled.
GitHub Actions run 9800609906 succeeded.
Connected!
We have once again narrowly avoided a collapse of the universe itself, for our hero ChrisLovering has saved us from yet certain doom.
GitHub Actions run 9800610968 was cancelled.
6207352 Update internal eval & latex to use the new pas... - ChrisLovering
[python-discord/sir-lancebot] branch deleted: use-new-paste-service-API
GitHub Actions run 9800625111 succeeded.
Connected!
Connected!
GitHub Actions run 9800623317 failed.
GitHub Actions run 9800628000 failed.
Both have been merged. I can go ahead and pick this up.
06353e8 Bump rapidfuzz from 3.9.3 to 3.9.4 (#1568) - dependabot[bot]
GitHub Actions run 9800663985 succeeded.
Connected!
GitHub Actions run 9800677099 succeeded.
Connected!
GitHub Actions run 9800681543 was cancelled.
Connected!
GitHub Actions run 9800695652 failed.
GitHub Actions run 9800728232 succeeded.
Connected!
[python-discord/bot-core] New branch created: py312
If we decide that this feature is needed in one of the bots, then we can reopen this. For now I'll close this, as this PR has been around for 3 years.
@JelmerKorten Hello! Will you be able to finish up this PR? Thanks!
Howzit!
I can definitely try.
To be very honest, I thought it was finished and accepted a long time ago.
Tried to use it on the server a few weeks back and it didnโt work.
Iโll get to it probably at the end of next week.
Thanks for the reminder!
On Fri, 5 Jul 2024 at 04:07, Xithrius @.***> wrote:
@JelmerKorten https://github.com/JelmerKorten Hello! Will you be able
to finish up this PR? Thanks!โ
Reply to this email directly, view it on GitHub
<https://...
Hello! Thanks for the PR. A small nit, please remove the commented out newlines which are located in the following places:
Thanks for the quick response! No rush. If you need any help completing this PR, don't hesitate to ask.
Actual behaviour
$ curl -L http://quackstack.pythondiscord.com/duck?seed=123
{"file":"http://quackstack.pythondiscord.com/duck?seed=123/static/4f7d04f0501e44f652faa08e8c9dfb12324eea51.png"}
# ^^^^^^^^^^^^^
Expected behaviour
$ curl -L http://quackstack.pythondiscord.com/duck?seed=123
{"file":"http://quackstack.pythondiscord.com/static/4f7d04f0501e44f652faa08e8c9dfb12324eea51.png"}
3ff33b1 fix: create path correctly - lavirlifiliol
[python-discord/quackstack] New branch created: lakmatiol/fix/duck-path
Doing string manipulation breaks with queries in url, this PR instead uses the URL API of fastAPI.
fixes #81
We already support Python 3.12, hence the ^3.11 version specifier, and why run the 3.12 tests.
This PR is just dropping support for 3.11, which I don't think we should do yet.
I simply am unable to read, misread the ^3.11 lol
[python-discord/bot-core] branch deleted: py312
GitHub Actions run 9806762832 succeeded.
GitHub Actions run 9807438730 succeeded.
I'm surprised this passed linting, why the extra newline?
Generally looks good, a couple of small notes
If the message is deleted (meaning the type is DeletedReferencedMessage), can you make it say In reply to: Deleted
As we have another "Jump to message" later, I'd like to avoid any confusion if someone clicks it without paying attention. Maybe make it say "Jump to referenced message"
The watched_users pop here remains, but can't the same issue occur if you're trying to remove a user and list the users at the same time? Maybe it's worth converting the iterator in prepare_watched_users_data into a list before looping over it.
For the other two dicts, does this definitely resolve the issue? Looking at on_message, you could theoretically have multiple consume_messages tasks. If one task clears a queue while another is iterating over it, won't it create the same bug?
I made a gif for this as discussed on discord, you ofc have my full permission to use it. it has a similar quality/fps to the return-gif one (actually slightly bigger).
That's a really cool GIF. One thing is that I think it's better to show on the right what's being printed, to clarify that the result is "2\n4\n". Currently it looks like it ends too soon before I can understand what you're showing.
I think posting in both is fine
GitHub Actions run 9809470876 succeeded.
Wait, why did it delete both new lines ๐คฆ
Not sure it was showing a single line
You mean to say like, if the parent message get deleted then it will edit the sent messages changing In reply to: Deleted?
a35f508 Be more specific when describing the base url f... - ChrisLovering
8e270b2 Add daily devops missions for added motivation - ChrisLovering
49edd29 Bump ruff target version to 3.12 - ChrisLovering
7d84160 Disable packaging mode in pyproject.toml - ChrisLovering
5e6b508 Bump dependencies to latest - ChrisLovering
[python-discord/king-arthur] New branch created: Add-daily-missions-for-motivation
a35f508 Be more specific when describing the base url f... - ChrisLovering
8e270b2 Add daily devops missions for added motivation - ChrisLovering
49edd29 Bump ruff target version to 3.12 - ChrisLovering
7d84160 Disable packaging mode in pyproject.toml - ChrisLovering
5e6b508 Bump dependencies to latest - ChrisLovering
[python-discord/king-arthur] branch deleted: Add-daily-missions-for-motivation
b761bcb Create sentry releases using getsentry's action - ChrisLovering
f6b1341 Do not install recommended packages - jchristgit
[python-discord/king-arthur] New branch created: slim-build
We should add a command to King Arthur that displays a programming quote from http://quotes.cat-v.org/programming/.
For Bella, who has generously agreed to implement this feature, I have already prepared the proposed parser logic below. The Cat-V websites provides a HTML-based API, we simply need to install the BeautifulSoup API wrapper to consume this API.
from bs4 import BeautifulSoup
import urllib.request
from typing import NamedTuple
class Quote(NamedTuple):
text: str
s...
7a2d271 Fix transient issues in status embed - jchristgit
[python-discord/king-arthur] New branch created: fix-status-embed-problems
As seen in a dozen other Python Discord projects.
GitHub Actions run 9812746274 succeeded.
819372f Migration to official Sentry release CI action - Xithrius
[python-discord/bot] New branch created: sentry-ci-fix
[python-discord/forms-frontend] New branch created: sentry-ci-fix
5329e56 Migration to official Sentry release CI action - Xithrius
f582b12 Migration to official Sentry release CI action - Xithrius
[python-discord/forms-backend] New branch created: sentry-ci-fix
35e4d7c Migration to official Sentry release CI action - Xithrius
[python-discord/sir-robin] New branch created: sentry-ci-fix
4041d11 Migration to official Sentry release CI action - Xithrius
[python-discord/snekbox] New branch created: sentry-ci-fix
0152aff Migration to official Sentry release CI action - Xithrius
[python-discord/site] New branch created: sentry-ci-fix
8ea5097 Migration to official Sentry release CI action - Xithrius
GitHub Actions run 9813151566 succeeded.
GitHub Actions run 9813151135 succeeded.
GitHub Actions run 9813152209 succeeded.
4540016 Migration to official Sentry release CI action ... - Xithrius
[python-discord/bot] branch deleted: sentry-ci-fix
6f17329 Migration to official Sentry release CI action ... - Xithrius
[python-discord/forms-frontend] branch deleted: sentry-ci-fix
b03d30f Migration to official Sentry release CI action ... - Xithrius
[python-discord/forms-backend] branch deleted: sentry-ci-fix
96c6a5d Migration to official Sentry release CI action ... - Xithrius
[python-discord/sir-robin] branch deleted: sentry-ci-fix
ad7a154 Migration to official Sentry release CI action ... - Xithrius
[python-discord/snekbox] branch deleted: sentry-ci-fix
c3ae5d3 Migration to official Sentry release CI action ... - Xithrius
[python-discord/site] branch deleted: sentry-ci-fix
[python-discord/site] branch deleted: sentry-ci-fix
517cbff Migration to official Sentry release CI action ... - Xithrius
[python-discord/sir-lancebot] branch deleted: sentry-ci-fix
Connected!
GitHub Actions run 9813249327 succeeded.
GitHub Actions run 9813259219 was cancelled.
Connected!
GitHub Actions run 9813258676 succeeded.
Connected!
GitHub Actions run 9813253004 succeeded.
GitHub Actions run 9813261446 succeeded.
GitHub Actions run 9813262622 succeeded.
GitHub Actions run 9813242783 succeeded.
GitHub Actions run 9813264592 succeeded.
GitHub Actions run 9813256536 was cancelled.
GitHub Actions run 9813434368 succeeded.
[python-discord/forms-backend] New branch created: jb3/environ/python-3.12
- Update to Python 3.12
- Update all dependencies and tooling versions
- Update Dockerfile base to 3.12
I will update us to use Ruff in this PR also in accordance with our other projects.
GitHub Actions run 9814687772 succeeded.
Have you tested this? Or are we just deploying to prod as our test?
I have end-to-end tested locally with form creation, submission, response
fetching, Discord OAuth2. I have also tested all this functionality with
the latest version of forms-frontend.
The only bit I am yet to test (but obviously will ahead of a merge) is
unittesting/snekbox integration. I've copied the qualifier form locally
which should allow me to do this fairly easily.
On Sat, 6 Jul 2024 at 02:09, Mark @.***> wrote:
@.**** approved this pull request.
Have yo...
47d924b Bump certifi from 2024.2.2 to 2024.7.4 (#1570) - dependabot[bot]
Connected!
GitHub Actions run 9820378752 succeeded.
Connected!
GitHub Actions run 9820563810 succeeded.
GitHub Actions run 9823722101 failed.
GitHub Actions run 9823807115 failed.
GitHub Actions run 9823849415 failed.
GitHub Actions run 9823869113 failed.
GitHub Actions run 9823882600 succeeded.
GitHub Actions run 9824395687 succeeded.
How can this return None is value is dict[str, str] | int?
The only other exit path I see from this function is raising an error.
This isn't needed anymore. poetry install is the default now.
Same as above, if value is str how can this return None?
The uvicorn.workers module was depreacted in uvicorn 0.30.0.
We currently rely on that module for gunicorn in the dockerfile.
We should either install the module from https://github.com/Kludex/uvicorn-worker, or remove gunicorn entirly and just use the uvicorn binary in the dockerfile.
My preference is the latter, since we already use k8s for replication, so having gunicorn too seems unneeded.
if value and DISCORD_GUILD in value:
This isn't needed anymore, now that you've changed the default to a string in constants.py
I haven't tested locally but code looks good to me.
e3a38ef fix: create path correctly (#82) - lavirlifiliol
[python-discord/quackstack] branch deleted: lakmatiol/fix/duck-path
Connected!
GitHub Actions run 9829676648 succeeded.
GitHub Actions run 9830624409 failed.
GitHub Actions run 9830635398 succeeded.
GitHub Actions run 9830734565 succeeded.
GitHub Actions run 9830814097 succeeded.
I think it would have been best to make the ruff changes in a separate CR. Separating functional and non-functional changes makes reviews easier.
Remove trailing comma.
Absolutely brilliant. Death to the single quotes. They can no longer take refuge in f-strings.
Remove trailing comma.
I would find this more readable if it was split into several statements.
Remove trailing comma.
I know it original had Optional, but can this actually return None? I'm not seeing it.
Remove trailing comma.
Remove trailing comma.
I don't think this actually returns None.
Can this fit into one line?
We should use utf8 as the encoding. Not explicitly specifying one to begin with was a mistake,
Can this fit into one line?
Remove trailing comma.
Remove trailing comma to make it one line.
This can be split into two variables to make it more readable.
I think the explicit else is more readable. At the least there should be a blank line after the if block.
Can this fit into one line?
GitHub Actions run 9834261471 failed.
GitHub Actions run 9839293249 succeeded.
GitHub Actions run 9839302787 succeeded.
GitHub Actions run 9839312989 succeeded.
I'm going to flip this around so instead we do if not member: ... and then default to returning the found member, should help clarity.
All comments addressed, thank you greatly for the review @MarkKoz :shipit:
GitHub Actions run 9841037564 succeeded.
180c89b Bump ruff from 0.5.0 to 0.5.1 (#3116) - dependabot[bot]
7469fd8 Make !warn fail if DMing the user is unsuccessf... - vivekashok1221
[python-discord/bot] branch deleted: vivek/warn-dm-fail
GitHub Actions run 9841104076 was cancelled.
GitHub Actions run 9841129288 succeeded.
Connected!
GitHub Actions run 9841157132 succeeded.
Connected!
GitHub Actions run 9841286291 succeeded.
GitHub Actions run 9841628473 succeeded.
GitHub Actions run 9844887758 failed.
A member update event triggered the following traceback shortly after startup:
2024-07-08 18:26:19 metricity-85d48b5747-9bpkj metricity.bot[16] ERROR Unhandled exception in on_member_update
Traceback (most recent call last):
[ ... ]
File "asyncpg/protocol/protocol.pyx", line 207, in bind_execute
asyncpg.exceptions.UniqueViolationError: duplicate key value violates unique constraint "users_pkey"
DETAIL: Key (id)=(1234) already exists.
The above exception was the direct cause of ...
daaa8f1 Bump coverage from 7.5.1 to 7.5.3 (#3078) - dependabot[bot]
8503f12 Bump ruff from 0.4.5 to 0.4.6 (#3079) - dependabot[bot]
eac1e4d Bump rapidfuzz from 3.9.1 to 3.9.2 (#3080) - dependabot[bot]
588259d Bump sentry-sdk from 2.3.1 to 2.4.0 - dependabot[bot]
cf8af8f Merge pull request #3083 from python-discord/de... - jb3
36fac49 Lazily create guild on text/voice channel mocks - wookie184
cf74040 Make use of fakeredis instead of mocking - wookie184
7477a1c Don't setup the cog for Notifier and Argument P... - wookie184
379194b Just use the notifier instead of patching - wookie184
efa85ef Selectively patch SilenceNotifier only where ne... - wookie184
[python-discord/bot] branch deleted: faster-silence-tests
GitHub Actions run 9846939106 succeeded.
Connected!
GitHub Actions run 9846950361 succeeded.
GitHub Actions run 9847022359 succeeded.
GitHub Actions run 9847025490 succeeded.
fcd7654 Bump sentry-sdk from 2.6.0 to 2.7.0 (#1564) - dependabot[bot]
cdfd0bd Bump ruff from 0.4.10 to 0.5.0 (#1565) - dependabot[bot]
6207352 Update internal eval & latex to use the new pas... - ChrisLovering
06353e8 Bump rapidfuzz from 3.9.3 to 3.9.4 (#1568) - dependabot[bot]
b3a0773 Bump sentry-sdk from 2.7.0 to 2.7.1 (#1566) - dependabot[bot]
GitHub Actions run 9847896458 succeeded.
GitHub Actions run 9851281450 failed.
5ce8d80 Move unittest filtering to the Form.dict() func... - ChrisLovering
[python-discord/forms-backend] New branch created: refactor-unittest-filtering
[forms-backend] Branch refactor-unittest-filtering was force-pushed to `56b6b09`
ae2d6cc Move unittest filtering to the Form.dict() func... - ChrisLovering
[python-discord/forms-backend] branch deleted: refactor-unittest-filtering
GitHub Actions run 9861946788 succeeded.
0980a9f Add @reduxjs/toolkit and react-redux packages - jb3
83b682b Add new redux stores and slices for authorizati... - jb3
d3f0997 Wrap application in Redux Provider with new store - jb3
5384ee5 Send dispatches to store on authorization state... - jb3
adbc408 Add AuthorizationSplash to display above conten... - jb3
[python-discord/forms-frontend] New branch created: jb3/auth/popup-and-improvements
- Authorization window with Discord is now a pop-up instead of a new tab, more
in keeping with other services that use OAuth2. - State is now a longer cryptographically secure nonce, as opposed to our
previous short numeric states. - When authorizing, we now dim the entire form tab until the authorization has
been completed/cancelled - We now have an application-wide Redux store if we want to do anything fancy in
future related to application state
[forms-frontend] Branch jb3/auth/popup-and-improvements was force-pushed to `f77c39a`
7021562 Gracefully handle user cancelled authorization - jb3
[forms-frontend] Branch jb3/auth/popup-and-improvements was force-pushed to `a2a37ba`
[forms-frontend] Branch jb3/auth/popup-and-improvements was force-pushed to `334b150`
[python-discord/forms-frontend] New branch created: jb3/deps/dep-bumps
- Bump all dependencies to latest
- Bump from Node 16 to 20 in Docker images
- Use @uiw/react-codemirror for code component for greater simplification
[python-discord/forms-frontend] branch deleted: jb3/deps/dep-bumps
[forms-frontend] Branch jb3/auth/popup-and-improvements was force-pushed to `e586c95`
8077176 Add @reduxjs/toolkit and react-redux packages - jb3
5c8125a Add new redux stores and slices for authorizati... - jb3
a735211 Wrap application in Redux Provider with new store - jb3
5dac3c0 Send dispatches to store on authorization state... - jb3
f5024e4 Add AuthorizationSplash to display above conten... - jb3
[python-discord/forms-frontend] branch deleted: jb3/auth/popup-and-improvements
[python-discord/forms-frontend] New branch created: jb3/components/improved-radio
31adec3 Improve the styles on the radio component to ma... - jb3
Increases the click area, the visibility that an option has been
selected, and the visibility that an item has been hovered on.
Additionally, adds an instruction ahead of the component instructing
users to select an option incase it was no longer clear that the field
is a radio select.
Demo of the selected option (green) and the hovered option (lighter grey & offset on X)
[forms-frontend] Branch jb3/components/improved-radio was force-pushed to `4f9fbc4`
[forms-frontend] Branch jb3/components/improved-radio was force-pushed to `93e42b9`
Cherry picking this onto main to avoid having to do a branch update.
[forms-frontend] Branch jb3/components/improved-radio was force-pushed to `00413b1`
00413b1 Improve the styles on the radio component to ma... - jb3
[python-discord/forms-frontend] branch deleted: jb3/components/improved-radio
GitHub Actions run 9868932415 failed.
Suspect Issues
This pull request was deployed and Sentry observed the following issues:
- โผ๏ธ AutoReconnect: mongodb.databases.svc.cluster.local:27017: connection closed (configured timeouts: connectTimeout...
http://10.2.0.188:8000/forms/submit/cj11-2024-q...View Issue
<sub>Did you find this useful? React with a ๐ or ๐</sub>
GitHub Actions run 9872233720 succeeded.
GitHub Actions run 9873982207 succeeded.
GitHub Actions run 9877995155 succeeded.
GitHub Actions run 9878404351 succeeded.
GitHub Actions run 9878412682 succeeded.
GitHub Actions run 9878371309 was cancelled.
GitHub Actions run 9878454668 succeeded.
GitHub Actions run 9878435353 succeeded.
GitHub Actions run 9879322992 succeeded.
[python-discord/forms-frontend] New branch created: jb3/components/vote-field
Adds a new component for transferrable voting, allowing users to rank
preferences based on the provided options list.
[python-discord/forms-backend] New branch created: jb3/components/vote-field
Adds a new voting question type in accordance with python-discord/forms-frontend#638
GitHub Actions run 9883994285 succeeded.
GitHub Actions run 9884051677 succeeded.
GitHub Actions run 9890402590 succeeded.
GitHub Actions run 9891856499 succeeded.
[python-discord/forms-backend] New branch created: jb3/features/condorcet-count
Adds an endpoint, /forms/{form_id}/condorcet/{question_id} to perform a
Condorcet calculation for the newly added vote components.
Optionally, a ?winners= parameter can be specified to provide the number of
results to calculate for, defaulting to 1 winner.
The rest of the Condorcet table is provided.
An example response:
{
"question": {
"id": "vote-1",
"name": "Vote for your preferred options",
"type": "vote",
"data": {
"options": [
"Dog",
...
GitHub Actions run 9898815066 succeeded.
GOAT
GitHub Actions run 9898851550 succeeded.
[forms-backend] Branch jb3/features/condorcet-count was force-pushed to `3b6464f`
GitHub Actions run 9898910008 succeeded.
cab8799 Return errors in JSON format so they can still ... - jb3
cb2dd7e Add Condorcet calculation library - jb3
b5bb7e0 Add new endpoint for performing condorcet calcu... - jb3
3b6464f Ensure requested condorcet calculations are on ... - jb3
23e6be1 Merge pull request #282 from python-discord/jb3... - jb3
[python-discord/forms-backend] branch deleted: jb3/features/condorcet-count
GitHub Actions run 9898999818 succeeded.
GitHub Actions run 9899010279 succeeded.
GitHub Actions run 9899009500 succeeded.
GitHub Actions run 9899019764 succeeded.
GitHub Actions run 9903024881 succeeded.
GitHub Actions run 9907593839 succeeded.
GitHub Actions run 9914357302 succeeded.
Thanks Bella for wiring up the parser for this esoteric format.
Truly great work!
QUOTE OF THE DAY - POWERED BY DENNIS.SERVICES
Pain is a thing of the mind. The mind can be controlled.
-- Spock, "Operation -- Annihilate!" stardate 3287.2
[python-discord/king-arthur] New branch created: set-user-agent-explicitly
3c9abdd Set explicit user-agent header - jchristgit
Allow people to know that we're not just a dumb scraper, but we're
business professionals.
GitHub Actions run 9917913353 succeeded.
GitHub Actions run 9918067829 succeeded.
Suspect Issues
This pull request was deployed and Sentry observed the following issues:
- โผ๏ธ ExtensionFailed: Extension 'arthur.exts.fun.quotes' raised an error: ImportError: cannot import name 'KingArthur' ...
discord.ext.commands.bot in _load_from_module_specView Issue
<sub>Did you find this useful? React with a ๐ or ๐</sub>
GitHub Actions run 9918094212 succeeded.
GitHub Actions run 9919251272 succeeded.
Even if the message reference could not b resolved, we can still have an indication that the deleted message was a reply.
So something like:
In reply to: (Message could not be resolved)
I feel like you should still include the message author as well as the message link/message ID- and put "Deleted Message" in parenthesis.
Don't you need to add a newline here?
reference_line = "**In reply to:** Deleted Message\n"
GitHub Actions run 9922295469 succeeded.
GitHub Actions run 9922433688 succeeded.