Reviewed: https://review.openstack.org/396258 Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=e727b92d3d643384cc2e34d26266cd1e2f3334fe Submitter: Jenkins Branch: master
commit e727b92d3d643384cc2e34d26266cd1e2f3334fe Author: Ihar Hrachyshka <[email protected]> Date: Tue Nov 8 19:54:04 2016 +0000 Register osprofiler options before setting engine hook The patch makes the module to not assume the options are registered by some other code, that may never be executed, f.e. when it's part of a single test case execution. Change-Id: I7eefb32e6f34d732bda681919b434a96b8ad36da Closes-Bug: #1640782 ** Changed in: neutron Status: In Progress => Fix Released -- You received this bug notification because you are a member of Yahoo! Engineering Team, which is subscribed to neutron. https://bugs.launchpad.net/bugs/1640782 Title: oslo_config.cfg.NoSuchOptError: no such option profiler in group [DEFAULT] when running an isolated unit test Status in neutron: Fix Released Bug description: (py27) -bash-4.2$ python -m testtools.run neutron.tests.unit.objects.test_trunk.TrunkObjectTestCase.test_delete_objects Tests running... Policies ['update_rbac_policy:target_tenant'] are part of a cyclical reference. ====================================================================== ERROR: neutron.tests.unit.objects.test_trunk.TrunkObjectTestCase.test_delete_objects ---------------------------------------------------------------------- Traceback (most recent call last): File "neutron/tests/unit/objects/test_base.py", line 544, in setUp mock.patch.object(self.context.session, 'refresh').start() File "neutron/context.py", line 134, in session self._session = db_api.get_session() File "neutron/db/api.py", line 201, in get_session return context_manager.get_legacy_facade().get_session( File "/home/vagrant/git/neutron/.tox/py27/lib/python2.7/site-packages/oslo_db/sqlalchemy/enginefacade.py", line 667, in get_legacy_facade return self._factory.get_legacy_facade() File "/home/vagrant/git/neutron/.tox/py27/lib/python2.7/site-packages/oslo_db/sqlalchemy/enginefacade.py", line 261, in get_legacy_facade self._start() File "/home/vagrant/git/neutron/.tox/py27/lib/python2.7/site-packages/oslo_db/sqlalchemy/enginefacade.py", line 363, in _start engine_args, maker_args) File "/home/vagrant/git/neutron/.tox/py27/lib/python2.7/site-packages/oslo_db/sqlalchemy/enginefacade.py", line 389, in _setup_for_connection hook(engine) File "neutron/db/api.py", line 38, in set_hook if cfg.CONF.profiler.enabled and cfg.CONF.profiler.trace_sqlalchemy: File "/home/vagrant/git/neutron/.tox/py27/lib/python2.7/site-packages/oslo_config/cfg.py", line 2316, in __getattr__ raise NoSuchOptError(name) oslo_config.cfg.NoSuchOptError: no such option profiler in group [DEFAULT] Ran 1 test in 0.256s FAILED (failures=1) Apparently, the option is not registered. To manage notifications about this bug go to: https://bugs.launchpad.net/neutron/+bug/1640782/+subscriptions -- Mailing list: https://launchpad.net/~yahoo-eng-team Post to : [email protected] Unsubscribe : https://launchpad.net/~yahoo-eng-team More help : https://help.launchpad.net/ListHelp

