-
Notifications
You must be signed in to change notification settings - Fork 29
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
Python: add ZINTERCARD command #1418
Python: add ZINTERCARD command #1418
Conversation
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.
good job :)
@pytest.mark.parametrize("protocol", [ProtocolVersion.RESP2, ProtocolVersion.RESP3]) | ||
async def test_zintercard(self, redis_client: TRedisClient): | ||
min_version = "7.0.0" | ||
if await check_if_server_version_lt(redis_client, min_version): |
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.
same, I think a function for that would be good
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.
I'm not sure I understand, can you clarify? Are you suggesting a skip_if_server_version_lt
function that encapsulates lines 2528 to 2530?
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.
I'd like to see a function which run on the very beginning and sets a global value with the version.
Furthermore, in java, C# and go clients we check binary version, not what server returns.
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.
@shohamazon I suggest we merge this PR for now, you can answer my questions above and then we can go ahead and make the changes in all places that use these lines if we decide to go ahead
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.
@aaron-congo yes, skip_if_server_version_lt
sounds good and could be vey useful
8cd83f8
to
4f65653
Compare
4f65653
to
0fbe5b0
Compare
501f6bc
to
e5f0da2
Compare
Issue #, if available:
N/A
Description of changes:
https://redis.io/docs/latest/commands/zintercard/
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.