fwaas unit tests are failing on networking-midonet gate

Bug #1758062 reported by YAMAMOTO Takashi
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
networking-midonet
Fix Released
Critical
YAMAMOTO Takashi
neutron
Fix Released
Critical
YAMAMOTO Takashi

Bug Description

After the recent CI changes, fwaas unit tests are broken.

ft1.16: midonet.neutron.tests.unit.test_extension_fwaas.FirewallTestCaseML2.test_delete_error_in_midonet_does_not_delete_firewall_StringException: Traceback (most recent call last):
  File "/home/zuul/src/git.openstack.org/openstack/networking-midonet/.tox/py27/local/lib/python2.7/site-packages/neutron_fwaas/tests/unit/services/firewall/test_fwaas_plugin.py", line 317, in setUp
    super(TestFirewallPluginBase, self).setUp(fw_plugin=FW_PLUGIN_KLASS)
  File "/home/zuul/src/git.openstack.org/openstack/networking-midonet/.tox/py27/local/lib/python2.7/site-packages/neutron_fwaas/tests/unit/services/firewall/test_fwaas_plugin.py", line 93, in setUp
    plugin=plugin, service_plugins=service_plugins, ext_mgr=ext_mgr)
  File "midonet/neutron/tests/unit/test_midonet_plugin_ml2.py", line 112, in setUp
    self.setup_parent(service_plugins=service_plugins, ext_mgr=ext_mgr)
  File "midonet/neutron/tests/unit/test_midonet_plugin_ml2.py", line 108, in setup_parent
    MidonetPluginConf.setUp(self, parent_setup)
  File "midonet/neutron/tests/unit/test_midonet_plugin_ml2.py", line 81, in setUp
    parent_setup()
  File "/home/zuul/src/git.openstack.org/openstack/networking-midonet/.tox/py27/local/lib/python2.7/site-packages/neutron/tests/unit/db/test_db_base_plugin_v2.py", line 112, in setUp
    super(NeutronDbPluginV2TestCase, self).setUp()
  File "/home/zuul/src/git.openstack.org/openstack/networking-midonet/.tox/py27/local/lib/python2.7/site-packages/neutron/tests/unit/testlib_api.py", line 394, in setUp
    super(WebTestCase, self).setUp()
  File "/home/zuul/src/git.openstack.org/openstack/networking-midonet/.tox/py27/local/lib/python2.7/site-packages/neutron/tests/unit/testlib_api.py", line 289, in setUp
    super(BaseSqlTestCase, self).setUp()
  File "/home/zuul/src/git.openstack.org/openstack/networking-midonet/.tox/py27/local/lib/python2.7/site-packages/neutron/tests/base.py", line 329, in setUp
    self.setup_config()
  File "/home/zuul/src/git.openstack.org/openstack/networking-midonet/.tox/py27/local/lib/python2.7/site-packages/neutron_fwaas/tests/base.py", line 44, in setup_config
    self.config_parse(args=args)
  File "/home/zuul/src/git.openstack.org/openstack/networking-midonet/.tox/py27/local/lib/python2.7/site-packages/neutron/tests/base.py", line 305, in config_parse
    config.init(args=args)
  File "/home/zuul/src/git.openstack.org/openstack/networking-midonet/.tox/py27/local/lib/python2.7/site-packages/neutron/common/config.py", line 78, in init
    **kwargs)
  File "/home/zuul/src/git.openstack.org/openstack/networking-midonet/.tox/py27/local/lib/python2.7/site-packages/oslo_config/cfg.py", line 2498, in __call__
    else sys.argv[1:])
  File "/home/zuul/src/git.openstack.org/openstack/networking-midonet/.tox/py27/local/lib/python2.7/site-packages/oslo_config/cfg.py", line 3162, in _parse_cli_opts
    return self._parse_config_files()
  File "/home/zuul/src/git.openstack.org/openstack/networking-midonet/.tox/py27/local/lib/python2.7/site-packages/oslo_config/cfg.py", line 3198, in _parse_config_files
    self._oparser.parse_args(self._args, namespace)
  File "/home/zuul/src/git.openstack.org/openstack/networking-midonet/.tox/py27/local/lib/python2.7/site-packages/oslo_config/cfg.py", line 2326, in parse_args
    return super(_CachedArgumentParser, self).parse_args(args, namespace)
  File "/usr/lib/python2.7/argparse.py", line 1701, in parse_args
    args, argv = self.parse_known_args(args, namespace)
  File "/usr/lib/python2.7/argparse.py", line 1733, in parse_known_args
    namespace, args = self._parse_known_args(args, namespace)
  File "/usr/lib/python2.7/argparse.py", line 1939, in _parse_known_args
    start_index = consume_optional(start_index)
  File "/usr/lib/python2.7/argparse.py", line 1879, in consume_optional
    take_action(action, args, option_string)
  File "/usr/lib/python2.7/argparse.py", line 1807, in take_action
    action(self, namespace, argument_values, option_string)
  File "/home/zuul/src/git.openstack.org/openstack/networking-midonet/.tox/py27/local/lib/python2.7/site-packages/oslo_config/cfg.py", line 1741, in __call__
    raise ConfigDirNotFoundError(values)
