aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeLines
...
| | | | | | | | | | | | | * | | | | HelpChannels: fix race condition between claiming and unclaimingGravatar MarkKoz2021-01-04-1/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The race condition is when a user claims a channel while their other channel is being unclaimed. Specifically, it's while their cooldown is being removed. The lock ensures that either the cooldown will be re-applied after it's removed or that it won't be removed since `unclaim_channel` will see the user has another claimed channel.
| | | | | | | | | | | | | * | | | | Lock: support waiting until a lock is availableGravatar MarkKoz2021-01-04-37/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It's been determined that asyncio.Lock is safe to use in such manner. Therefore, replace LockGuard entirely with asyncio.Lock.
| | | | | | | | | | | | | * | | | | HelpChannels: refactor channel unclaimingGravatar MarkKoz2021-01-04-20/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Narrow the scope of `move_to_dormant` to just moving the channel. Following the design of `claim_channel`, make `unclaim_channel` handle cooldowns and unpinning.
| | | | | | | | | | | | | * | | | | HelpChannels: remove obsolete channel position trace logGravatar MarkKoz2021-01-04-1/+0
| | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | * | | | | HelpChannels: refactor stat trackingGravatar MarkKoz2021-01-04-27/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Move significant code related to stats to a separate module.
| | | | | | | | | | | | | * | | | | HelpChannels: move function to the channel moduleGravatar MarkKoz2021-01-04-42/+45
| | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | * | | | | HelpChannels: prevent user from claiming multiple channels quicklyGravatar MarkKoz2021-01-04-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It's conceivable for a user to be able to quickly send a message in all available channels before the code has a chance to add the cooldown role. Place a lock on the author to prevent the claim code from running multiple times for the same user.
| | | | | | | | | | | | | * | | | | HelpChannels: await init task at the start of event listenersGravatar MarkKoz2021-01-04-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It feels safer to do this since the init task moves channels to different categories and the listeners check if channels are in certain categories.
| | | | | | | | | | | | | * | | | | HelpChannels: use a more accurate lock for messagesGravatar MarkKoz2021-01-04-47/+35
| | |_|_|_|_|_|_|_|_|_|_|/ / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Use the `lock_arg` decorator to keep a separate lock for each channel rather than a single lock used by all messages. Separate the core logic in `on_message` into a separate function to facilitate the use of `lock_arg` - not everything in `on_message` needs to be under the lock.
| * | | | | | | | | | | | | | | | Merge pull request #1340 from python-discord/ks123/raw-fixGravatar Matteo Bertucci2021-01-04-2/+6
| |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add check does user have permission to get raw message and re-enable raw command
| | * \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ Merge branch 'master' into ks123/raw-fixGravatar Matteo Bertucci2021-01-04-71/+131
| | |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | |/ / / / / / / / / / / / / / / / | |/| | | | | | | | | | | | | | | |
| * | | | | | | | | | | | | | | | | Merge pull request #1152 from python-discord/Make_nomination_reason_optionalGravatar Dennis Pham2021-01-03-8/+8
| |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make nomination reason optional.
| | * \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ Merge branch 'master' into Make_nomination_reason_optionalGravatar Dennis Pham2021-01-03-45/+60
| | |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | |/ / / / / / / / / / / / / / / / / | |/| | | | | | | | | | | | | | | | |
| * | | | | | | | | | | | | | | | | | Merge PR #1345 - Update d.py to fix webhook message publishingGravatar Mark2021-01-03-45/+60
| |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | |_|_|_|_|_|_|/ / / / / / / / / / / | |/| | | | | | | | | | | | | | | | |
| | * | | | | | | | | | | | | | | | | Update discord.py to fix webhook message publishing.Gravatar Den42002021-01-01-45/+60
| |/ / / / / / / / / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Related to #1342.
| | * | | | | | | | | | | | | | | | Removed 'Optional' import.Gravatar xithrius2021-01-02-1/+1
| | | | | | | | | | | | | | | | | |
| | * | | | | | | | | | | | | | | | Removed unnecessary debugging logs.Gravatar Xithrius2021-01-02-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Co-authored-by: Dennis Pham <[email protected]>
| | * | | | | | | | | | | | | | | | Set reason to default as an empty string.Gravatar Xithrius2021-01-02-5/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Co-authored-by: Dennis Pham <[email protected]>
| | * | | | | | | | | | | | | | | | No nominaton reason blank replaced by italic NoneGravatar xithrius2021-01-02-2/+4
| | | | | | | | | | | | | | | | | |
| | * | | | | | | | | | | | | | | | Rebased master into this branch.Gravatar xithrius2021-01-02-6460/+7705
| | |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | |/ / / / / / / / / / / / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The cogs folder no longer exists, but the merge command was able to automagically find the correct files to merge into. Nomination reason is now optional.
| * | | | | | | | | | | | | | | | | Merge pull request #1334 from python-discord/bug/precommit-pycharmGravatar ks1292020-12-31-1/+1
| |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix flake8 pre-commit hook running through PyCharm
| | * \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ Merge branch 'master' into bug/precommit-pycharmGravatar ks1292020-12-31-297/+322
| | |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | |/ / / / / / / / / / / / / / / / / | |/| | | | | | | | | | | | | | | | |
| * | | | | | | | | | | | | | | | | | Merge pull request #1339 from python-discord/swfarnsworth/infoGravatar Dennis Pham2020-12-31-3/+3
| |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | `!user` command says if a user is "Verified", rather than "Pending"
| | * | | | | | | | | | | | | | | | | | "Pending: False" to "Verified: True" to agree with new semantics.Gravatar Steele2020-12-30-1/+1
| | | | | | | | | | | | | | | | | | | |
| | * | | | | | | | | | | | | | | | | | Merge branch 'master' of https://github.com/python-discord/bot into ↵Gravatar Steele2020-12-30-14/+59
| | |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | |/ / / / / / / / / / / / / / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | swfarnsworth/info
| | * | | | | | | | | | | | | | | | | | `!user` command says if user is "Verified"Gravatar Steele2020-12-25-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously, `!user` said if the user is "Pending", whereas "Verified" is the boolean opposite.
| | | * | | | | | | | | | | | | | | | | Fix flake8 pre-commit hook running through PyCharmGravatar MarkKoz2020-12-19-1/+1
| | | | | | | | | | | | | | | | | | | |
| | | | * | | | | | | | | | | | | | | | Fix import order to pass linting tests.Gravatar Eivind Teig2020-09-12-1/+1
| | | | | | | | | | | | | | | | | | | |
| | | | * | | | | | | | | | | | | | | | Update user cache after nomination reason edit.Gravatar Eivind Teig2020-09-12-1/+1
| | | | | | | | | | | | | | | | | | | |
| | | | * | | | | | | | | | | | | | | | Only show reason if it exist.Gravatar Eivind Teig2020-09-12-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reduce the footer to not include reason if it does not exist.
| | | | * | | | | | | | | | | | | | | | Make nomination reason optional.Gravatar Eivind Teig2020-09-12-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We want to make the nominate command more attractive for our members of staff.
| | | | | * | | | | | | | | | | | | | | Update raw command no permission error messageGravatar ks1292020-12-28-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Co-authored-by: Xithrius <[email protected]>
| | | | | * | | | | | | | | | | | | | | Enable raw commandGravatar ks1292020-12-27-2/+2
| | | | | | | | | | | | | | | | | | | |
| | | | | * | | | | | | | | | | | | | | Add check does user can see channel in raw commandGravatar ks1292020-12-27-0/+4
| | | |_|/ / / / / / / / / / / / / / / | | |/| | | | | | | | | | | | | | | |
* | | | | | | | | | | | | | | | | | | Cleans Up Voice Sync TestsGravatar Hassan Abouelela2021-01-10-18/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Cleans up the tests related to the voice sync/kick functions by adding a helper method to simplify mocking.
* | | | | | | | | | | | | | | | | | | Cleans Up & Simplifies TestsGravatar Hassan Abouelela2021-01-10-80/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Cleans up the silence tests by removing unneeded or repeated mocks. Simplifies tests where possible by joining similar tests.
* | | | | | | | | | | | | | | | | | | Improves Unsilence Wrapper DocstringGravatar Hassan Abouelela2021-01-10-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Modifies the unsilence wrapper docstring to make the arguments and behavior more clear.
* | | | | | | | | | | | | | | | | | | Breaks Out Send Message TestsGravatar Hassan Abouelela2020-12-29-75/+81
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Moves the tests for the helper method `send_message` to simplify tests, and avoid repeated code.
* | | | | | | | | | | | | | | | | | | Makes Kick Keyword Only ParameterGravatar Hassan Abouelela2020-12-29-3/+3
| | | | | | | | | | | | | | | | | | |
* | | | | | | | | | | | | | | | | | | Adds Error Handling For Voice Channel MutingGravatar Hassan Abouelela2020-12-29-5/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adds error handlers to allow voice channel muting to handle as many members as possible.
* | | | | | | | | | | | | | | | | | | Refractors Helper Method SignaturesGravatar Hassan Abouelela2020-12-29-27/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes the signatures of a few helper methods to make them more concise and understandable.
* | | | | | | | | | | | | | | | | | | Merge branch 'master' into voicechannel-muteGravatar Hassan Abouelela2020-12-29-160/+238
|\| | | | | | | | | | | | | | | | | |
| * | | | | | | | | | | | | | | | | | Merge pull request #1016 from ks129/bug-fixesGravatar ks1292020-12-29-14/+59
| |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | |/ / / / / / / / / / / / / / / / / | |/| | | | | | | | | | | | | | | | | Some bug fixes
| | * | | | | | | | | | | | | | | | | Merge branch 'master' into bug-fixesGravatar ks1292020-12-29-554/+567
| | |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | |/ / / / / / / / / / / / / / / / / | |/| | | | | | | | | | | | | | | | |
| * | | | | | | | | | | | | | | | | | Merge pull request #1328 from python-discord/swfarnsworth/developer_commandGravatar ks1292020-12-24-10/+12
| |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Manual verification with `!verify` sends the user the confirmation DM.
| | * | | | | | | | | | | | | | | | | | `if user.pending` -> `if not user.pending`Gravatar Steele Farnsworth2020-12-24-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This was a logic error. This functionality is unfortunately difficult to test outside of production.
| | * | | | | | | | | | | | | | | | | | `ALTERNATE_VERIFIED_MESSAGE`: "You're" -> "You are".Gravatar Steele2020-12-23-1/+1
| | | | | | | | | | | | | | | | | | | |
| | * | | | | | | | | | | | | | | | | | Merge branch 'master' of https://github.com/python-discord/bot into ↵Gravatar Steele2020-12-23-136/+167
| | |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | |/ / / / / / / / / / / / / / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | swfarnsworth/developer_command
| * | | | | | | | | | | | | | | | | | | Merge pull request #1337 from python-discord/ks123/pepGravatar Dennis Pham2020-12-23-136/+167
| |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Move PEP command and utils to own cog, fix bug related not checking status and add GitHub token
| | * \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ Merge branch 'master' into ks123/pepGravatar Dennis Pham2020-12-23-10/+42
| | |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | |/ / / / / / / / / / / / / / / / / / / | |/| | | | | | | | | | | | | | | | | | |