← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1750994] [NEW] lbaas: TestHaproxyCfg.test_transform_listener fails in Python 3.6

 

Public bug reported:

While building the neutron-lbaas package in Debian Sid with Python 3.6,
I get the below failure. As this looks like a broken test rather than a
software bug, I've disabled running the unit test at package build time,
however, it'd be nice to have it fixed.

FAIL: neutron_lbaas.tests.unit.drivers.haproxy.test_jinja_cfg.TestHaproxyCfg.test_transform_listener
neutron_lbaas.tests.unit.drivers.haproxy.test_jinja_cfg.TestHaproxyCfg.test_transform_listener
----------------------------------------------------------------------
_StringException: Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/neutron/tests/base.py", line 132, in func
    return f(self, *args, **kwargs)
  File "/home/zigo/sources/openstack/queens/services/neutron-lbaas/build-area/neutron-lbaas-12.0.0~rc1/neutron_lbaas/tests/unit/drivers/haproxy/test_jinja_cfg.py", line 443, in test_transform_listener
    self.assertEqual(sample_configs.RET_LISTENER, ret)
  File "/usr/lib/python3/dist-packages/testtools/testcase.py", line 411, in assertEqual
    self.assertThat(observed, matcher, message)
  File "/usr/lib/python3/dist-packages/testtools/testcase.py", line 498, in assertThat
    raise mismatch_error
testtools.matchers._impl.MismatchError: !=:
reference = {'connection_limit': 98,
 'default_pool': {'admin_state_up': True,
                  'health_monitor': {'admin_state_up': True,
                                     'delay': 30,
                                     'expected_codes': '500|405|404',
                                     'http_method': 'GET',
                                     'id': 'sample_monitor_id_1',
                                     'max_retries': 3,
                                     'timeout': 31,
                                     'type': 'HTTP',
                                     'url_path': '/index.html'},
                  'id': 'sample_pool_id_1',
                  'lb_algorithm': 'roundrobin',
                  'members': [{'address': '10.0.0.99',
                               'admin_state_up': True,
                               'id': 'sample_member_id_1',
                               'protocol_port': 82,
                               'provisioning_status': 'ACTIVE',
                               'subnet_id': '10.0.0.1/24',
                               'weight': 13},
                              {'address': '10.0.0.98',
                               'admin_state_up': True,
                               'id': 'sample_member_id_2',
                               'protocol_port': 82,
                               'provisioning_status': 'ACTIVE',
                               'subnet_id': '10.0.0.1/24',
                               'weight': 13}],
                  'protocol': 'http',
                  'provisioning_status': 'ACTIVE',
                  'session_persistence': {'cookie_name': 'HTTP_COOKIE',
                                          'type': 'HTTP_COOKIE'}},
 'id': 'sample_listener_id_1',
 'protocol': 'HTTP',
 'protocol_mode': 'http',
 'protocol_port': '80'}
actual    = {'connection_limit': 98,
 'default_pool': {'admin_state_up': True,
                  'health_monitor': {'admin_state_up': True,
                                     'delay': 30,
                                     'expected_codes': '500|404|405',
                                     'http_method': 'GET',
                                     'id': 'sample_monitor_id_1',
                                     'max_retries': 3,
                                     'timeout': 31,
                                     'type': 'HTTP',
                                     'url_path': '/index.html'},
                  'id': 'sample_pool_id_1',
                  'lb_algorithm': 'roundrobin',
                  'members': [{'address': '10.0.0.99',
                               'admin_state_up': True,
                               'id': 'sample_member_id_1',
                               'protocol_port': 82,
                               'provisioning_status': 'ACTIVE',
                               'subnet_id': '10.0.0.1/24',
                               'weight': 13},
                              {'address': '10.0.0.98',
                               'admin_state_up': True,
                               'id': 'sample_member_id_2',
                               'protocol_port': 82,
                               'provisioning_status': 'ACTIVE',
                               'subnet_id': '10.0.0.1/24',
                               'weight': 13}],
                  'protocol': 'http',
                  'provisioning_status': 'ACTIVE',
                  'session_persistence': {'cookie_name': 'HTTP_COOKIE',
                                          'type': 'HTTP_COOKIE'}},
 'id': 'sample_listener_id_1',
 'protocol': 'HTTP',
 'protocol_mode': 'http',
 'protocol_port': '80'}

** Affects: neutron
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to neutron.
https://bugs.launchpad.net/bugs/1750994

Title:
  lbaas: TestHaproxyCfg.test_transform_listener fails in Python 3.6

