Actions
Bug #9547
closedpython rados aio_read truncates returned buffer on \000
% Done:
100%
Source:
Community (dev)
Tags:
Backport:
firefly
Regression:
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):
Description
diff --git a/src/test/pybind/test_rados.py b/src/test/pybind/test_rados.py index fcbe421..c41ddef 100644 --- a/src/test/pybind/test_rados.py +++ b/src/test/pybind/test_rados.py @@ -288,12 +288,12 @@ class TestIoctx(object): with lock: retval[0] = buf lock.notify() - self.ioctx.write("foo", "bar") + self.ioctx.write("foo", "bar\000frob") self.ioctx.aio_read("foo", 7, 0, cb) with lock: while retval[0] is None: lock.wait() - eq(retval[0], "bar") + eq(retval[0], "bar\000frob") [i.remove() for i in self.ioctx.list_objects()] class TestObject(object): $ PYTHONPATH=pybind nosetests -v test/pybind/test_rados.py:TestIoctx.test_aio_read test_rados.TestIoctx.test_aio_read ... FAIL ====================================================================== FAIL: test_rados.TestIoctx.test_aio_read ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/lib/python2.7/dist-packages/nose/case.py", line 197, in runTest self.test(*self.arg) File "/home/loic/software/ceph/ceph/src/test/pybind/test_rados.py", line 296, in test_aio_read eq(retval[0], "bar\000frob") AssertionError: 'bar' != 'bar\x00frob' ---------------------------------------------------------------------- Ran 1 test in 3.080s FAILED (failures=1)
Updated by Loïc Dachary over 9 years ago
- Source changed from other to Community (dev)
Updated by Loïc Dachary over 9 years ago
Proposed fix https://github.com/ceph/ceph/pull/2544
Updated by Loïc Dachary over 9 years ago
- Backport set to firefly
Updated by Loïc Dachary over 9 years ago
running wip-9547-python-rados-truncate from https://github.com/ceph/ceph/pull/2545 on http://ceph.com/gitbuilder.cgi
Updated by Loïc Dachary over 9 years ago
- Status changed from 12 to Fix Under Review
Updated by Loïc Dachary over 9 years ago
- Status changed from Fix Under Review to Pending Backport
Updated by Loïc Dachary over 9 years ago
The example from the description was not right but fixing it to have the expected length does not change the result of the failed test. The test in the commit does not have this problem.
Updated by Loïc Dachary over 9 years ago
firefly backport https://github.com/ceph/ceph/pull/2548
Updated by Loïc Dachary over 9 years ago
- Status changed from Pending Backport to Resolved
- % Done changed from 90 to 100
Actions