test_get_interface_bridged_time fails at self.assertGreater(t2, t1)

Bug #1614380 reported by IWAMOTO Toshihiro
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
neutron
Fix Released
High
Brian Haley

Bug Description

Traceback (most recent call last):
  File "neutron/tests/functional/agent/linux/test_bridge_lib.py", line 53, in test_get_interface_bridged_time
    self.assertGreater(t2, t1)
  File "/opt/stack/new/neutron/.tox/dsvm-functional/local/lib/python2.7/site-packages/unittest2/case.py", line 1233, in assertGreater
    self.fail(self._formatMessage(msg, standardMsg))
  File "/opt/stack/new/neutron/.tox/dsvm-functional/local/lib/python2.7/site-packages/unittest2/case.py", line 690, in fail
    raise self.failureException(msg)
AssertionError: 1471426063.9028516 not greater than 1471426063.9028516

http://logstash.openstack.org/#dashboard/file/logstash.json?query=build_name%3A%5C%22gate-neutron-dsvm-functional%5C%22%20AND%20build_status%3A%5C%22FAILURE%5C%22%20AND%20message%3A%5C%22assertGreater%5C%22

It seems sysfs mtime has only 4ms granularity. (Use attached shell script to confirm.)

sleep(.1) between get_interface_bridged_time would band-aid this bug.

Revision history for this message
IWAMOTO Toshihiro (iwamoto) wrote :
Revision history for this message
IWAMOTO Toshihiro (iwamoto) wrote :
tags: added: gate-failure
Changed in neutron:
status: New → Confirmed
importance: Undecided → High
Revision history for this message
Brian Haley (brian-haley) wrote :

Could always just use assertGreaterEqual()

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/357279

Changed in neutron:
assignee: nobody → Brian Haley (brian-haley)
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (master)

Reviewed: https://review.openstack.org/357279
Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=51ea9b10c73a5990e8e28b78e192e71d46142c71
Submitter: Jenkins
Branch: master

commit 51ea9b10c73a5990e8e28b78e192e71d46142c71
Author: Brian Haley <email address hidden>
Date: Thu Aug 18 11:08:14 2016 -0400

    Fix bridge assertion error when times are equal

    Sysfs mtime has only a 4ms granularity, so sometimes t2 will
    be equal to t1. Change to use assertGreaterEqual() instead.

    Change-Id: Id9a97dc3d5facbf66cd5c774a52f6a1b83712f33
    Closes-bug: #1614380

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

This issue was fixed in the openstack/neutron 9.0.0.0b3 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.