Bug 2196782
| Summary: | python-redis: test failures with redis 7.2rc2 | ||
|---|---|---|---|
| Product: | [Fedora] Fedora | Reporter: | Tomáš Hrnčiar <thrnciar> |
| Component: | python-redis | Assignee: | Fedora Infrastructure SIG <infra-sig> |
| Status: | NEW --- | QA Contact: | Fedora Extras Quality Assurance <extras-qa> |
| Severity: | unspecified | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | 39 | CC: | admiller, i, infra-sig, kevin, mhroncok, nathans, rcollet |
| Target Milestone: | --- | ||
| Target Release: | --- | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| URL: | https://koschei.fedoraproject.org/package/python-redis | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | If docs needed, set a value | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | Type: | Bug | |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
|
Description
Tomáš Hrnčiar
2023-05-10 08:45:35 UTC
This is blocking the Python 3.12 rebuild of Django. I've tried updating the package, but no dice.
This seems to fail since redis update form 7.0 to 7.2rc2.
=================================== FAILURES ===================================
_________ TestRedisCommands.test_xinfo_consumers[single-python-parser] _________
self = <tests.test_asyncio.test_commands.TestRedisCommands object at 0x7fff8bd042d0>
r = Redis<ConnectionPool<Connection<host=localhost,port=6379,db=9>>>
@skip_if_server_version_lt("5.0.0")
async def test_xinfo_consumers(self, r: redis.Redis):
stream = "stream"
group = "group"
consumer1 = "consumer1"
consumer2 = "consumer2"
await r.xadd(stream, {"foo": "bar"})
await r.xadd(stream, {"foo": "bar"})
await r.xadd(stream, {"foo": "bar"})
await r.xgroup_create(stream, group, 0)
await r.xreadgroup(group, consumer1, streams={stream: ">"}, count=1)
await r.xreadgroup(group, consumer2, streams={stream: ">"})
info = await r.xinfo_consumers(stream, group)
assert len(info) == 2
expected = [
{"name": consumer1.encode(), "pending": 1},
{"name": consumer2.encode(), "pending": 2},
]
# we can't determine the idle time, so just make sure it's an int
assert isinstance(info[0].pop("idle"), int)
assert isinstance(info[1].pop("idle"), int)
> assert info == expected
E AssertionError: assert [{'inactive':...'pending': 2}] == [{'name': b'c...'pending': 2}]
E At index 0 diff: {'name': b'consumer1', 'pending': 1, 'inactive': 1} != {'name': b'consumer1', 'pending': 1}
E Use -v to get more diff
tests/test_asyncio/test_commands.py:2661: AssertionError
__________ TestRedisCommands.test_xinfo_consumers[pool-python-parser] __________
self = <tests.test_asyncio.test_commands.TestRedisCommands object at 0x7fff8bd04050>
r = Redis<ConnectionPool<Connection<host=localhost,port=6379,db=9>>>
@skip_if_server_version_lt("5.0.0")
async def test_xinfo_consumers(self, r: redis.Redis):
stream = "stream"
group = "group"
consumer1 = "consumer1"
consumer2 = "consumer2"
await r.xadd(stream, {"foo": "bar"})
await r.xadd(stream, {"foo": "bar"})
await r.xadd(stream, {"foo": "bar"})
await r.xgroup_create(stream, group, 0)
await r.xreadgroup(group, consumer1, streams={stream: ">"}, count=1)
await r.xreadgroup(group, consumer2, streams={stream: ">"})
info = await r.xinfo_consumers(stream, group)
assert len(info) == 2
expected = [
{"name": consumer1.encode(), "pending": 1},
{"name": consumer2.encode(), "pending": 2},
]
# we can't determine the idle time, so just make sure it's an int
assert isinstance(info[0].pop("idle"), int)
assert isinstance(info[1].pop("idle"), int)
> assert info == expected
E AssertionError: assert [{'inactive':...'pending': 2}] == [{'name': b'c...'pending': 2}]
E At index 0 diff: {'name': b'consumer1', 'pending': 1, 'inactive': 0} != {'name': b'consumer1', 'pending': 1}
E Use -v to get more diff
tests/test_asyncio/test_commands.py:2661: AssertionError
I've deselected the failing tests to unblock the Python 3.12 rebuild. Upstream report: https://github.com/redis/redis-py/issues/2825 This bug appears to have been reported against 'rawhide' during the Fedora Linux 39 development cycle. Changing version to 39. |