GitHub Actions run 1799816742 succeeded.
#dev-log
1 messages ยท Page 93 of 1
GitHub Actions run 1799819805 failed.
Not quite sure what you mean. We insert all roles as a list? Not sure what the benefit is.
It doesn't matter if discord adds something, the model will just ignore it.
You're technically right (though we use IDs too), but I think we can use this info in the frontend when displaying the role, or for any future endavors. It doesn't hurt to have.
I'm not sure what problem you're trying to solve here. There is no extra complexity to using the models if we already have them, as it's just some init/dict calls every now and then. The benefit to using them is we get built-in validation, and it's mentally easier to deal with than a bunch of random dicts all over the place.
I see, right. I think I read that sentence differently and focused on the cache being skipped.
This makes sense though, I'll mark this as resolved.
GitHub Actions run 1799842347 succeeded.
GitHub Actions run 1799845944 succeeded.
GitHub Actions run 1799819805 failed.
GitHub Actions run 1799885551 succeeded.
Looks perfectly fine!
Thank you! ๐
0344d9a Use HTTPException To Propagate Access Failures - HassanAbouelela
Connected!
Looks perfectly fine!
Thank you! ๐
Because of your help!! Thank you ๐ฅณ
GitHub Actions run 1799819805 succeeded.
Doc item doc_item.symbol_id='numpy.roots' present in loaded documentation inventories not found on site, inventories may need to be refreshed.
GitHub Actions run 1801334866 succeeded.
Description
A .joke command, using the pyjokes library . Most of the jokes are programming based.
Reasoning
It would be another fun command for sir lancebot, and as I said earlier, the jokes are programming based, which the community will find relatable.
Proposed Implementation
I haven't implemented this in a discord bot yet, but I plan on doing so soon. This
is how it works (I tested it in a normal python program)
 a user somehow gets the Voice Verified role but the event is not logged by Discord's audit log nor in our #user-log.
