test_ingress_bw_limit_dpdk_port functional test fails with python3

Bug #1771409 reported by Jakub Libosvar
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
neutron
Fix Released
Undecided
Jakub Libosvar

Bug Description

  File "/opt/stack/new/neutron/neutron/tests/base.py", line 140, in func
    return f(self, *args, **kwargs)
  File "/opt/stack/new/neutron/neutron/tests/functional/agent/test_ovs_lib.py", line 430, in test_ingress_bw_limit_dpdk_port
    port_name)
  File "/opt/stack/new/neutron/neutron/agent/common/ovs_lib.py", line 865, in get_ingress_bw_limit_for_dpdk_port
    common_utils.bytes_to_bits(int(max_bw_in_bytes)),
ValueError: invalid literal for int() with base 10: '87500.0'

Tags: py34
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron (master)

Fix proposed to branch: master
Review: https://review.openstack.org/568674

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

Reviewed: https://review.openstack.org/568674
Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=f3f2436d6db724126e5611d632b7d1efe309a2af
Submitter: Zuul
Branch: master

commit f3f2436d6db724126e5611d632b7d1efe309a2af
Author: Jakub Libosvar <email address hidden>
Date: Tue May 15 19:00:03 2018 +0000

    py3: Fix ingress_bw_limit_for_dpdk_port() value conversion

    Python 3 is not able to type int from string but max_bw_in_bytes is a
    string in float format. This patch types first to float and then to int,
    hence no ValueError is raised.

    Change-Id: I7a527a58f79c1451d8593330d433f620cb0a4107
    Closes-bug: #1771409

Changed in neutron:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/neutron 13.0.0.0b2

This issue was fixed in the openstack/neutron 13.0.0.0b2 development milestone.

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.