Simplify Discord subscription require filter labels - #4
Merged
Conversation
Only render enabled requirement flags in status output, so false filters are omitted and the rule text is easier to scan. Made-with: Cursor
There was a problem hiding this comment.
Pull request overview
This PR simplifies how Discord subscription rules are rendered in status embeds by only showing enabled requirement filters (and omitting False/disabled requirement flags), reducing noise in the displayed rule strings.
Changes:
- Update rule string formatting to include only enabled
requireFresh/requireCompletedflags, while always showing the raid filter. - Adjust unit test expectations to match the new compact filter label output.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
src/commands/subscription_helpers.py |
Changes _standardized_rule_string() to omit disabled requirement filters and render enabled requirements as require:* labels. |
tests/test_subscription_helpers.py |
Updates assertions to expect require:fresh and to no longer expect output for disabled requireCompleted. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
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.
Summary
Test plan
PYTHONPATH=. python3 -m pytest tests/test_subscription_helpers.pylocally (blocked here by missingjwtdependency)Made with Cursor