Currently, the messages in #voice-verification that get deleted by the bot are logged in #message-change-log with the exception of invocations of the !voiceverify command.
We would like to see the bot not ignore these messages, and still log them.
The relevant sections of code (thanks @ChrisLovering)
The further this, my opinions are that we should either remove these two mod_log.ingore calls, or we should log.info() these events, so that when investigating we have an avenue to go down that isn't trawl through Discord's audit logs.
Connected!
GitHub Actions run 1809487150 succeeded.
GitHub Actions run 1809612171 succeeded.
GitHub Actions run 1810745025 succeeded.
GitHub Actions run 1811658554 succeeded.
Small and concise ๐
Said screenshot was updated in https://github.com/python-discord/site/pull/624/commits/32db9c54f46edbca8036f6cf2e7dc94ac78ad056
The area around previous line 59 has been re-written in that same above commit on line 48.
With the Exercism resource, it says a name of Exercism.io, with a website of exercism.io.
While thE website is historically correct, it is no longer correct! The website does redirect correctly, but we should probably use the new link anyway (exercism.org)
I'd say that the name should just be Exercism as well!
I am happy to fix this!
The raw command does not work in threads. It displays the following message even when the user has access to the thread:
.
I haven't looked very closely into it and I'm rusty with discord.py but the bug could be because message.channel.members [line 473] is a list of [ThreadMember](https://discordpy.readthedocs.io/en/master/api.html?highlight=channel#discord.ThreadM...
BTW, I'm not particularly interested in implementing a fix.
Resource name
Dear PyGui
Resource location
https://github.com/hoffstadt/DearPyGui
Payment type
Free (MIT license)
Why it should be included
Dear PyGui is a fast and powerful cross-platform Graphical User Interface Toolkit for Python with minimal dependencies, available under a permissive MIT license. It fits in with GUI frameworks such as Tkinter, PySimpleGui, PyQt and WxPython. Each framework has its strengths and weaknesses. Dear PyGUI stands out in its comb...
Thank you for taking interest in our resources. The resources page is for recommending media for learning Python and how to do different things in Python; it is not a collection of recommended libraries.
I was referring to the following page that links to Kivy, Pandas3D and Pyglet or their Discord servers.
https://www.pythondiscord.com/resources/?topics=user-interface
If more appropriate, I'd suggest a link to the Dear PyGui Discord server: https://discord.gg/tyE7Gu4
Apologies if I misunderstood. I don't mean to argumentative, but to explain why I thought it might be appropriate given the references to these other comparable libraries.
I see. It would appear that some of the entries under user interfaces are written as though they're featuring the library themselves, even though in some cases, the associated Discord server is the actual resource.
I'll bring this up with staff members who are experienced with GUI design. Thanks!
Thank you. If it turns out there is another resource page that is a better fit, please let me know.
GitHub Actions run 1815453033 failed.
GitHub Actions run 1815529663 failed.
Connected!
GitHub Actions run 1816422759 succeeded.
[python-discord/bot] New branch created: chris/fix/help\-channel\-errors
These changes ensure that for every help channel in use, a claimant is present in the redis cache. This is to avoid an issue caused when a user tries to close a channel, but the cache is empty so the author check fails.
This also cancels a help channel claim if we hit a discord 500 error while moving the channel.
GitHub Actions run 1818136980 succeeded.
[bot] Branch chris/fix/help\-channel\-errors was force-pushed to `14bb179`
GitHub Actions run 1818150038 succeeded.
An addition to this I thought of is when someone claims a how-to-get-help channel it could check if their initial message is in a list of common first messages like hello, hi, help me etc. and if it does have the bot wait say 10 seconds and if the user that claimed the channel is not typing (I believe you can check that, if you can't then have this happen after say 60 seconds of no messages) have the bot reply to the message restating:
Remember to:
โข Ask your Python question, not if...
Another thing I also think it should say is something a long the lines of:
"Try to write your sentences with grammar heavily in mind as it will help readability for people trying to answer your question"
I'd like for the resources command to have a single, optional parameter for specifying the topic. For example, !resources data science should return the URL for the resources page, pre-filtered to show all data science resources. This only requires appending the URL to include ?topic=data-science.
I think trying to support more filtering options than this (like support for more than one option or settings for the other filters) would be too complicated for the command, but I can see th...
Sentry Issue: SIR-LANCEBOT-7R
NotFound: 404 Not Found (error code: 10008): Unknown Message
File "discord/ext/commands/core.py", line 167, in wrapped
ret = await coro(*args, **kwargs)
File "bot/exts/utilities/epoch.py", line 89, in epoch
await original.edit(view=None)
File "discord/message.py", line 1289, in edit
data = await self._state.http.edit_message(self.channel.id, sel...
GitHub Actions run 1819714238 succeeded.
I couldn't find much here @Shom770 but there's a few points to be brought up.
Was this accidentally left behind? What's the differnence between this and the end method above?
I don't remember, does this account for people not answering all questions? Also we should probably filter out incorrect answers (if possible?)
Looking at this again from the full diff, it's actual purpose is an Optional timestamp so this wouldn't work.
This results in an Internal Server Error if the user is admin and the form isn't in the database.
Cursory testing works fine so far, but I've haven't had the time to properly review
I'm not sure how this works, and I can't seem to find a reference. Is this tied to a role helper somewhere?
I agree with this, for the sake of keeping the data as long as possible @Shom770. Move this to start() (self._guesses = {} that is). So that guesses are left intact for as long as possible.
GitHub Actions run 1821316227 failed.
GitHub Actions run 1821429102 succeeded.
GitHub Actions run 1821653464 succeeded.
It isn't tied to a constant, but rather the new access system fetches all the user's roles, and adds their names as scopes.
Have you reproduced that? Line 41 should prevent it from happening.
Yes I have reproduced it, I believe Line 41 doesn't prevent it because the check returns before raising FormNotFoundError here: https://github.com/python-discord/forms-backend/blob/0344d9a2137eb755f002398aac40533e8ea46776/backend/discord.py#L168-L169
Since the role name in the server is Admins, wouldn't there be no collision? Or am I misunderstanding something?
No you're right, this is more of a precautionary measure though. Form admins have had a lot of perms, so reducing the surface for attack on that seems smart.
10080f8 Ensure Form Existence Is Always Checked - HassanAbouelela
Ah, that's a good catch. I've switched the order in 10080f8f
GitHub Actions run 1825932466 succeeded.
GitHub Actions run 1826216262 succeeded.
435de9c Add PostUp directive for routing wg subnet - jb3
[python-discord/infra] New branch created: jb3/wg\-add\-local\-ip
This PR adds a PostUp directive to the Wireguard config of all nodes to add the allocated /16 to the local routing table.
This means that hosts:
- Are aware that packets destined for these IPs should be captured by the Kernel, not ignored
- Allow services to bind to any IP address within their allocated /16
This does not include a PostDown directive since we do not want to lose the local routing should the Wireguard session go down, services should still be able to bind to relevant IPs ev...
An example of ICMP responding on any IP within the range (prior to this, only the default gateway (e.g. 10.2.0.0) would respond to ICMP, any other IP would infinitely loop in the destination host.
joe@turing:~$ ping 10.2.0.1 -c 4
PING 10.2.0.1 (10.2.0.1) 56(84) bytes of data.
64 bytes from 10.2.0.1: icmp_seq=1 ttl=64 time=0.572 ms
64 bytes from 10.2.0.1: icmp_seq=2 ttl=64 time=0.727 ms
64 bytes from 10.2.0.1: icmp_seq=3 ttl=64 time=0.784 ms
64 bytes from 10.2.0.1: icmp_seq=4 ttl=...
Sorry, I am unable to find the file having !resource command.
It will be a great help if you can guide.
If you go into the server and run !source resources, it will tell you. At least I think it will.
If it's a "tag" (a command that fetches a static markdown file and displays the content), an actual function for the command will need to be defined somewhere. Try asking in #dev-contrib, in that case.
The feature could simply be implemented as tags under a new resources group, though depending on what exactly is in those tags, it could lead to some content duplication between them.
Looks challenging for me, but surely i will try.
Reminder validation relied on the member cache which might not be properly filled, which caused some reminders to not be sent.
This PR removes this part of the validation. This can cause reminders to be sent for users who are no longer in the server, but this seems negligible.
While #1919 might be more thorough, the changes here are very simple and will allow us to have the reminders cog again.
Don't be alarmed by the line count, the merge commit brought back the entire file. The actual change is the first commit which is an 8-line change
[python-discord/bot] branch deleted: mbaruh/reminders\-fix
GitHub Actions run 1829696993 succeeded.
Connected!
GitHub Actions run 1829718257 succeeded.
It is a tag, yes @swfarnsworth.
Which means, we either need to do what @Numerlor suggested and making one tag for each type in the same group, or we need to get rid of the tag and just make a regular command for this to replace it.
The latter seems simpler to me. It could simply take any input you give it and append it to the URL as ?topic=<input>. The Resources page is made so that if you request a topic that doesn't exist, that's okay, it'll just dump the parameter and show you all ...
Hmm, on second thought, this may have an unintended side-effect of getting in the way of how people like to use this tag today. A lot of people love throwing extra text after the invocation:

which may cause it to break or perform strangely in interesting ways.
With the different tags I also though of changing the accompanying text of them, but looking at the resources page and how many potential filtering options there are (without combinations) it doesn't seem fitting for plain tags
Writing a message alongside the invocation of !resources is indeed very very common, as lemon pointed out.
Would it be possible to make it such that some logic is only triggered if the user says !resources for _ ?
GitHub Actions run 1830563660 was cancelled.
GitHub Actions run 1830568292 succeeded.
I see the problem, but I think it solves itself.
See what happens if you click https://www.pythondiscord.com/resources/?topics=foo-bar-lol?
As opposed to https://www.pythondiscord.com/resources/?topics=data-science
It looks like clicking a link with an invalid ?topics= argument takes you to the resources page without any filters applied.
We have talked about this internally and we decided on not adding a new linting dependency here. While there's some value in having linters for consistent code like this, there is a line to draw - it's not a great experience for contributors to have a contributor go back and modify their code just for changing the quotation style, especially since some developers tend to have fixed habits on their usage of quotes in Python.
Truly the pinnacle of software engineering is only display with this PR. Thank you Johannes
GitHub Actions run 1830841667 succeeded.
Chris, I was highly satisfied to be able to receive a notification of you reviewing my pull request today. I look forward to receiving further reviews from you in the future.
We have talked about this internally and we decided on not adding a new linting dependency here. While there's some value in having linters for consistent code like this, there is a line to draw - it's not a great experience for contributors to have a contributor go back and modify their code just for changing the quotation style, especially since some developers tend to have fixed habits on their usage of quotes in Python.
What about the local pre-commit which would do it automatically ...
What about the local pre-commit which would do it automatically along with the other checks like trailing spaces?
I am indifferent about this, personally the pre-commit setup has grown to a size where I have completely removed it from my workflow due to the time it needs to run through.
More so on the developers having habits on their own quoting style, how should this be handled in reviews?
The current Python Discord style is to use ", should this be pointed out in reviews (i.e....
Is it personal preference if it's the project's style set by the style guide?
GitHub Actions run 1831538462 succeeded.
it does, yes, by design. I did mention that in an earlier comment in this thread. It might still cause some interesting side-effects, but I don't think it's a dealbreaker.
Looks good, just one comment regarding the traceback.
File "my_file.py", line 2, in add_three
I don't see a real benefit to keeping the guesses around until the next question starts. Trying to int-e our way back to viewing the guesses later is not something I'm going to do mid-event.
Great feature and thank you so much for your work on it! The core of this is very, very solid and it runs like a charm.
I think the remaining unaddressed feedback can be added into a QoL PR later as it doesn't impact the core functionality.
It's a force end in case something wonky happens with the interactions or something weird goes on.
It'll let us force end it and then I can call for the scoreboard specifically which will embed.
This has been solved in #570
@swfarnsworth
Would you say this is solved? If you would, please close it.
The way I see it now, there are really two different search bars we want:
- A reactive search bar on the resources page, which filters down the resources which are shown with immediate effect. Every keypress should do a search.
- A full-site search, for searching the content of pages and articles.
These probably shouldn't be the same search bar, so we should split this into two different issues.
I'm repurposing this issue to be about the former of these two, and self-assigning it. For...
Let's create a reactive search bar that can be used to filter the resources on the /resources page.
We can build this with some fairly simple jQuery, .filtering all currently visible resource cards. This will extend the current functionality very naturally.
Specs
- The search bar should do a search for every keypress.
- The search should be fuzzy.
aksshould matchask. - When typing a search term, a
Search:tag should appear in the tag pool at the top of the filter sideba...
Actually, on second thought, I'm not 100% sure the full-site search fits the app well. It's unclear how static page search would work, and doing only content page search seems kind of unintuitive and like poor UX.
I'm not sure it's worth implementing, and it would be tricky. Let's start with resource filtering and see if anyone creates a new issue for full-site search.
Approving since it's tested and works. We don't want to delay further due to the event happening this evening.
However, we'd like to see some of the comments here actioned in a subsequent PR.
Thanks for the input everyone, nice work ๐
GitHub Actions run 1834173849 succeeded.
Sentry Issue: SIR-LANCEBOT-7T
AttributeError: type object 'Roles' has no attribute 'admin'
File "discord/ext/commands/bot.py", line 660, in _load_from_module_spec
spec.loader.exec_module(lib) # type: ignore
File "", line 850, in exec_module
File "", line 228, in _call_with_frames_removed
File "bot/exts/events/trivianight/trivianight.py", line 18, in
TRIVIA_NIGHT_ROLES = (Rol...
Relevant Issues
<!-- Link the issue by typing: "Closes #" (Closes #0 to close issue 0 for example). -->
Closes #1025
Description
Changed Roles.admin to Roles.admins to prevent an error.
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://python...
GitHub Actions run 1834203039 succeeded.
Connected!
GitHub Actions run 1834223704 succeeded.
Try to write your sentences with grammar heavily in mind, as it will help readability for people trying to answer your question
I disagree with this. Questions that are poorly written from an English grammar perspective are not necessarily those that are poorly written from an answerability perspective. Many of our users are not native English speaking, and I'm concerned about how this kind of messaging would be received.
maybe the addition of a command where the answering party can...
111c7c3 Fix line numbers, location names - swfarnsworth
Thank you for pointing this out; I have fixed it.
GitHub Actions run 1835001112 succeeded.
[metricity] Branch message\-sync\-command was force-pushed to `56c4a53`
fd9328d Bump version number to 1.4.0 - ChrisLovering
8114d5e Kaizen: Ensure resource cards are fullwidth. - lemonsaurus
74cfc67 Kaizen: Fix redirect /pages/resources/communities. - lemonsaurus
dbc7584 Add a search bar to the top of the filter sidebar. - lemonsaurus
c412d29 Kaizen: Update URL for Two Scoops. - lemonsaurus
a3c29eb Dynamically update URL with search query. - lemonsaurus
[python-discord/site] New branch created: 659/lemon/resource\_search\_bar
- Kaizen: Ensure resource cards are fullwidth.
- Kaizen: Fix redirect /pages/resources/communities.
- Add a search bar to the top of the filter sidebar.
- Kaizen: Update URL for Two Scoops.
- Dynamically update URL with search query.
- Trigger a UI update when typing into search.
- Add fuzzysort dependency.
- Add names for every resource card.
- Implement fuzzy search.
- Add a filter tag when searching.
GitHub Actions run 1836763149 succeeded.
Should we add the new !resource command to help cog at
bot/exts/info?
@swfarnsworth ?
GitHub Actions run 1836890467 succeeded.
GitHub Actions run 1836901848 succeeded.
According to a vote we held with the mods, the alert should always ping if the unfurl fails, but otherwise ping only if the destination is blacklisted.
GitHub Actions run 1837058732 succeeded.
GitHub Actions run 1837071159 failed.
Sentry Issue: BOT-2Y7
Forbidden: 403 Forbidden (error code: 50003): Cannot execute action on a DM channel
File "discord/client.py", line 351, in _run_event
await coro(*args, **kwargs)
File "bot/exts/info/code_snippets.py", line 254, in on_message
await message.edit(suppress=True)
File "discord/message.py", line 1289, in edit
data = await self._state.http.edit_message(self.ch...
1296914 Add unsubscribe alias to subscribe command - ChrisLovering
[python-discord/bot] New branch created: subscribe\-alias
In quite a few places, such as #roles, we tell users to run the unsubscribe command to remove roles from them. However, this command no longer exists due to the rework of the subscribe command.
Since the subscribe commands allows you to remove as well as add roles, I have added this as an alias.
2ea2596 Edge case: Fix extremely long search overflow. - lemonsaurus
Connected!
GitHub Actions run 1837167801 succeeded.
Shouldn't we use something like x-data-name instead?
Can we add this to our staticfiles instead, or pin it to a ref?
[python-discord/site] branch deleted: user\-information\-endpoint
f5f2310 Add fuzzysort as a local dependency. - lemonsaurus
ad4897c Edge case: Fix a bug with overflow on Chrome. - lemonsaurus
GitHub Actions run 1837259607 succeeded.
This is great lemon. Stunning work on the Smarter Resources. I don't understand anything about JavaScript or CSS or HTML for that matter, but I think this is great.
9f2d083 Add reported message author's username and prof... - minalike
ee5a216 Merge pull request #2073 from minalike/incident... - D0rs4n
d7872d4 Don't validate reminder author - mbaruh
f037942 Disable Reminders Cog (#2074) - HassanAbouelela
d280b08 Merge branch 'main' into mbaruh/reminders-fix - mbaruh
I think we can do a squash merge for this one?
GitHub Actions run 1837438235 succeeded.
This looks wonderful! I don't know much about Django, but from what I do know about JS, that all looks great. The search experience is flawless, too.
I think these seem okay. It would be nice if there were more, but I don't have any problem with these being added. ๐ฆ
The close button doesn't look great when the bar is really wide

I think this is actually a problem with the bar's width, as it shouldn't get that wide in the first place. It seems to try to match the width of the line below it, but when a 3rd line gets added, it gets too wide:

- Champion Role Icon
- Events Team Role Icon
GitHub Actions run 1837860317 succeeded.
GitHub Actions run 1837884460 succeeded.
Critical change approved. READY TO LAUNCH SIR!
[python-discord/bot] New comment on pull request #2083: Removed extra newline in the traceback tag\.
Oh I forgot I can merge this sooner because it's a tag lol
Thanks y'all
[python-discord/bot] branch deleted: traceback\-tag\-hotfix
6cdbd56 Removed extra newline in the traceback tag. (#2... - Xithrius
Connected!
GitHub Actions run 1837930044 succeeded.
Connected!
@mathstrains21 will you be continuing this PR?
This condition isn't very easy to read, should I change it to the following for readability?
if after.channel is not None and before.channel is None:
I personally don't really see this as an improvement. I actually find it better as-is.
Additionally, I've been asked for it to only be triggered on initial joins.
To further expand on this: I requested this since there's no point in triggering when switching voice channels. In order to switch channels, o...
I'd like to have a go at implementing this.
My current thoughts are having a button on the reminder message for snoozing, which will then display a dropdown of reschedule relative times ("1 hour", "6h hours", "1 day", "1 week" and "1 month" or something). I.e. a system similar to .epoch, but with a button triggering the drowdown message.
Thoughts on this? @ChrisLovering @Shivansh-007
The check_bad_words_in_name only pings once every 3 days, unless the docstring is misleading.
Seems good ๐ As long as the subsequent remind message still points to the original message :D
b54d81b Add a cog to bump threads - ChrisLovering
[python-discord/bot] New branch created: thread\-bumper\-cog
Quite often we want threads such as event discussions, or moderation discussions to live beyond their maximum of 1 week of auto-archival. This cog allows staff to add a thread to a list that will get 'bumped' back open by the bot when they are auto-archived
GitHub Actions run 1838031746 succeeded.
@mathstrains21 will you be continuing this PR?
Hi! I will be, I just need to find the time to do so! Thanks for the reminder though!
GitHub Actions run 1838076142 succeeded.
GitHub Actions run 1838111615 succeeded.
Would manually archived threads be bumped too? I don't think that'd be a desired behaviour.
Thread.archiver_id is Optional[int]. I'm assuming it will not be None in cases of manual archiving. I've not tested it but I guess you could use that to check if a thread was manually archived.
Please correct me if I'm wrong. As perfect as I might seem, I make sometimes make mistakes.
The
check_bad_words_in_nameonly pings once every 3 days, unless the docstring is misleading.
Right. I didn't word my reasoning very well, but it still applies. It just saves a redundant function call.
Hmmm, I've tried this in the on_thread_update event listener, and it doesn't seem to be set at all, on the before or after thread object when manually archiving.
i also can't see where this data would come from, since it's not present on the discord api https://discord.com/developers/docs/resources/channel#thread-metadata-object and in the discord.py source, its tries to pull this key directly form the data from the api.
So possibly it used to be there, but isn't anymore? ๐คท
GitHub Actions run 1838219112 succeeded.
I've been bamboozled!
As of June 10th, 2021, this value will always be None since Discord doesnโt provide this information anymore.
This property will be removed in a future version.
I guess we can manually remove the thread from the bump list before archiving it.
Ah, that explains it.
The only other option I can think of is to take the last message in the thread, add the auto-archive time to it and see if that is close to the current time, or in the past.
GitHub Actions run 1838315273 succeeded.
GitHub Actions run 1838380661 succeeded.
I am going to make this run on every single voice_state_update event, as we are already running this same function for every single message sent. So there shouldn't be any issues with slow down.
One thing we could do, if we are worried about that, is implementing an LRU cache on this function. We would need to worry about invalidating the cache when the filters change...
Thanks for the quick update! Have a good one!
GitHub Actions run 1838499430 failed.
Looks good, a few comments
I'm not sure I like this description, it's a bit confusing. If I were to describe it, I'd just say that the help system provides channels for focused help to you individually, and can have any python related question, while the topical channels have specific topics, aren't reserved for one person at a time, but might have a better chance to been seen by someone with domain knowledge.
Could say "until you close your help channel" to highlight the ability of closing the channel, even if it's not as accurate.
maybe we could call it "asking questions well" or something? someone might think that their problem might not be good enough to be asked about or something.
GitHub Actions run 1838517659 succeeded.
Explicit kwarg for readability.
await self.apply_ban(ctx, user, reason, purge_days=1, expires_at=duration)
Raise an error so the invoker knows it failed?
GitHub Actions run 1838704794 failed.
None
None
None
None
None
None
Hi, saw this and wanted to explain a 100% guaranteed way to know if it was manual or automatic: manual closes will have an audit log entry. If there's no relevant audit log entry then it safe to assume that the thread closed automatically, rather than manual.
None
None
None
Description
I made _effects.py even more random
- [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?
None
None
Description
I made the effects in avatar modification by using threading
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?
GitHub Actions run 1839532283 failed.
None
None
None
None
None
None
hello can i fix this issue? that is if it has not already been fixed yet
None
None
None
None
None
None
None
None
None
None
[python-discord/bot] New branch created: fix\-issue\-2010
None
fb476c5 Return earlier for raw message edits in DMs. - TizzySaurus
Closes #2010.
Returns early when the event.guild_id is None, in order to prevent the channel from being None.
The initial plan of moving up the self.is_message_blacklisted(message) wouldn't work since we don't have access to the message variable until after we have the channel.
GitHub Actions run 1840196354 succeeded.
None
None
None
None
b651e34 Fix DM handling for code snippets. - TizzySaurus
[python-discord/bot] New branch created: fix\-bot\-2081
Closes #2081.
Catches error raised when trying to edit message in DM fails (we still try to edit so we can ensure the message hasn't been deleted).
If the error was raised by a message inside the guild, then we reraise the error since that's unexpected behaviour (would mean that the bot has missing permissions).
Also only checks if we need to send to #bot-commands when the message was sent in the guild.
GitHub Actions run 1840507205 succeeded.
c62a52e Allow duckifying of messages in threads - TizzySaurus
[python-discord/bot] New branch created: fix\-issue\-1930
Closes #1930.
Messages in threads can now be duckified!
NB: Currently untested.
GitHub Actions run 1840571999 succeeded.
Connected!
None
None
None
None
Many moderators moderate from iOS and Android mobile devices. As of today, Discord iOS doesn't allow for copying embed text at all, and Android iOS allows copying of embed text as a whole (not selectively).
One of the biggest pain points for moderators is not being able to grab the user's ID from the mod-alert embed, neither from the embed itself nor from the mention of the user (because the mention doesn't resolve properly).
A quick easy fix for this is to simply add the user ID outs...
None
None
Connected!
GitHub Actions run 1842168190 succeeded.
None
None
None
None
None
Greetings.
There seems to be no issue that was approved by a core developer before this PR was created. Please follow the contributing guidelines before making your next PR.
On another note, please see this page on making commits with great me...
GitHub Actions run 1844055164 succeeded.
377dcf9 Add Better Support For Whitelisting DM Commands - HassanAbouelela
eba75f7 Add .aoc link command - janine9vn
1dba7a7 Make self_placement_name keyword-only in .aoc lb - bsoyka
4959f08 Strip quotes from start/end of the username for... - bsoyka
aea61a0 Shorten parameter name for .aoc lb - bsoyka
GitHub Actions run 1844109210 succeeded.
4ec414a chore: Merge the .issue command into the github... - ToxicKidz
ba10b9b chore: Remove the .issue command - ToxicKidz
101001b chore: Apply suggested changes - ToxicKidz
cb41148 Make dataclasses hashable, and fix kwarg spelli... - ChrisLovering
cdd4067 use og_blurple in issue embed for consistency - ChrisLovering
[python-discord/sir-lancebot] branch deleted: merge\-github\-issues
GitHub Actions run 1844117271 succeeded.
None
None
27131b9 Disable AoC completionist task - ChrisLovering
[python-discord/sir-lancebot] New branch created: ChrisLovering\-patch\-1
This disabled the completionist task that checks the leaderboard for people who have 50 stars and gives out the role. Since the event is running, we are not keeping the session cookies up to date, so this is flooding #dev-log with errors.
This task should be altered in preparation for next event so that commenting out this line isn't required.
Relevant Issues
<!-- Link the issue by typing: "Closes #" (Closes #0 to close issue 0 for example). -->
Description
Did y...
GitHub Actions run 1844194252 succeeded.
@gitautas if you're not able to work on this PR anymore, would you like it to go up for grabs?
The time utility refactor has been merged.
It wasn't a suggestion to defer the whole PR but rather to defer that specific request.
@MarkKoz Sorry about my misunderstanding. Since it was such a long time ago, I don't remember if I was planning to follow up or not, but that's no longer relevant.
Would you like to continue this PR where it left off?
Bumping this PR, would anyone like to take over? This is still in high priority.
Sorry about all the additions/deletions for requests reviews, I forgot how to GitHub for a minute
Correct me if I'm wrong, but shouldn't we comment out the line that starts the completionist task?
self.status_task.add_done_callback(_helpers.background_task_callback)
# Don't start task while event isn't running
# self.completionist_task.start()
hi there!
is anyone is still working on the project?
if no i have a fork fixed, can i be assigned? thanks.
@Krish-bhardwaj Pinging you to make sure you see the above. Are you still working on this?
sounds pretty cool!
but i would like the thread is archived and non-unarchiveable by non-mods instead of getting deleted.
hi ||again||, can i being assigned? thanks.
@MaskDuck yes, you've been assigned
@Xithrius Yes, I will finish it up when I find some time. Hopefully that will be before next week.
Yeah, that seems good.
GitHub Actions run 1846358542 succeeded.
[python-discord/sir-lancebot] branch deleted: ChrisLovering\-patch\-1
833d2e5 Disable AoC completionist task - ChrisLovering
Connected!
GitHub Actions run 1846651538 succeeded.
Relevant Issues
<!-- Link the issue by typing: "Closes #" (Closes #0 to close issue 0 for example). -->
Closes #1024
Description
I disregareded the error when you are trying to edit a message that doesn't exist, using try except.
Did you:
- [x] Join the Python Discord Community? (yes, my discord have the ID 716134528409665586)
- [x] Read all the comments in this template?
- [x] Ensure there is an issue open, or link releva...
Usually we'd use contextlib.suppress here, but that's more of a nitpick and doesn't really matter.
[python-discord/forms-backend] New branch created: fix\-eval\-exploits
This PR hardens our snekbox script template against a few possible exploits that can force snekbox to pass failing code.
GitHub Actions run 1847253689 succeeded.
Hi @MarkKoz i was working on this issue sorry for being late i had my semester exams
i solved this issue my way but i don't know why this was not working

but after taking reference i made changes
I am new its up to you can can merge any PR . This was my first contribution requested to merge PR.

i guess this is your expected output
Relevant Issues
display realpython home page on blank .realpython command
- [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?
@Krish-bhardwaj You were the first to ask, so you have the right to work on the issue if you want. You have some code ready, so you can go ahead an open a pull request. Then someone will review it.

how can i solve this problem
ave the right to work on th
i have opened one PR i have a error in than can you please guide me
Connected!
GitHub Actions run 1848749713 succeeded.
@Krish-bhardwaj
You needed to follow the instructions in our contributing guidelines, which state you have to set up pre-commit hooks in your development environment. Set that up, run linting, and commit the changes.
GitHub Actions run 1849170712 failed.
I think that having the embed title have a link to the home page is possibly a better solution than just sending a link. At least, that is the idea I had in the beginning.

I think keeping the blank line in the docstring is more consistent with the style of the code base.
I don't think this needs to be a tuple, leaving it as:
if user_search is None:
Will work just fine
I think the linter is complaining about not having a new line at the end of the file.
I haven't really tried to escape or abuse the code before it, this is purely a functional approval. Works nicely and will be super useful! Thanks.
61d652a Rename voice_ban type to voice_mute - ChrisLovering
32d77fa Refactor voice_ban function definitions to voic... - ChrisLovering
07211bb Add voice_ban stub commands - ChrisLovering
b9df3f2 Merge branch 'main' into voicemute - ChrisLovering
5f4b557 Merge pull request #2052 from python-discord/vo... - ChrisLovering
GitHub Actions run 1849540630 succeeded.
751f295 Feat: add ability to snooze reminders - TizzySaurus
[python-discord/bot] New branch created: add\-reminder\-snoozing
Closes #2045.
Users can now "snooze" reminders, by pressing the "Snooze Reminder" button and then selecting a snooze duration from the dropdown menu that appears upon doing so.
I've tried to make this as resilient as I can, and have extensively tested it so there should hopefully not be any bugs ๐ค.
This is my first attempt at using dpy2.0 features, so please feel free to give suggestions as to any possible improvements as well as reviewing the code as-is.
GitHub Actions run 1849585189 succeeded.
GitHub Actions run 1849652478 failed.
40d5691 Fix: !raw can now be used in threads - TizzySaurus
[python-discord/bot] New branch created: fix\-bot\-2077
read_message_history is probably a better option for this check.
9c73f53 Chore: update error message when attempting to ... - TizzySaurus
Closes #2077.
!raw now works for messages inside threads.
Tested w/ help of @LiquidPulsar.
GitHub Actions run 1849774678 succeeded.
GitHub Actions run 1849782608 succeeded.
Deploy Prometheus & the cloudflare access-backed query interface.
Backed by PostgreSQL - migrate data from SQLite.
I can't do this on my own, as I need access to the SQLite database.
We need to ensure that NGINX is validating mutual TLS coming from Cloudflare to make sure all services are forced through Cloudflare (and specifically Cloudflare Access), this ensures ACL is A-Okay!
[python-discord/bot] New review comment on pull request #2089: Feat: add ability to snooze reminders
Why are we doing this? The defined select can be accessed as self.select_snooze_duration.
[python-discord/bot] New review comment on pull request #2089: Feat: add ability to snooze reminders
while we're here, rsplit("/", 1)[-1]
[python-discord/bot] New review comment on pull request #2089: Feat: add ability to snooze reminders
what exactly is the reason for this?
Our most important backing service, this needs to be set up as soon as possible due to the sheer amount of usefulness encapsulated in such a great deployment service.
This may be a good task to jump into the deployment setup with Ansible, and once we have the previous issues done, we can admit somebody to the DevOps team to take care of it.
[python-discord/bot] New review comment on pull request #2089: Feat: add ability to snooze reminders
I did notice this, but I also don't see a point in doing so. We only ever use the label, so there's not much point in defining a value (especially since not all values are fixed -- for durations >= 1 month).
Needs PostgreSQL and data migration.
"We actually need to configure it properly nad put SMTP information in the environment variables instead of just putting it everywhere"
- Joe Banks, DevOps Engineer
[python-discord/bot] New review comment on pull request #2089: Feat: add ability to snooze reminders
Why are we doing this? The defined select can be accessed as
self.select_snooze_duration.
This was simply copied from the code on lancebot:
https://github.com/python-discord/sir-lancebot/blob/main/bot/exts/utilities/epoch.py#L115
The Voices want to use KeyDB here instead, but their arguments come from weak minds.
"We're using KeyDB" - Voice 1
Voice 2 wants to mention that Chris is Voice 1.
Logging, monitoring, alerting, observability, lads!
[python-discord/bot] New review comment on pull request #2089: Feat: add ability to snooze reminders
I believe this may be a left-over try/except from when I was trying to debug a separate error.
The idea is that the message may be deleted before we edit it, but in reality I don't think this would happen.
Will be used for backups, although we should consider pgbarman as an alternative for PostgreSQL backups specifically.
Needs data migration of Graphite.
@jb3 is it possible to have the old Graphite instance push its data into the new one for a seamless switchover?
Mr. Hemlock does not have the time for this right now, because it's the middle of Texas season.
Mark might be interested in doing this.
Most of what King Arthur uses may need to be adjusted anyways, because we are SIGKILLing Kubernetes.
Let's implement IP bans in King Arthur to lock AS211224 out of connecting.
Needs data migration of Redis.
read_message_historyis probably a better option for this check.
Decided I'll just leave it as-is, since I'm pretty sure it won't make a difference within pydis anyway. If someone else thinks I should change this then I will.
Data here will not be migrated.
will not be migrated out of pure spite of people considering Redis a database
No. Redis is not a database, it's an in-memory key-value store. It's also called a [distributed] data structure server, which (at least to me) implies a tight coupling with your application: it's a way to offload shared state between multiple components, but the persistence of that shared state is not guaranteed. In fact, Redis...
This needs a MongoDB data migration.
Good introductory issue for people to get familiar with the setup (once base is set up).
As ....
joe
I want to...
prevent PRs from behind merged easily
Such that...
I can get a feeling of power by never reviewing any PR
Needs data migration of PostgreSQL.
Needs data migration of ๐ป SQLITE ๐ป
Backend - frontend is hosted at Netlify
May need a decision here as the deployment is quite involved.
Needs data migration.
I remember, very well, all the way back when I started work on the new site, I deployed it on bare metal, on Linux, on Debian, with gunicorn, behind nginx reverse proxy. It worked well, and then Joe "Complication Officer" Banks decided on making it as complicated as possible.
"I have no problem if you shitpost in all of the issues, but I have no idea what you're saying."
Lemon
Final service before dominion.
To clarify, I do not mean the end of the bot's project life, I mean the end of the migration process. I am not attempting a coup on the Python Discord deployment.
We need a central space for documenting topics of this deployment.
I would be happy to hear the team's thoughts here - what's a good, approachable place to put this?
cc @jchristgit @ChrisLovering @MrHemlock @minalike what would be the most approachable spot to find documentation?
Let's use markdown for this, especially with the new flowchart support.
@jb3 will set this up, link and structure it accordingly.
The first thing that comes to mind is Notion. The next thing that comes to mind is static page using GH Pages (never attempted this, so I don't know how involved it is). Lastly, it could just be loose files in a directory on this repo, but that's more difficult to navigate.
I'd like to work on this! I'm very new to open-source contributions, can someone please assign this to me and guide me a little?
I like. If you donโt get any further discussion by the end of the week, consider it approved.
There was some discussion on this internally, and we've decided that for now we'll take the approach mentioned in the OP.
Once the filters rewrite has been implemented, we'll most likely change this in favour of a button which sends a new ephemeral message consisting of only the user id (making it easier to copy since you're not also copying the Moderator's ping).
@minalike would you like to implement wht's in the OP yourself? If not I'm happy to do so.
GitHub Actions run 1854382957 succeeded.
[python-discord/infra] New branch created: jb3\-patch\-1
[python-discord/infra] branch deleted: jb3\-patch\-1
Originally got the idea from the Vortex bot and thought why not implement this in the pydis bot.
Basically, Vortex's way of doing it makes you provide the character in the command then everyone who is hoisted with that character and above will be dehoisted. I don't know if that's how python discord would want to do it. I was thinking of having more of an automated command that doesn't have any character input and dehoists people with characters from a set list. Here is an example of how vor...
I'm not sure how much we really care about members hoisting themselves up the member list, since you already need to scroll, ~6 pages just to get to normal members.
I don't think a command that will make that many api requests would be worth it for us, since I imagine there are easily >1k users with a symbol in their name.
It would only initially be a problem for the first time the command is run other than that it should be fine. But I understand where you are coming from.
[python-discord/infra] New branch created: 22\-nginx
Includes documented roles for:
- installing nginx & configuring handlers
- installing the mTLS certificate for Cloudflare
- installing firewall rules
They are kept separate for now, for composability.
Closes #22.
d66269d Optimize linting execution time - jchristgit
[python-discord/infra] New branch created: delete\-ansible\-lint
@RohanJnr What is your status?
GitHub Actions run 1855226805 succeeded.
@ChrisLovering @MarkKoz was there ever a resolution to this topic?
I'm also pretty sure that a subdirectory can be mounted as read-write. In Kubernetes for instance it's common to have the root directory mounted read-only and then a read-write subdirectory, so that should be fine.
@MarkKoz does this work for you?
15cac33 Return random off topic names which are Active ... - RohanJnr
[python-discord/site] branch deleted: otn\_active\_only
GitHub Actions run 1855297920 succeeded.
Just one small comment, everything else seems great ๐
So long as Nginx is installed before this is ran (which it currently is), this suggestion would work and be more explicit.
app: Nginx HTTPS
rule: allow
[python-discord/site] branch deleted: bsoyka\-typo
GitHub Actions run 1855306160 succeeded.
GitHub Actions run 1855309439 succeeded.
GitHub Actions run 1855318965 succeeded.
Description
allow the source command in dev contrib
Reasoning
its a dev contribution channel, we should be able to run the source command because of its relevance to the channel
Proposed Implementation
add dev contrib to the source command whitelist
Would you like to implement this yourself?
- [ ] I'd like to implement this feature myself
- [x] Anyone can implement this feature
1ffc346 Bump log to INFO so it gets shown in production - TizzySaurus
I approve of this message.
GitHub Actions run 1855438353 succeeded.
disabled automerge as I cannot merge main into this branch since the enable commits from maintainers wasn't enabled on the PR. Once this branch is updated to main, we can merge it.
From searching for around 30 minutes, the only issue that remains today that I could find was the log statement in Mark's above comment, and in discussion with @D0rs4n we decided it's not really worth PRing a fix since it has humanised time with it anyway.
As such, this issue can likely be closed, but @D0rs4n wishes to take a look themselves before we do so.
[python-discord/bot] branch deleted: fix\-bot\-2077
GitHub Actions run 1855462080 succeeded.
Right now, there are three problems with the logos displayed in our sponsor hero and in the footer of the site.
An alignment issue with the logos on Windows.
This problem is described in #458. We should optimize the background-position so that this problem will look optimal on Windows machines, since our typical visitor is a Windows user.
Hacky filtering to turn logos into white logos
Right now, we're using filter in CSS to turn the Django and Linode logos into something tha...
Connected!
GitHub Actions run 1855478232 succeeded.
Connected!
GitHub Actions run 1855506437 succeeded.
465c2f5 Reply with log url after cleaning messages - ChrisLovering
caaf0fa Support not deleting invoking message of a clea... - ChrisLovering
3a7871b Update respect_role_hierarchy decorator to pass... - ChrisLovering
15fb882 Change purgeban to use custom clean logic - ChrisLovering
954c1a9 Add more aliases to purgeban - ChrisLovering
[python-discord/bot] branch deleted: purge\-to\-clean
GitHub Actions run 1855516297 succeeded.
Connected!
GitHub Actions run 1855533624 succeeded.
2d540a9 Remove unnecessary Infraction conversion in cle... - ChrisLovering
[python-discord/bot] New branch created: optimise\-cban
apply_ban already returns the data exactly how it's needed, so we don't need to call the infraction convertor and use an API call to site.
@jchristgit Last time I was debugging this, it was not working. I still have no idea why.
GitHub Actions run 1855581925 failed.
You didn't lint before you pushed, you must now perish.
Once test is fixed then we're good to go
Should this just be dropped if we're going to be creating separate roles anyway? https://github.com/python-discord/infra/blob/main/roles/ufw/tasks/main.yml#L33-L37
7e8e95f Remove unnecessary Infraction conversion in cle... - ChrisLovering
[python-discord/bot] branch deleted: optimise\-cban
GitHub Actions run 1855628706 succeeded.
Connected!
GitHub Actions run 1855642186 succeeded.
ca1ccc0 fixup: Use audit log to determine manually arch... - ChrisLovering
Hi, saw this and wanted to explain a 100% guaranteed way to know if it was manual or automatic: manual closes will have an audit log entry. If there's no relevant audit log entry then it safe to assume that the thread closed automatically, rather than manual.
Were you expecting something like this?
https://github.com/python-discord/bot/pull/2084/commits/0ae5ee9c478bd4a627473acce8a46de3965176b9
Should this just be dropped if we're going to be creating separate roles anyway? https://github.com/python-discord/infra/blob/main/roles/ufw/tasks/main.yml#L33-L37
Hmm, I'm 50/50 of it. On one hand it's nice to have a common base spot to configure this stuff, on the other hand, your configurations for services start drifting around in the repository. For instance - in your postgresql configuration you add the site database, then in your UFW configuration you add this port, .... Does that...
GitHub Actions run 1855711189 was cancelled.
GitHub Actions run 1855714415 succeeded.
on the other hand, your configurations for services start drifting around in the repository. For instance - in your postgresql configuration you add the site database, then in your UFW configuration you add this port, .... Does that make sense?
Sort of. Why can't the same be said for this PR's approach where the there is a separate role for nginx ufw rather than a single nginx role for all nginx things?
Sort of. Why can't the same be said for this PR's approach where the there is a separate role for nginx ufw rather than a single nginx role for all nginx things?
Because NGINX and UFW are independent services, and the NGINX role does not perform any configuration of NGINX sites by itself.
Because NGINX and UFW are independent services, and the NGINX role does not perform any configuration of NGINX sites by itself.
Isn't that the case for every service that needs a UFW config? I'm not following how creating a separate "<service>-ufw" role for each service is any better regarding "drifting around in the repository" than using a centralised location.
Guild.audit_logs() is an async iterator.
async for thread_update in guild.audit_logs(limit=200, action=discord.AuditLogAction.thread_update):
hah, you're right, I had this as async locally before I refactored the function and missed this :(
GitHub Actions run 1855877122 succeeded.
e4713c4 Add community_meta to bot.constants.Channels - TizzySaurus
c937442 Rename bot.constants.Channels.bot to bot.con... - TizzySaurus [6b4adee](https://github.com/python-discord/sir-lancebot/commit/6b4adee6639c1a6f224924e3401d4b776c881899) Rename bot.constants.Channels.community_bot_co... - TizzySaurus
88d54d3 Allow .src command in community-meta and dev-... - TizzySaurus
[python-discord/sir-lancebot] New branch created: fix\-issue\-1032\-temp
Relevant Issues
Closes #1032
<!-- Link the issue by typing: "Closes #" (Closes #0 to close issue 0 for example). -->
Description
- Renamed some Channel constants so that it's clearer what they're referring to
- Added community-meta to Channel constants
- Added support for
.srcin dev-contrib and community-meta via the@whitelist_overridedecorator.
Did you:
- [x] Join the Python Discord Community?
- [x] Read all the com...
Looks good. Did a quick grep for the changed constants and couldn't find any other places where the old names were used. Thanks ๐
df6c8a4 fixup: check for archived attr before using it - ChrisLovering
GitHub Actions run 1855960351 succeeded.
This should return after this line, otherwise thread won't be set, causing an AttributeError.
GitHub Actions run 1856008532 succeeded.
Yea, will add a continue after this line
Is there a reason we don't just use Guild.get_channel_or_thread() here?
GitHub Actions run 1856065340 succeeded.
GitHub Actions run 1856084662 succeeded.
GitHub Actions run 1856175055 succeeded.
This might need to be updated.
LGTM, works well, , just one comment.
Changed this to You must provide a thread, or run this command within a thread. during the squash.
GitHub Actions run 1856209922 succeeded.
There's one line that causes an error, but other than that this looks good.
DMChannel has no guild attribute.
if message.guild:
Only saw this after I pressed the submit review button, but wait_for_deletion() only accepts messages that are in guilds. Although, I don't think we should really support code snippets in DMs anyways.
In the past few days, there has been two instances of users adding a regex to the filter_token that wasn't valid, leading to #dev-alerts being spammed with regex-related errors.
This issue proposes that we should validate the regex when adding to the bucket, and if it's not valid, then we return an error message and don't add to the bucket to save these alerts.
In terms of implementation, should be a case of doing a try/except on a re.compile.
I wasn't aware that this was a thing.
Although looking at the docs, that would also get voice channels etc., not just TextChannel or Thread. Is this something that matters?
Good catch :+1:
Have fixed.
I don't think we should really support code snippets in DMs anyways.
I think it's nice to support as many features in DMs as we can. It's relatively easy to support code snippets in DMs, so I think we should.
wait_for_deletion()only accepts messages that are in guilds.
Thanks, have fixed :+1:
GitHub Actions run 1857755900 succeeded.
I think it's nice to support as many features in DMs as we can. It's relatively easy to support code snippets in DMs, so I think we should.
I disagree with this, and I believe thatโs the general view of the core dev team as well. There is a very, very clear cost (this entire PR) to supporting these features in DMs, which doesnโt seem to balance against the benefits. You could always justโฆ run this feature in bot-spam.
Eh, I guess.
I've fixed this now though so we might as well merge it ๐คท.
The previous behaviour has now been migrated over to voice_mute. voice_ban currently has stub commands, so who ever picks up this ticket show implement those as described above.
abfb0ed Validate regex when adding to the filter_token ... - TizzySaurus
[python-discord/bot] New branch created: fix\-bot\-2093
Closes #2093.
When a user attempts to add a regex to the filter_token filter, the regex is now validated before being added to prevent errors when checking if a message matches the regex. If the regex isn't valid, an error message is sent informing the user that an invalid regex was passed, and the regex doesn't get added to the filter list.
GitHub Actions run 1858247137 succeeded.
Well, I wouldn't worry about getting reactions inside a voice channel.
Surely it would break stuff. E.g. on L183 we do channel.fetch_message, which would raise an error for a VoiceChannel (voice channels don't have such a method)
I'll update this to use Guild.get_channel_or_thread
7110024 Use discord.Guild.get_channel_or_thread() ins... - TizzySaurus
GitHub Actions run 1858360650 succeeded.
re.error is going to contain where it failed. Consider adding the error message to the output message. An example is: https://github.com/python-discord/bot/blob/7e8e95f07e343f1d7d9a8069b6cdb1a9fcbb00d7/bot/exts/moderation/clean.py#L56
b0e21f0 Include regex error in failure message - TizzySaurus
re.error is going to contain where it failed. Consider adding the error message to the output message. An example is:
Yep! Added :+1:
GitHub Actions run 1858443694 succeeded.
Description
Wordle is a very, very popular word game that's rising in players.
Reasoning
It's a game that would be fun to play with others, and the game would probably appeal to most people.
Proposed Implementation
I have built a working Wordle generator, which would be too complicated to go in detail on Github. It will use modals, buttons.
There are only two issues currently, and that's 1. Modals aren't supported by discord.py, and I do not see SirLancebot using an alternative....
GitHub Actions run 1860931672 succeeded.
PR Author
Workflow Run
Source Branch
monkey-patch-url-...
GitHub Actions run 1860975756 succeeded.
PR Author
Workflow Run
Source Branch
monkey-patch-url-...
GitHub Actions run 1861017368 succeeded.
PR Author
Workflow Run
Source Branch
monkey-patch-url-...
GitHub Actions run 1861025412 succeeded.
PR Author
Workflow Run
Source Branch
monkey-patch-url-...
GitHub Actions run 1861068981 succeeded.
GitHub Actions run 1861093932 succeeded.
44afbcf Only sync thread archive status on startup - ChrisLovering
38a38d3 Ignore threads in forum channels - ChrisLovering
b1ca171 Listen for thread create and unarchive events - ChrisLovering
3040859 Bump metricity version following bug fixes - ChrisLovering
e5b81f2 Merge pull request #13 from python-discord/thre... - jchristgit
[python-discord/metricity] branch deleted: threadfixes
Fix them file conflicts and we'll be good.
Fix them file conflicts and we'll be good.
This PR is now up for grabs. Would anyone that's currently subscribed to this thread or just happened to see this comment like to take over this feature?
Hello, Iโd like to have a go at this in a separate PR.
@Xithrius Currently this PR is complete, only needs another core-dev approval.
Cool okay ๐๐ป , let me know if you need any help while going through the code @ToxicKidz.
Closes #2088
This is a temporary quality of life improvement for moderators on mobile.
GitHub Actions run 1862295702 succeeded.
but this will probably be a temporary solution
will you be making an issue to track the permanent solution?
At the moment I think we shouldn't, as it's too far out. I'd rather we wait til we have new filter system merged and running.
At the moment I think we shouldn't, as it's too far out. I'd rather we wait til we have new filter system merged and running.
From my experience, it's generally better to create the issue early, add the "stalled" label, and then link it to the PR that needs to be complete first.
That way it ensure we don't forget, and we can see what the other PR (in this case the rewrite) is blocking too.
Additionally if we use buttons I'd rather we just have the options we want (user and infrac...
7c8458c Remove auto joining of new threads. - TizzySaurus
[python-discord/bot] New branch created: fix\-bot\-2004
Closes #2004.
As per discussion with @ChrisLovering in dev-contrib, this PR removes the code for auto-joining new threads, since this functionality isn't needed and has a race condition issue (as per #2004).
GitHub Actions run 1863919036 succeeded.
Could do: Not really going to change much, but there's no need to assign this to a variable right?
re.compile(content)
I'm not sure if a reaction and a message is needed here. Either one or the other would be fine. Just removes one unnecessary API call.
If you want to keep the โ, then it could be added to the start of the message.
Connected!
GitHub Actions run 1863948020 succeeded.
We currently do both of these, so why not here?
Yep, for some reason I forgot you don't have to assign.
permissions_for works on all GuildChannel objects, and also takes into account default role permissions, so this whole function can be simplified quite a lot. The channel type hint can also be changed to discord.GuildChannel, since this funciton is available on all GuildChannel objects.
def is_helper_viewable(channel: discord.GuildChannel) -> bool:
"""Return whether helpers can view the given channel."""
helper_role = guild.get_role(constants.Roles.helpers)
return...
Yea true, probably fine though, not sure if it's needed, but not worth changing if it already exists elsewhere.
actually, it seems Thread doesn't actually subclass GuildChannel, but rather Messageable, however it still implements this function in a similar way.
Not all Messageable objects implement this however, so the correct type hint for channel would be Union[discord.GuildChannel, discord.Thread
I agree with Scale here, we don't want to support things in DMs with the bot. I think the correct solution to this sentry issue is to just add the below conditional to the top of the event listener.
if not message.guild:
return
my only outstanding comment isn't required for this to work, so approving anyway.
[metricity] Branch message\-sync\-command was force-pushed to `804f8c5`
There are 1 failures, 0 warnings, and 0 notices.
[metricity] Branch message\-sync\-command was force-pushed to `df0473a`
[metricity] Branch message\-sync\-command was force-pushed to `12d7001`
There are 1 failures, 0 warnings, and 0 notices.
GitHub Actions run 1864550273 succeeded.
Although, the only channel you can get reactions from is TextChannel and Thread (also PrivateChannel, but we do a check for the guild), so the current typehint is also correct.
Yea, that's true. Although looking at the file, this function is only actually used once. So imo this function can be deleted and this condition can just be changed to
helper_role = guild.get_role(constants.Roles.helpers)
if not channel.permissions_for(helper_role).view_channel:
return
When trying to add a thread which is already in the bump list, it might be useful to send a message like "Thread is already in the bump list. ".
Two minor suggestions, feel free to ignore if you feel they're not needed.
@thread_bump_group.command(name="add", aliases=("a",))
How about adding a as an alias to add? Feel free to ignore this comment because add is short as it is, but, personally, I would expect a to be an alias for add since r is an alias for remove.
GitHub Actions run 1864948046 succeeded.
Connected!
GitHub Actions run 1864969842 succeeded.
Sorry, but I one more thing I wanted to point out :sweat_smile: .
PS: I believe you can do something like this here instead.
if await bumped_threads.contains(after.id):
await self.unarchive_threads_not_manually_archived([after])
You could also use RedisCache.contains() in line 88 if you decide to incorporate this suggestion.
Yeah, I went through all the possible places where this could go wrong, and I could only find that log statement as well.
I observed this log statement more, and I believe it would be great if we could refactor this log message, though. Just for the sake of consistency.
So I'll keep this issue open, it should be a fairly easy patch.
(The mentioned log message again:
https://github.com/python-discord/bot/blob/9bae829f91c00f89fd1e725036f4d24ec796410b/bot/exts/moderation/stream.py#L137
)
[python-discord/infra] branch deleted: delete\-ansible\-lint
Closing per discussion.
Isn't that the case for every service that needs a UFW config? I'm not following how creating a separate "[service]-ufw" role for each service is any better regarding "drifting around in the repository" than using a centralised location.
Yes, but also no.
The problem is that if I configure the UFW firewall rules in the inventory as a variable, like e.g. this:
podman:
hosts:
turing:
lovelace:
hopper:
ritchie:
vars:
...
GitHub Actions run 1865664789 succeeded.
I don't think we refuse to help people with projects that contain ytdl as long as the question doesn't involve it then it's fine.
Connected!
GitHub Actions run 1866650409 succeeded.
We actually do. The rules channel clearly says so:
Do not provide or request help on projects that may break laws, breach terms of services, or are malicious or inappropriate.
youtube_dl breaches the terms of services of YouTube, so according to rule 5, we should not help anyone that uses youtube_dl in the project they're asking help for.
Continued work on #2096
Further closes #2088
This PR
- additionally adds the user ID for antispam alerts
- removes the user ID for autoban alerts
I'll make an additional commit to rename the content in the code block below, since it overlaps with the content parameter used a little later on.
I didn't quite understand what lines 98-101 were doing though, and need some guidance on good rename suggestions for content ๐
https://github.com/python-discord/bot/blob/389cb815a37...
GitHub Actions run 1866917456 succeeded.
Thank you for suggesting this resource, and for your patience in awaiting our decision. We don't feel that the Discord server associated with this library is of sufficient benefit to our users, and so we won't be featuring Dear PyGui or the associated Discord server at this time. By our observation, questions about Dear PyGui in our server are infrequent, and so we don't see added value in listing an alternative location in which to ask about the library.
I realize you may feel that if oth...
GitHub Actions run 1868112641 succeeded.
Will skip the additional commit and my curiosity about the above code is satisfied. Please review!
Make this a set, so the same user_id isn't sent more than once.
content=", ".join({str(m.id) for m in self.members}), # quality-of-life improvement for mobile moderators
Actually, members is already a frozenset, so this can be ignored.
[python-discord/site] New branch created: thread\-dumping\-support
Following our move to use Redis as just a cache, this PR allows the site to store a list of threads that need to be bumped.
The bot will interact with this within the ThreadBumper cog.
This also moves the imports of FilterList around, so that they're alphabetised.
GitHub Actions run 1869540513 succeeded.
78553a9 Remove expired coupon code and update course name - wookie184
[python-discord/site] New branch created: wookie184\-patch\-1
Removed expired coupon code and updated course name for automate the boring stuff udemy course
[python-discord/site] branch deleted: wookie184\-patch\-1
GitHub Actions run 1869598310 succeeded.
GitHub Actions run 1869620586 succeeded.
GitHub Actions run 1869624838 succeeded.
GitHub Actions run 1869624623 succeeded.
GitHub Actions run 1869628090 succeeded.
GitHub Actions run 1869635547 succeeded.
PR Author
Workflow Run
Source Branch
fix-lance-cache-path
GitHub Actions run 1869641658 succeeded.
GitHub Actions run 1869877324 succeeded.
GitHub Actions run 1869884663 succeeded.
97ddd3a Add user ID to message content for all mod alerts - minalike
7c8458c Remove auto joining of new threads. - TizzySaurus
681ba54 Merge pull request #2096 from minalike/enhancem... - ChrisLovering
a52e465 Merge branch 'main' into fix-bot-2004 - ChrisLovering
9bae829 Merge pull request #2097 from python-discord/fi... - ChrisLovering
abfb0ed Validate regex when adding to the filter_token ... - TizzySaurus
b0e21f0 Include regex error in failure message - TizzySaurus
f500249 Remove unnecessary assignment - TizzySaurus
a56100b Merge branch 'main' into fix-bot-2093 - ChrisLovering
ddb5d80 Merge pull request #2094 from python-discord/fi... - ChrisLovering
[python-discord/bot] branch deleted: fix\-bot\-2093
Connected!
GitHub Actions run 1869893328 succeeded.
Connected!
GitHub Actions run 1869900168 succeeded.
Relevant Issues
Closes #1035
Description
Let the logs attribute of invalid latex errors be None if its missing in the API response, and handle the case with a slightly different embed.
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/...
GitHub Actions run 1870994903 succeeded.
0d51688 Start from upstream main branch - brad90four
15d545e Create draft body of file - brad90four
969ab35 Add colorsys import, verbage for using JSON - brad90four
b66e613 Added ryanzec_colours.json constructed from rya... - CyberCitizen01
663b528 Added ryanzec_colours.json constructed from rya... - CyberCitizen01
GitHub Actions run 1871736223 succeeded.
436c9f7 Allow .src in dev-contrib and community-meta ... - TizzySaurus
[python-discord/sir-lancebot] branch deleted: fix\-issue\-1032\-temp
GitHub Actions run 1871741263 succeeded.
can i be assigned?
This hasn't been approved yet, but if/when it does then I don't see an issue with that.
b55add3 Migrate to og_blurple - TizzySaurus
17bcd45 Merge remote-tracking branch 'origin/main' into... - TizzySaurus
e69f65c Merge remote-tracking branch 'origin/main' into... - TizzySaurus
a921f48 Merge remote-tracking branch 'origin/main' into... - TizzySaurus
e232b7c Merge remote-tracking branch 'origin/main' into... - TizzySaurus
[python-discord/sir-lancebot] New branch created: fix\-error\-in\-pull\-1033
Relevant Issues
There's no issue created yet, but this is fixing [this](#dev-alerts message) dev-alerts.
<!-- Link the issue by typing: "Closes #" (Closes #0 to close issue 0 for example). -->
Description
Now adds a tuple to a tuple instead of a list to a tuple.
Did you:
- [x] Join the Python Discord Community?
- [x] Read all the comments in this template?
- [x...
GitHub Actions run 1871770316 succeeded.
Sentry Issue: SIR-LANCEBOT-7Z
TypeError: can only concatenate tuple (not "list") to tuple
File "discord/ext/commands/bot.py", line 660, in _load_from_module_spec
spec.loader.exec_module(lib) # type: ignore
File "", line 850, in exec_module
File "", line 228, in _call_with_frames_removed
File "bot/exts/core/source.py", line 14, in
class BotSource(commands.Cog):
File "bot/ex...
b55add3 Migrate to og_blurple - TizzySaurus
17bcd45 Merge remote-tracking branch 'origin/main' into... - TizzySaurus
e69f65c Merge remote-tracking branch 'origin/main' into... - TizzySaurus
a921f48 Merge remote-tracking branch 'origin/main' into... - TizzySaurus
e232b7c Merge remote-tracking branch 'origin/main' into... - TizzySaurus
[python-discord/sir-lancebot] branch deleted: fix\-error\-in\-pull\-1033
Connected!
GitHub Actions run 1871785798 succeeded.
This command already exists.
They're suggesting that the command be updated to use relative timestamps instead of manually getting humanized time.
Right, now I understand ๐
cf66e71 Remove discord formatted timestamp from log mes... - TizzySaurus
[python-discord/bot] New branch created: fix\-bot\-1751
Closes #1751.
Changes log message to show humanised duration as well as end timestamp in a YYYY-mm-dd HH:MM:SS format.
Has been tested as seems to be working perfectly :+1:
GitHub Actions run 1871845456 succeeded.
@D0rs4n done in #2100 :+1:
[python-discord/sir-lancebot] New branch created: add\-run\-bot\-step\-during\-lint
sure i can work on this! can i be assigned again?
Description
This adds a step to our linting action to catch errors in imports/cog setup functions before they are merged by running the bot package, but not actually calling bot.run().
Adding it to the lint flow means we already have the code checked out and a poetry env, so it adds ~1s to CI time.
See here fir a passing action https://github.com/ChrisLovering/sir-lancebot/runs/5264386120?check_suite_focus=true
This is a failing one https://github.com/ChrisLovering/sir-lancebot...
GitHub Actions run 1871872273 succeeded.
I would argue that this new step should be inserted higher up the workflow.
In the case of a syntax error, the error would be reported much better by this step, while flake8 doesn't give any detail about such an error.
Considering this step doesn't take much time, I think it is fine to have it run first.
I would argue that this new step should be inserted higher up the workflow.
In the case of a syntax error, the error would be reported much better by this step, while flake8 doesn't give any detail about such an error.
Considering this step doesn't take much time, I think it is fine to have it run first.
On the flip side flake8 gives errors that this wouldn't give any detail about too.
So is the argument here to order the steps fastest to slowest, so that the workflow fa...

