Some tests fail sometimes, because of plugin loading exception

Bug #1617240 reported by David TARDIVEL
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
watcher
Fix Released
High
David TARDIVEL

Bug Description

watcher.tests.decision_engine.loading.test_default_planner_loader.TestDefaultPlannerLoader.test_endpoints
---------------------------------------------------------------------------------------------------------

Captured traceback:
~~~~~~~~~~~~~~~~~~~
    Traceback (most recent call last):
      File "watcher/tests/decision_engine/loading/test_default_planner_loader.py", line 29, in test_endpoints
        loaded = self.loader.load(endpoint)
      File "watcher/common/loader/default.py", line 59, in load
        raise exception.LoadingError(name=name)
    watcher.common.exception.LoadingError: Error loading plugin 'default'

watcher.tests.decision_engine.loading.test_collector_loader.TestLoadClusterDataModelCollectors.test_load_cluster_data_model_collectors(compute)
-----------------------------------------------------------------------------------------------------------------------------------------------

Captured traceback:
~~~~~~~~~~~~~~~~~~~
    Traceback (most recent call last):
      File "/data/bcom/OPENSTACK/watcher/.tox/py27/local/lib/python2.7/site-packages/mock/mock.py", line 1305, in patched
        return func(*args, **keywargs)
      File "watcher/tests/decision_engine/loading/test_collector_loader.py", line 82, in test_load_cluster_data_model_collectors
        collector = self.collector_loader.load(self.collector_name)
      File "watcher/common/loader/default.py", line 59, in load
        raise exception.LoadingError(name=name)
    watcher.common.exception.LoadingError: Error loading plugin 'compute'

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

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

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

Reviewed: https://review.openstack.org/361058
Committed: https://git.openstack.org/cgit/openstack/watcher/commit/?id=32c13d00fe23161340e87aa38933475b3571c68f
Submitter: Jenkins
Branch: master

commit 32c13d00fe23161340e87aa38933475b3571c68f
Author: David TARDIVEL <email address hidden>
Date: Fri Aug 26 12:08:45 2016 +0200

    Fix loading of plugin configuration parameters

    When the load a plugin, we need to reload once the watcher
    configuration data, in order to include the plugin parameters in
    cfg.CONF data dict. To reload the conf, we just call self.conf().
    But every time we call this method, cfg.CONF is cleaned, and we
    lost previously loaded parameters. This generated the exception
    RequiredOptError and the plugin was not correctly loaded.

    To fix it, we have just to add the watcher configuration
    filename as argument of self.conf().

    Change-Id: Ic2384b68f6d604640127fe06893d0f808aee34b7
    Closes-Bug: #1617240

Changed in watcher:
status: Fix Committed → Fix Released
Revision history for this message
Thierry Carrez (ttx) wrote : Fix included in openstack/watcher 0.29.0

This issue was fixed in the openstack/watcher 0.29.0 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.