oslo_config.cfg.ConfigDirNotFoundError: Failed to read config file directory: /home/zuul/src/git.openstack.org/openstack/networking-midonet/.tox/py27/local/lib/python2.7/site-packages/neutron_fwaas/tests/./../../etc/neutron/policy.d

Changed in networking-midonet:
importance: Undecided → Critical
tags: added: gate-failure
Revision history for this message
YAMAMOTO Takashi (yamamoto) wrote :

let me look

Changed in networking-midonet:
assignee: nobody → YAMAMOTO Takashi (yamamoto)
milestone: none → 7.0.0
status: New → In Progress
tags: added: fwaas
Changed in neutron:
assignee: nobody → YAMAMOTO Takashi (yamamoto)
importance: Undecided → Critical
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron-fwaas (master)

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

Revision history for this message
Elod Illes (elod-illes) wrote : Re: fwaas unit tests are failing

This bug occures in stable/ocata [1] and stable/pike's [2] networking-midonet job. I think the above patch would fix the issue in those jobs as well if they are backported.

[1] http://logs.openstack.org/periodic-stable/git.openstack.org/openstack/networking-midonet/stable/ocata/openstack-tox-py27/770163d/
[2] http://logs.openstack.org/periodic-stable/git.openstack.org/openstack/networking-midonet/stable/pike/openstack-tox-py27/ea29b2b/

tags: added: ocata-backport-potential pike-backport-potential queens-backport-potential
summary: - fwaas unit tests are failing
+ fwaas unit tests are failing on networking-midonet gate
description: updated
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron-fwaas (master)

Reviewed: https://review.openstack.org/555699
Committed: https://git.openstack.org/cgit/openstack/neutron-fwaas/commit/?id=e1231cd6eabb0992820d0c0fdc629c8a96b5f6b9
Submitter: Zuul
Branch: master

commit e1231cd6eabb0992820d0c0fdc629c8a96b5f6b9
Author: YAMAMOTO Takashi <email address hidden>
Date: Fri Mar 23 17:40:53 2018 +0900

    tests: don't rely on configuration files outside tests directory

    Following the similar Neutron change. [1]

    Recently, the way sibling projects are installed were changed.
    It broke networking-midonet gate as neutron-fwaas was installed
    under site-packages, where the etc directory is not available.

    [1] If1f5ebd981cf06558d5102524211799676068889

    Closes-Bug: #1758062
    Change-Id: I72aeeac8cbe07f6fc6cb4acf54fb632587d890a0

Changed in neutron:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron-fwaas (stable/pike)

Fix proposed to branch: stable/pike
Review: https://review.openstack.org/557005

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron-fwaas (stable/queens)

Fix proposed to branch: stable/queens
Review: https://review.openstack.org/557006

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron-fwaas (stable/queens)

Reviewed: https://review.openstack.org/557006
Committed: https://git.openstack.org/cgit/openstack/neutron-fwaas/commit/?id=384366b3894611306b2b25203a7d63aba79c4f02
Submitter: Zuul
Branch: stable/queens

commit 384366b3894611306b2b25203a7d63aba79c4f02
Author: YAMAMOTO Takashi <email address hidden>
Date: Fri Mar 23 17:40:53 2018 +0900

    tests: don't rely on configuration files outside tests directory

    Following the similar Neutron change. [1]

    Recently, the way sibling projects are installed were changed.
    It broke networking-midonet gate as neutron-fwaas was installed
    under site-packages, where the etc directory is not available.

    [1] If1f5ebd981cf06558d5102524211799676068889

    Closes-Bug: #1758062
    Change-Id: I72aeeac8cbe07f6fc6cb4acf54fb632587d890a0
    (cherry picked from commit e1231cd6eabb0992820d0c0fdc629c8a96b5f6b9)

tags: added: in-stable-queens
tags: added: in-stable-pike
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron-fwaas (stable/pike)

Reviewed: https://review.openstack.org/557005
Committed: https://git.openstack.org/cgit/openstack/neutron-fwaas/commit/?id=d02659fc5da30791eab93bb8dcc362a2b02c0499
Submitter: Zuul
Branch: stable/pike

