-
Notifications
You must be signed in to change notification settings - Fork 6k
Implement game_pattern support in CQH #4353
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement game_pattern support in CQH #4353
Conversation
Bibo-Joshi
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi, thanks for the PR! I left some comments below.
…elegram-bot into jainamoswal-patch-1
Bibo-Joshi
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks for the new updates. the logic now lgtm - except for one comment below. please let me know when you've implemented the tests so that I can give another review :)
|
I have added tests here. As a newbie can't confirm if they are accurate or need some changes. |
Bibo-Joshi
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM now :) thanks for the nice contribution and your cooperation in the review process!
Added the
game_patternparameter to CQH to enablecallback_data-like support for filtering based ongame_short_name.It supports
CQH(pattern=None, game_patterm=None)handles any CQ → backward compatibleCQH(pattern=pattern, game_patterm=None)handles only CQs with.data→ backward compatibleCQH(pattern=None, game_patterm=pattern)handles only CQs with.game_short_name. → still backward compatible sincegame_patterndefaults to NoneCQH(pattern=pattern, game_patterm=game_pattern)handles only CQs with matching.dataxor matching.game_short_name→ also backward compatible since.dataand.game_short_nameare mutually exclusiveThis PR closes #4269.