Status in neutron:
  New

Bug description:
  While building the neutron-lbaas package in Debian Sid with Python
  3.6, I get the below failure. As this looks like a broken test rather
  than a software bug, I've disabled running the unit test at package
  build time, however, it'd be nice to have it fixed.

  FAIL: neutron_lbaas.tests.unit.drivers.haproxy.test_jinja_cfg.TestHaproxyCfg.test_transform_listener
  neutron_lbaas.tests.unit.drivers.haproxy.test_jinja_cfg.TestHaproxyCfg.test_transform_listener
  ----------------------------------------------------------------------
  _StringException: Traceback (most recent call last):
    File "/usr/lib/python3/dist-packages/neutron/tests/base.py", line 132, in func
      return f(self, *args, **kwargs)
    File "/home/zigo/sources/openstack/queens/services/neutron-lbaas/build-area/neutron-lbaas-12.0.0~rc1/neutron_lbaas/tests/unit/drivers/haproxy/test_jinja_cfg.py", line 443, in test_transform_listener
      self.assertEqual(sample_configs.RET_LISTENER, ret)
    File "/usr/lib/python3/dist-packages/testtools/testcase.py", line 411, in assertEqual
      self.assertThat(observed, matcher, message)
    File "/usr/lib/python3/dist-packages/testtools/testcase.py", line 498, in assertThat
      raise mismatch_error
  testtools.matchers._impl.MismatchError: !=:
  reference = {'connection_limit': 98,
   'default_pool': {'admin_state_up': True,
                    'health_monitor': {'admin_state_up': True,
                                       'delay': 30,
                                       'expected_codes': '500|405|404',
                                       'http_method': 'GET',
                                       'id': 'sample_monitor_id_1',
                                       'max_retries': 3,
                                       'timeout': 31,
                                       'type': 'HTTP',
                                       'url_path': '/index.html'},
                    'id': 'sample_pool_id_1',
                    'lb_algorithm': 'roundrobin',
                    'members': [{'address': '10.0.0.99',
                                 'admin_state_up': True,
                                 'id': 'sample_member_id_1',
                                 'protocol_port': 82,
                                 'provisioning_status': 'ACTIVE',
                                 'subnet_id': '10.0.0.1/24',
                                 'weight': 13},
                                {'address': '10.0.0.98',
                                 'admin_state_up': True,
                                 'id': 'sample_member_id_2',
                                 'protocol_port': 82,
                                 'provisioning_status': 'ACTIVE',
                                 'subnet_id': '10.0.0.1/24',
                                 'weight': 13}],
                    'protocol': 'http',
                    'provisioning_status': 'ACTIVE',
                    'session_persistence': {'cookie_name': 'HTTP_COOKIE',
                                            'type': 'HTTP_COOKIE'}},
   'id': 'sample_listener_id_1',
   'protocol': 'HTTP',
   'protocol_mode': 'http',
   'protocol_port': '80'}
  actual    = {'connection_limit': 98,
   'default_pool': {'admin_state_up': True,
                    'health_monitor': {'admin_state_up': True,
                                       'delay': 30,
                                       'expected_codes': '500|404|405',
                                       'http_method': 'GET',
                                       'id': 'sample_monitor_id_1',
                                       'max_retries': 3,
                                       'timeout': 31,
                                       'type': 'HTTP',
                                       'url_path': '/index.html'},
                    'id': 'sample_pool_id_1',
                    'lb_algorithm': 'roundrobin',
                    'members': [{'address': '10.0.0.99',
                                 'admin_state_up': True,
                                 'id': 'sample_member_id_1',
                                 'protocol_port': 82,
                                 'provisioning_status': 'ACTIVE',
                                 'subnet_id': '10.0.0.1/24',
                                 'weight': 13},
                                {'address': '10.0.0.98',
                                 'admin_state_up': True,
                                 'id': 'sample_member_id_2',
                                 'protocol_port': 82,
                                 'provisioning_status': 'ACTIVE',
                                 'subnet_id': '10.0.0.1/24',
                                 'weight': 13}],
                    'protocol': 'http',
                    'provisioning_status': 'ACTIVE',
                    'session_persistence': {'cookie_name': 'HTTP_COOKIE',
                                            'type': 'HTTP_COOKIE'}},
   'id': 'sample_listener_id_1',
   'protocol': 'HTTP',
   'protocol_mode': 'http',
   'protocol_port': '80'}

To manage notifications about this bug go to:
https://bugs.launchpad.net/neutron/+bug/1750994/+subscriptions


Follow ups