commit d02659fc5da30791eab93bb8dcc362a2b02c0499
Author: YAMAMOTO Takashi <email address hidden>
Date: Fri Mar 23 17:40:53 2018 +0900

    tests: don't rely on configuration files outside tests directory

    Following the similar Neutron change. [1]

    Recently, the way sibling projects are installed were changed.
    It broke networking-midonet gate as neutron-fwaas was installed
    under site-packages, where the etc directory is not available.

    [1] If1f5ebd981cf06558d5102524211799676068889

    Closes-Bug: #1758062
    Change-Id: I72aeeac8cbe07f6fc6cb4acf54fb632587d890a0
    (cherry picked from commit e1231cd6eabb0992820d0c0fdc629c8a96b5f6b9)

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron-fwaas (stable/ocata)

Fix proposed to branch: stable/ocata
Review: https://review.openstack.org/559940

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/neutron-fwaas 13.0.0.0b1

This issue was fixed in the openstack/neutron-fwaas 13.0.0.0b1 development milestone.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron-fwaas (stable/ocata)

Reviewed: https://review.openstack.org/559940
Committed: https://git.openstack.org/cgit/openstack/neutron-fwaas/commit/?id=d28a547fb2f8ff914facb20c03c2878bc4c3a7f9
Submitter: Zuul
Branch: stable/ocata

commit d28a547fb2f8ff914facb20c03c2878bc4c3a7f9
Author: Bertrand Lallau <email address hidden>
Date: Wed Feb 22 16:03:32 2017 +0100

    Fix pep8, py27, pip install error and tempest

    This patch is a squash of four fix that are needed together to have a
    successful zuul run.

    1. pep8 fix (cherry-picked from master:
       87eb1b15be8a4e39f3344f829d1a5b295a37a858 )

    A recent change in pep/pycodingchecks introduced new warnings as part of
    the pep8 target that causes pep8 to fail now.

    This patch fixes code that issued warnings W503,E731,E266,E402

    In addition, old tests which were not ran anyway, and are no longer
    relevant (test_firewall) were deleted.

    Conflicts:
     neutron_fwaas/tests/tempest_plugin/tests/scenario/manager.py

    2. Avoid parameterless pip install

    build-openstack-sphinx-docs jobs fail on all stable branches due to the
    new pip version 10 introduces some previously Warning as Error: in case
    of calling "pip install" without any package name, the command fails.
    tox_install.sh is called during docs job without any package passed to
    pip.

    This patch also disables E402 hacking check because releasenotes/* violates it
    (the issue is not present in Queens+ where
    Ib19f7ea4ea136180f38bc78389f51b6b5d179ab8 is merged).

    Conflicts:
          neutron_fwaas/db/migration/alembic_migrations/versions/queens/expand/876782258a43_create_default_firewall_groups_table.py
          neutron_fwaas/db/migration/alembic_migrations/versions/queens/expand/f24e0d5e5bff_uniq_firewallgroupportassociation0port.py
          neutron_fwaas/services/firewall/fwaas_plugin_v2.py
          neutron_fwaas/db/migration/alembic_migrations/versions/pike/contract/fd38cd995cc0_shared_attribute_for_firewall_resources.py
          neutron_fwaas/tests/unit/extensions/test_firewall.py
          tox.ini

    3. tests: don't rely on configuration files outside tests directory

    Following the similar Neutron change. [1]

    Recently, the way sibling projects are installed were changed.
    It broke networking-midonet gate as neutron-fwaas was installed
    under site-packages, where the etc directory is not available.

    [1] If1f5ebd981cf06558d5102524211799676068889

    Closes-Bug: #1758062

    4. Adding cleanup of router in unit tests

    Resources must be cleanup after each test in order to free
    resources.

    This patch fixes the legacy-neutron-fwaas-v1-dsvm-tempest jobs

    Change-Id: I72aeeac8cbe07f6fc6cb4acf54fb632587d890a0
    (cherry picked from commit 58a62382e939b47d7bb75e985852aa214f9f3cdd)
    (cherry picked from commit 1d884eab72375af862d50045acc2aa7b62985207)
    (cherry picked from commit 200a03439e4393af83f5bca1e0e18f196b024e5d)
    (cherry picked from commit e1231cd6eabb0992820d0c0fdc629c8a96b5f6b9)
    (cherry picked from commit 4f8dc35a056e003fcc7ad8f65368bc8f60163e85)

tags: added: in-stable-ocata
Changed in networking-midonet:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/neutron-fwaas 11.0.2

This issue was fixed in the openstack/neutron-fwaas 11.0.2 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/neutron-fwaas 12.0.1

This issue was fixed in the openstack/neutron-fwaas 12.0.1 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/neutron-fwaas ocata-eol

This issue was fixed in the openstack/neutron-fwaas ocata-eol 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.