Skip to content

Fix check-failure error messages never being shown - #856

Merged
MattyTheHacker merged 1 commit into
mainfrom
fix-command-check-failure-messages
Nov 21, 2026
Merged

MattyTheHacker merged 1 commit into
mainfrom
fix-command-check-failure-messages

Conversation

@MattyTheHacker

@MattyTheHacker MattyTheHacker commented Nov 20, 2026 •

Copy link
Copy Markdown
Member

The CommandChecks currently aren't working because is_interaction_user_in_main_guild_failure() and is_interaction_user_has_committee_role_failure() identify the failed check by comparing check.__name__ with the decorator's name. The check that pycord puts in CheckAnyFailure.checks is the inner _check function, so the names never match and both functions always return False.

Rename each inner _check function to its decorator's name, so the existing name comparison matches. The error handler and the is_…_failure() functions are unchanged.

@MattyTheHacker
MattyTheHacker requested a review from a team November 20, 2026 20:53
@codecov

codecov Bot commented Nov 20, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 4 lines in your changes missing coverage. Please review.
✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
utils/command_checks.py 0.00% 4 Missing ⚠️

📢 Thoughts on this report? Let us know!

@MattyTheHacker
MattyTheHacker enabled auto-merge (squash) November 20, 2026 20:59
@MattyTheHacker
MattyTheHacker marked this pull request as draft November 20, 2026 21:06
auto-merge was automatically disabled November 20, 2026 21:06

Pull request was converted to draft

@MattyTheHacker
MattyTheHacker marked this pull request as ready for review November 20, 2026 21:13
@CarrotManMatt

Copy link
Copy Markdown
Member

Awesome stuff. Cheers for noticing!

@MattyTheHacker
MattyTheHacker merged commit 227830b into main Nov 21, 2026
15 checks passed
@MattyTheHacker
MattyTheHacker deleted the fix-command-check-failure-messages branch November 21, 2026 14:05

This branch was successfully deployed

1 active deployment
publish — 533f448e Deployed Nov 20, 2026 by MattyTheHacker via Build and publish Docker image #5006
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants