docutils 0.19 deprecated OptionParser

Bug #1981194 reported by Lajos Katona
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Rally
Fix Released
Critical
Unassigned

Bug Description

docutils 0.19 deprecated OptionParser and this causes that DockerReadmeTestCase.test_mentioned_latest_version and DocstringsTestCase.test_all_plugins_have_docstrings started to fail:
testtools.testresult.real._StringException: Traceback (most recent call last):
  File "/home/lajoskatona/github/rally-openstack/tests/unit/doc/test_docker_readme.py", line 66, in test_mentioned_latest_version
    releases = self.get_releases()
  File "/home/lajoskatona/github/rally-openstack/tests/unit/doc/test_docker_readme.py", line 40, in get_releases
    settings = frontend.OptionParser(
  File "/home/lajoskatona/github/rally-openstack/.tox/py38/lib/python3.8/site-packages/docutils/frontend.py", line 662, in __init__
    warnings.warn('The frontend.OptionParser class will be replaced '
DeprecationWarning: The frontend.OptionParser class will be replaced by a subclass of argparse.ArgumentParser in Docutils 0.21 or later.

As I understand the new argparse.ArgumentParser based solution will be implemented in docutils, so a quick workaround till it is ready to limit docutils to <0.19

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to rally-openstack (master)

Related fix proposed to branch: master
Review: https://review.opendev.org/c/openstack/rally-openstack/+/849281

Changed in rally:
status: New → In Progress
importance: Undecided → Critical
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to rally-openstack (master)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to rally-openstack (master)

Reviewed: https://review.opendev.org/c/openstack/rally-openstack/+/849464
Committed: https://opendev.org/openstack/rally-openstack/commit/c1d9cf911bb66225f8332a1ca3cdddf00a7e0996
Submitter: "Zuul (22348)"
Branch: master

commit c1d9cf911bb66225f8332a1ca3cdddf00a7e0996
Author: Andrey Kurilin <email address hidden>
Date: Tue Jul 12 11:27:48 2022 +0300

    Suppress 2 warnings from Docutils

    The following 2 warnings do not require any modification of our code, so
    we can silently hide them and wait for new release of docutils:

    - The frontend.OptionParser class will be replaced by a subclass of
      argparse.ArgumentParser in Docutils 0.21 or later.
    - The frontend.Option class will be removed in Docutils 0.21 or later.

    Also, this commit temporary disables all dsvm job. They require a fix
    for list-resources ansible role, but it would be nice to do that in a
    separate change.

    Change-Id: I82e794c3d12222db9380701e6923b6e065b596ac
    Closes-Bug: 1981194

Changed in rally:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on rally-openstack (master)

Change abandoned by "Andrey Kurilin <email address hidden>" on branch: master
Review: https://review.opendev.org/c/openstack/rally-openstack/+/849281
Reason: Thanks for raising this issue.

The proper fix is here - https://review.opendev.org/c/openstack/rally-openstack/+/849464

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/rally-openstack 2.3.0

This issue was fixed in the openstack/rally-openstack 2.3.0 release.

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.