oslo.log: test failures with Python 3.13.0b2

Bug #2069084 reported by Michał Górny
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
oslo.log
In Progress
Undecided
Unassigned

Bug Description

When running the test suite on Python 3.13.0b2, I'm getting the following test failures (note that I had to remove the test requiring eventlet, as greenlet doesn't build on py3.13):

```
oslo_log.tests.unit.test_log.ContextFormatterTestCase.test_rfc5424_isotime_format_no_microseconds
-------------------------------------------------------------------------------------------------

Captured traceback:
~~~~~~~~~~~~~~~~~~~
    Traceback (most recent call last):

      File "/usr/lib/python3.13/unittest/mock.py", line 1420, in patched
    return func(*newargs, **newkeywargs)

      File "/tmp/oslo.log/oslo_log/tests/unit/test_log.py", line 1003, in test_rfc5424_isotime_format_no_microseconds
    self.assertEqual(expected, self.stream.getvalue())
    ~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

      File "/tmp/oslo.log/.tox/py313/lib/python3.13/site-packages/testtools/testcase.py", line 419, in assertEqual
    self.assertThat(observed, matcher, message)
    ~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^

      File "/tmp/oslo.log/.tox/py313/lib/python3.13/site-packages/testtools/testcase.py", line 509, in assertThat
    raise mismatch_error

    testtools.matchers._impl.MismatchError: !=:
reference = '''\
2015-12-16T13:54:26.000000+00:00 test
'''
actual = '''\
2015-12-16T13:54:26+00:00 test
'''

oslo_log.tests.unit.test_log.MutateTestCase.test_remove_logger
--------------------------------------------------------------

Captured traceback:
~~~~~~~~~~~~~~~~~~~
    Traceback (most recent call last):

      File "/tmp/oslo.log/oslo_log/tests/unit/test_log.py", line 1593, in test_remove_logger
    log.warn("warn")
    ^^^^^^^^

    AttributeError: 'Logger' object has no attribute 'warn'
```

I'm going to try to submit a fix for these.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to oslo.log (master)

Fix proposed to branch: master
Review: https://review.opendev.org/c/openstack/oslo.log/+/921797

Changed in oslo.log:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Fix proposed to branch: master
Review: https://review.opendev.org/c/openstack/oslo.log/+/921798

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on oslo.log (master)

Change abandoned by "Michał Górny <email address hidden>" on branch: master
Review: https://review.opendev.org/c/openstack/oslo.log/+/921798
Reason: Incorrect solution.

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.