cross-swift-py27 and cross-swift-py36 are failing 3 unit tests

Bug #1968562 reported by Jiri Podivin
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Object Storage (swift)
Fix Released
Undecided
Tim Burke
tripleo
Fix Released
Critical
Unassigned

Bug Description

The jobs cross-swift-py27 and cross-swift-py36 are failing on the stable/train branch of the openstack requirements project, effectively blocking merging of patches.

In both cases, the unit tests appear to fail due encoding change of the tested string, breaking the test assertion.

Trace:
------
#2564 test_obj_odd_chars (test.unit.common.middleware.test_tempurl.TestTempURL) ... FAIL
#3375 test_401_www_authenticate_is_quoted (test.unit.common.test_swob.TestRequest) ... FAIL
#3400 Copied from swift.common.utils.split_path ... FAIL

======================================================================
FAIL: test_obj_odd_chars (test.unit.common.middleware.test_tempurl.TestTempURL)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/zuul/src/opendev.org/openstack/swift/test/unit/common/middleware/test_tempurl.py", line 358, in test_obj_odd_chars
    self.assertEqual(resp.status_int, 200)
AssertionError: 401 != 200
    '401 != 200' = '%s != %s' % _common_shorten_repr(401, 200)
    '401 != 200' = self._formatMessage('401 != 200', '401 != 200')
>> raise self.failureException('401 != 200')

======================================================================
FAIL: test_401_www_authenticate_is_quoted (test.unit.common.test_swob.TestRequest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/zuul/src/opendev.org/openstack/swift/test/unit/common/test_swob.py", line 764, in test_401_www_authenticate_is_quoted
    resp.headers['Www-Authenticate'])
AssertionError: 'Swift realm="account-name%0A%0A%3Cb%3Efoo%3Cbr%3E"' != 'Swift realm="account-name%3Cb%3Efoo%3Cbr%3E"'
- Swift realm="account-name%0A%0A%3Cb%3Efoo%3Cbr%3E"
? ------
+ Swift realm="account-name%3Cb%3Efoo%3Cbr%3E"

    """Fail immediately, with the given message."""
>> raise self.failureException('\'Swift realm="account-name%0A%0A%3Cb%3Efoo%3Cbr%3E"\' != \'Swift realm="account-name%3Cb%3Efoo%3Cbr%3E"\'\n- Swift realm="account-name%0A%0A%3Cb%3Efoo%3Cbr%3E"\n? ------\n+ Swift realm="account-name%3Cb%3Efoo%3Cbr%3E"\n')

======================================================================
FAIL: Copied from swift.common.utils.split_path
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/zuul/src/opendev.org/openstack/swift/test/unit/common/test_swob.py", line 930, in test_split_path
    self.assertEqual(str(err), 'Invalid path: o%0An%20e')
AssertionError: 'Invalid path: on%20e' != 'Invalid path: o%0An%20e'
- Invalid path: on%20e
+ Invalid path: o%0An%20e
? +++

    """Fail immediately, with the given message."""
>> raise self.failureException("'Invalid path: on%20e' != 'Invalid path: o%0An%20e'\n- Invalid path: on%20e\n+ Invalid path: o%0An%20e\n? +++\n")

Logs:
-----
https://zuul.opendev.org/t/openstack/build/5fbf1ff2d0684788a46211c5614ac2b4
https://zuul.opendev.org/t/openstack/build/adf1939ef044430b9c131a60fd84a5ea

Revision history for this message
Tim Burke (1-tim-z) wrote :

Should get fixed for train by https://review.opendev.org/c/openstack/swift/+/838589. Starting 3/31, Ubuntu released fixes for https://bugs.python.org/issue43882 across many python versions; many of Swift's stable branches have been busted since then.

Changed in swift:
status: New → In Progress
assignee: nobody → Tim Burke (1-tim-z)
Revision history for this message
Tim Burke (1-tim-z) wrote :
Revision history for this message
Jiri Podivin (jpodivin) wrote :

All of the patches mentioned by Tim Burke were merged as of April 21.
I can confirm that both of the jobs are now functioning in the stable/train branch.

Revision history for this message
Jiri Podivin (jpodivin) wrote :

Marking as Fix released.

Changed in tripleo:
status: Triaged → Fix Released
Tim Burke (1-tim-z)
Changed in swift:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.