TabletBot rewrite to poise#23
Merged
InfinityGhost merged 5 commits intoOpenTabletDriver:masterfrom Dec 7, 2023
Merged
Conversation
Member
Author
|
Other than fixing the workflow it should work just fine. |
Member
Author
|
Not even sure how the workflow works or what needs changing but I'll look into it. |
c932849 to
f1513e5
Compare
Member
Author
|
I have gone ahead and pushed a new flake simply to fix the workflow (it needed newer rust and nix unstable didn't have it). This probably isn't the best way to do it, as well as it no longer includes the dev shell or the default.nix file. I would prefer if somebody else came up with a proper solution but at this moment I don't have the energy to figure out a better way of doing it. |
- Uses serenity 0.12 (poise doesn't have a release targetting it yet) - Fixes the Nix build action.
- Adds buttons to manipulate issue embeds - Add issue tokens to allow for linking other repositories - Add edit-embed support.
7babed9 to
b0a4ec7
Compare
- Fixes missing . in regex for repos - fix list-repos sending 2 messages - fix missing url (and url parsing) in embed command - fix embed command sending 2 responses in certain errors. - lazily match everywhere due to autocomplete limitations - remove redundant 25+ snippet warning
Member
|
This pr is big enough, and we've already deployed some revisions of it so I figure we can go ahead and merge this. |
InfinityGhost
approved these changes
Dec 7, 2023
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request fixes:
Stuff left to complete in this pull request:
track_editsto commandsA lot has changed in serenity since this bot was written, and I decided to go ahead and do a rewrite into poise to allow for more flexibility in commands.
poise allows for hybrid command support which we are using here to restore prefix commands.
Poise however does not allow for getting mutable references to custom data, so snippets now have to be in a synchronization primitive.
Previously commands were accessible in DMs, allowing for anybody to go into DMs and modify snippets regardless of permissions.
Because TabletBot is designed for one guild I haven't locked down the commands to permissions, but I have disabled the commands in DMs in this pull request to prevent this abuse from happening. Permissions will continue to be locked down in the OpenTabletDriver guild.