Implement warning by user ID. #6445
Labels
No labels
Automated PR
Blocked
Blocked By: Damage Control
Blocked By: Dependency
Blocked By: Other PR
Breaking Change
Category: CI
Category: Cogs - Admin
Category: Cogs - Alias
Category: Cogs - Audio
Category: Cogs - Bank
Category: Cogs - Cleanup
Category: Cogs - CustomCommands
Category: Cogs - Dev
Category: Cogs - Downloader
Category: Cogs - Economy
Category: Cogs - Filter
Category: Cogs - General
Category: Cogs - Image
Category: Cogs - Mod
Category: Cogs - Modlog
Category: Cogs - Mutes
Category: Cogs - Permissions
Category: Cogs - Reports
Category: Cogs - Streams
Category: Cogs - Trivia
Category: Cogs - Trivia - Lists
Category: Cogs - Warnings
Category: Core - API - App Commands Package
Category: Core - API - Audio
Category: Core - API - Bank
Category: Core - API - Commands Package
Category: Core - API - Config
Category: Core - API - Other
Category: Core - API - Utils Package
Category: Core - Bot Class
Category: Core - Bot Commands
Category: Core - Command-line Interfaces
Category: Core - Downloader
Category: Core - Help
Category: Core - i18n
Category: Core - Modlog
Category: Core - Other Internals
Category: Core - RPC/ZMQ
Category: Docker
Category: Docs - Changelogs
Category: Docs - For Developers
Category: Docs - Install Guides
Category: Docs - Other
Category: Docs - User Guides
Category: Meta
Category: RPC/ZMQ methods
Category: Vendored Packages
Changelog Entry: Added
Changelog Entry: Pending
Changelog Entry: Skipped
Closed: Duplicate
Closed: External
Closed: Invalid
Closed: User Error
Closed: Won't Fix
Complex Issue
Docs-only
Feature Branch
Good First Issue
Help Wanted
High Priority
Needs Backport To stable-docs
No Activity
No Repro
QA: Bypassed
QA: Changes Requested
QA: Passed
Release Blocker
Status: Accepted
Status: Frozen
Status: In Progress
Status: Needs Discussion
Status: Needs Info
Status: Needs Triage
Status: PRs Welcome
Type: Bug
Type: Dependency Update
Type: Deprecation
Type: Enhancement
Type: Feature
Type: Informational
Type: Merge
Type: Optimisation
Type: Question
Type: Removal
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
Mrcoolgamer11/Red-DiscordBot#6445
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What component of Red (cog, command, API) would you like to see improvements on?
warnings
Describe the enhancement you're suggesting.
It seems that this was once behavior for the cog a long while ago, but I would like to propose allowing warns by user ID. It would be useful to warn IDs of users who, say, violated a rule but left before any warning could be given.
Anything else?
I'm not sure how this would intersect with warn actions, I'm not sure how the cog would perform these on absent users. I would also be willing to try and take this enhancement on if that would be preferable. My current line of thought would be to replicate the member param validation from
[p]warningsand ignore DMing if the member isn't present.Hi, can I take this?
We don't assign non-members to issues. Feel free to work on it if you wish.
At least as far back as the start of V3,
warningshas always taken aMemberas the argument (ref). Perhaps you are thinking of[p]banor similar commands?As you pointed out, this seems a little hard to address given the nature of a warnings based cog.
warningsallows actions to run any arbitrary command on the user, and cannot guarantee that the command will succeed if given an ID of a user who has left the server. It would make sense to allow a[p]warnthat would give enough points to execute the[p]bancommand to be used on a user who has left the server, since a user who is at that tier should be banned regardless of if they try to rejoin the server, and the ban command is able to accept IDs of members not in the server. However, something like[p]timeoutwhich requires the user to be in the server would need to wait for them to rejoin (resulting in the timeout length not starting until after they rejoined, for better or for worse). There is no easy way forwarningsto tell the difference between these cases and handle them individually. The only option that could work is always waiting until the user rejoins, but that requires the bot to be online when the user joins for them to be punished.I am not certain if that added complexity is worth the effort for this edge case. If a disruptive user is leaving before a moderator is able to take action, it may often make sense to consider them a troll and bypass the server's standard
warningstrack.So yes, so in that case I can modify the [p]warn command to ban the user by their ID if they have already left the server. I also believe it is fair to assume they are a troll and should not be allowed back in the server.