Comment 10 for bug 1915400

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (master)

Reviewed: https://review.opendev.org/c/openstack/nova/+/830383
Committed: https://opendev.org/openstack/nova/commit/b2d28f890872747d099a262e4a208e146b882f3f
Submitter: "Zuul (22348)"
Branch: master

commit b2d28f890872747d099a262e4a208e146b882f3f
Author: Balazs Gibizer <email address hidden>
Date: Tue Feb 22 12:24:37 2022 +0100

    Fix eventlet.tpool import

    Currently nova.utils.tpool_execute() only works by chance. And as the
    bug report shows there are env where it fails.

    The nova.utils.tpool_execute() call tries to uses eventlet.tpool.execute
    but the tpool module is not imported by the utils module only eventlet.
    In devstack it works by chance as the wsgi init actually imports
    eventlet.tpool indirectly via:

    Traceback (most recent call last):
      File "<stdin>", line 1, in <module>
      File "/opt/stack/nova/nova/api/openstack/compute/__init__.py", line 21, in <module>
        from nova.api.openstack.compute.routes import APIRouterV21 # noqa
      File "/opt/stack/nova/nova/api/openstack/compute/routes.py", line 20, in <module>
        from nova.api.openstack.compute import admin_actions
      File "/opt/stack/nova/nova/api/openstack/compute/admin_actions.py", line 17, in <module>
        from nova.api.openstack import common
      File "/opt/stack/nova/nova/api/openstack/common.py", line 27, in <module>
        from nova.compute import task_states
      File "/opt/stack/nova/nova/compute/task_states.py", line 26, in <module>
        from nova.objects import fields
      File "/opt/stack/nova/nova/objects/fields.py", line 24, in <module>
        from nova.network import model as network_model
      File "/opt/stack/nova/nova/network/model.py", line 23, in <module>
        from nova import utils
      File "/opt/stack/nova/nova/utils.py", line 39, in <module>
        from oslo_concurrency import processutils
      File "/usr/local/lib/python3.8/dist-packages/oslo_concurrency/processutils.py", line 57, in <module>
        from eventlet import tpool

    This was broken since I8dbc579e0037969aab4f2bb500fccfbde4190726. This
    patch adds the correct import statement.

    Change-Id: Ic46345ceeb445164aea6ae9b35c457c6150765f6
    Closes-Bug: #1915400