Hello community,

here is the log from the commit of package python-heatclient for 
openSUSE:Factory checked in at 2016-10-13 11:28:50
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-heatclient (Old)
 and      /work/SRC/openSUSE:Factory/.python-heatclient.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-heatclient"

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-heatclient/python-heatclient.changes      
2016-09-30 15:30:13.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.python-heatclient.new/python-heatclient.changes 
2016-10-13 11:28:51.000000000 +0200
@@ -1,0 +2,13 @@
+Mon Sep 26 12:56:35 UTC 2016 - tbecht...@suse.com
+
+update to version 1.5.0
+  * Replace functions 'Dict.get' and 'del' with 'Dict.pop'
+  * Trivial:Standardize the output format of 'help' in shell.py
+  * Show resource name path in event log formatter
+  * Clean imports in code
+  * Add parameter_merge_startegies section
+  * Modify use of assertTrue(A in B)
+  * Update .gitreview for stable/newton
+  * Import mox in __init__.py
+
+-------------------------------------------------------------------

Old:
----
  python-heatclient-1.4.0.tar.gz

New:
----
  python-heatclient-1.5.0.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-heatclient.spec ++++++
--- /var/tmp/diff_new_pack.JOcUy9/_old  2016-10-13 11:28:52.000000000 +0200
+++ /var/tmp/diff_new_pack.JOcUy9/_new  2016-10-13 11:28:52.000000000 +0200
@@ -18,7 +18,7 @@
 
 %global sname python-heatclient
 Name:           python-heatclient
-Version:        1.4.0
+Version:        1.5.0
 Release:        0
 Summary:        Python API and CLI for OpenStack Heat
 License:        Apache-2.0

++++++ python-heatclient-1.4.0.tar.gz -> python-heatclient-1.5.0.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-heatclient-1.4.0/AUTHORS 
new/python-heatclient-1.5.0/AUTHORS
--- old/python-heatclient-1.4.0/AUTHORS 2016-08-25 13:58:47.000000000 +0200
+++ new/python-heatclient-1.5.0/AUTHORS 2016-09-22 14:01:27.000000000 +0200
@@ -11,9 +11,11 @@
 Angus Salkeld <asalk...@mirantis.com>
 Angus Salkeld <asalk...@redhat.com>
 Bartlomiej Biernacki <pa...@o2.pl>
+Bin Zhou <zhou.b...@zte.com.cn>
 Bo Wang <bo.w...@easystack.cn>
 Bryan D. Payne <bdpa...@acm.org>
 Bryan Jones <jone...@us.ibm.com>
+Cao Xuan Hoang <hoan...@vn.fujitsu.com>
 ChenZheng <chen.zh...@easystack.cn>
 Chmouel Boudjnah <chmo...@enovance.com>
 Christian Berendt <bere...@b1-systems.de>
@@ -78,6 +80,7 @@
 Rui Chen <chenrui.m...@gmail.com>
 Ryan S. Brown <rybr...@redhat.com>
 Sergey Kraynev <skray...@mirantis.com>
+Sharat Sharma <sharat.sha...@nectechnologies.in>
 Shuquan Huang <huang.shuq...@99cloud.net>
 Simon Pasquier <pasquier.si...@gmail.com>
 Simon Pasquier <simon.pasqu...@bull.net>
@@ -110,6 +113,7 @@
 ZhiQiang Fan <aji.zq...@gmail.com>
 ZhiQiang Fan <zhiqiang....@huawei.com>
 anusha-rayani-7 <anusha.ray...@tcs.com>
+bhagyashris <bhagyashri.shew...@nttdata.com>
 cedric.brandily <cedric.brand...@thalesgroup.com>
 chenhaiq <chenh...@cn.ibm.com>
 chenxiao <chenx...@cn.ibm.com>
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-heatclient-1.4.0/ChangeLog 
new/python-heatclient-1.5.0/ChangeLog
--- old/python-heatclient-1.4.0/ChangeLog       2016-08-25 13:58:47.000000000 
+0200
+++ new/python-heatclient-1.5.0/ChangeLog       2016-09-22 14:01:27.000000000 
+0200
@@ -1,6 +1,21 @@
 CHANGES
 =======
 
+1.5.0
+-----
+
+* Add parameter_merge_startegies section
+* Show resource name path in event log formatter
+* Update .gitreview for stable/newton
+* Show resource name path in event log formatter
+* Clean imports in code
+* Update .gitreview for stable/newton
+* Modify use of assertTrue(A in B)
+* Import mox in __init__.py
+* Replace functions 'Dict.get' and 'del' with 'Dict.pop'
+* Trivial:Standardize the output format of 'help' in shell.py
+* Add parameter_merge_startegies section
+
 1.4.0
 -----
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-heatclient-1.4.0/PKG-INFO 
new/python-heatclient-1.5.0/PKG-INFO
--- old/python-heatclient-1.4.0/PKG-INFO        2016-08-25 13:58:48.000000000 
+0200
+++ new/python-heatclient-1.5.0/PKG-INFO        2016-09-22 14:01:28.000000000 
+0200
@@ -1,6 +1,6 @@
 Metadata-Version: 1.1
 Name: python-heatclient
-Version: 1.4.0
+Version: 1.5.0
 Summary: OpenStack Orchestration API Client Library
 Home-page: http://docs.openstack.org/developer/python-heatclient/
 Author: OpenStack
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/python-heatclient-1.4.0/heatclient/common/deployment_utils.py 
new/python-heatclient-1.5.0/heatclient/common/deployment_utils.py
--- old/python-heatclient-1.4.0/heatclient/common/deployment_utils.py   
2016-08-25 13:55:11.000000000 +0200
+++ new/python-heatclient-1.5.0/heatclient/common/deployment_utils.py   
2016-09-22 13:59:48.000000000 +0200
@@ -20,13 +20,13 @@
 
 from heatclient import exc
 from heatclient.openstack.common._i18n import _
-from heatclient.v1.software_configs import SoftwareConfig
+from heatclient.v1 import software_configs
 
 
 def build_derived_config_params(action, source, name, input_values,
                                 server_id, signal_transport, signal_id=None):
 
-    if isinstance(source, SoftwareConfig):
+    if isinstance(source, software_configs.SoftwareConfig):
         source = source.to_dict()
     input_values = input_values or {}
     inputs = copy.deepcopy(source.get('inputs')) or []
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/python-heatclient-1.4.0/heatclient/common/environment_format.py 
new/python-heatclient-1.5.0/heatclient/common/environment_format.py
--- old/python-heatclient-1.4.0/heatclient/common/environment_format.py 
2016-08-25 13:55:11.000000000 +0200
+++ new/python-heatclient-1.5.0/heatclient/common/environment_format.py 
2016-09-22 13:59:48.000000000 +0200
@@ -17,9 +17,13 @@
 
 
 SECTIONS = (
-    PARAMETER_DEFAULTS, PARAMETERS, RESOURCE_REGISTRY, EVENT_SINKS
+    PARAMETER_DEFAULTS, PARAMETERS, RESOURCE_REGISTRY,
+    ENCRYPTED_PARAM_NAMES, EVENT_SINKS,
+    PARAMETER_MERGE_STRATEGIES
 ) = (
-    'parameter_defaults', 'parameters', 'resource_registry', 'event_sinks'
+    'parameter_defaults', 'parameters', 'resource_registry',
+    'encrypted_param_names', 'event_sinks',
+    'parameter_merge_strategies'
 )
 
 
@@ -55,7 +59,9 @@
 
 def default_for_missing(env):
     """Checks a parsed environment for missing sections."""
-
     for param in SECTIONS:
-        if param not in env:
-            env[param] = {}
+        if param not in env and param != PARAMETER_MERGE_STRATEGIES:
+            if param in (ENCRYPTED_PARAM_NAMES, EVENT_SINKS):
+                env[param] = []
+            else:
+                env[param] = {}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/python-heatclient-1.4.0/heatclient/common/event_utils.py 
new/python-heatclient-1.5.0/heatclient/common/event_utils.py
--- old/python-heatclient-1.4.0/heatclient/common/event_utils.py        
2016-08-25 13:55:13.000000000 +0200
+++ new/python-heatclient-1.5.0/heatclient/common/event_utils.py        
2016-09-22 13:59:48.000000000 +0200
@@ -179,6 +179,7 @@
     msg_template = _("\n Stack %(name)s %(status)s \n")
     if not out:
         out = sys.stdout
+    event_log_context = utils.EventLogContext()
     while True:
         events = get_events(hc, stack_id=stack_name, nested_depth=nested_depth,
                             event_args={'sort_dir': 'asc',
@@ -190,7 +191,7 @@
             no_event_polls = 0
             # set marker to last event that was received.
             marker = getattr(events[-1], 'id', None)
-            events_log = utils.event_log_formatter(events)
+            events_log = utils.event_log_formatter(events, event_log_context)
             out.write(events_log)
             out.write('\n')
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-heatclient-1.4.0/heatclient/common/utils.py 
new/python-heatclient-1.5.0/heatclient/common/utils.py
--- old/python-heatclient-1.4.0/heatclient/common/utils.py      2016-08-25 
13:55:11.000000000 +0200
+++ new/python-heatclient-1.5.0/heatclient/common/utils.py      2016-09-22 
13:59:48.000000000 +0200
@@ -97,16 +97,84 @@
     print(pt.get_string(sortby='Property'))
 
 
-def event_log_formatter(events):
+class EventLogContext(object):
+
+    def __init__(self):
+        # key is a stack id or the name of the nested stack, value is a tuple
+        # of the parent stack id, and the name of the resource in the parent
+        # stack
+        self.id_to_res_info = {}
+
+    def prepend_paths(self, resource_path, stack_id):
+        if stack_id not in self.id_to_res_info:
+            return
+        stack_id, res_name = self.id_to_res_info.get(stack_id)
+        if res_name in self.id_to_res_info:
+            # do a double lookup to skip the ugly stack name that doesn't
+            # correspond to an actual resource name
+            n_stack_id, res_name = self.id_to_res_info.get(res_name)
+            resource_path.insert(0, res_name)
+            self.prepend_paths(resource_path, n_stack_id)
+        elif res_name:
+            resource_path.insert(0, res_name)
+
+    def build_resource_name(self, event):
+        res_name = getattr(event, 'resource_name')
+
+        # Contribute this event to self.id_to_res_info to assist with
+        # future calls to build_resource_name
+
+        def get_stack_id():
+            for l in getattr(event, 'links', []):
+                if l.get('rel') == 'stack':
+                    if 'href' not in l:
+                        return None
+                    stack_link = l['href']
+                    return stack_link.split('/')[-1]
+
+        stack_id = get_stack_id()
+        if not stack_id:
+            return res_name
+        phys_id = getattr(event, 'physical_resource_id')
+        status = getattr(event, 'resource_status')
+
+        is_stack_event = stack_id == phys_id
+        if is_stack_event:
+            # this is an event for a stack
+            self.id_to_res_info[stack_id] = (stack_id, res_name)
+        elif phys_id and status == 'CREATE_IN_PROGRESS':
+            # this might be an event for a resource which creates a stack
+            self.id_to_res_info[phys_id] = (stack_id, res_name)
+
+        # Now build this resource path based on previous calls to
+        # build_resource_name
+        resource_path = []
+        if res_name and not is_stack_event:
+            resource_path.append(res_name)
+        self.prepend_paths(resource_path, stack_id)
+
+        return '.'.join(resource_path)
+
+
+def event_log_formatter(events, event_log_context=None):
     """Return the events in log format."""
     event_log = []
     log_format = ("%(event_time)s "
                   "[%(rsrc_name)s]: %(rsrc_status)s  %(rsrc_status_reason)s")
+
+    # It is preferable for a context to be passed in, but there might be enough
+    # events in this call to build a better resource name, so create a context
+    # anyway
+    if event_log_context is None:
+        event_log_context = EventLogContext()
+
     for event in events:
+        rsrc_name = event_log_context.build_resource_name(event)
+
         event_time = getattr(event, 'event_time', '')
         log = log_format % {
             'event_time': event_time.replace('T', ' '),
-            'rsrc_name': getattr(event, 'resource_name', ''),
+            'rsrc_name': rsrc_name,
             'rsrc_status': getattr(event, 'resource_status', ''),
             'rsrc_status_reason': getattr(event, 'resource_status_reason', '')
         }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/python-heatclient-1.4.0/heatclient/openstack/common/apiclient/base.py 
new/python-heatclient-1.5.0/heatclient/openstack/common/apiclient/base.py
--- old/python-heatclient-1.4.0/heatclient/openstack/common/apiclient/base.py   
2016-08-25 13:55:11.000000000 +0200
+++ new/python-heatclient-1.5.0/heatclient/openstack/common/apiclient/base.py   
2016-09-22 13:59:48.000000000 +0200
@@ -286,7 +286,7 @@
       {}, {}]}`).
     - `key`: Usually a singular noun by convention (e.g. `entity`); used to
       refer to an individual member of the collection.
-
+    
     """
     collection_key = None
     key = None
@@ -446,7 +446,7 @@
 
     This is pretty much just a bag for attributes.
     """
-
+    
     HUMAN_ID = False
     NAME_ATTR = 'name'
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/python-heatclient-1.4.0/heatclient/openstack/common/apiclient/client.py 
new/python-heatclient-1.5.0/heatclient/openstack/common/apiclient/client.py
--- old/python-heatclient-1.4.0/heatclient/openstack/common/apiclient/client.py 
2016-08-25 13:55:11.000000000 +0200
+++ new/python-heatclient-1.5.0/heatclient/openstack/common/apiclient/client.py 
2016-09-22 13:59:48.000000000 +0200
@@ -145,13 +145,10 @@
                 resp.text)
 
     def serialize(self, kwargs):
-        if kwargs.get('json') is not None:
+        json_data = kwargs.pop('json', None)
+        if json_data is not None:
             kwargs['headers']['Content-Type'] = 'application/json'
-            kwargs['data'] = json.dumps(kwargs['json'])
-        try:
-            del kwargs['json']
-        except KeyError:
-            pass
+            kwargs['data'] = json.dumps(json_data)
 
     def get_timings(self):
         return self.times
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-heatclient-1.4.0/heatclient/osc/v1/event.py 
new/python-heatclient-1.5.0/heatclient/osc/v1/event.py
--- old/python-heatclient-1.4.0/heatclient/osc/v1/event.py      2016-08-25 
13:55:11.000000000 +0200
+++ new/python-heatclient-1.5.0/heatclient/osc/v1/event.py      2016-09-22 
13:59:48.000000000 +0200
@@ -177,6 +177,7 @@
 
             marker = parsed_args.marker
             try:
+                event_log_context = heat_utils.EventLogContext()
                 while True:
                     events = event_utils.get_events(
                         client,
@@ -186,7 +187,8 @@
                         marker=marker)
                     if events:
                         marker = getattr(events[-1], 'id', None)
-                        events_log = heat_utils.event_log_formatter(events)
+                        events_log = heat_utils.event_log_formatter(
+                            events, event_log_context)
                         self.app.stdout.write(events_log)
                         self.app.stdout.write('\n')
                     time.sleep(5)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/python-heatclient-1.4.0/heatclient/tests/unit/__init__.py 
new/python-heatclient-1.5.0/heatclient/tests/unit/__init__.py
--- old/python-heatclient-1.4.0/heatclient/tests/unit/__init__.py       
2016-08-25 13:55:11.000000000 +0200
+++ new/python-heatclient-1.5.0/heatclient/tests/unit/__init__.py       
2016-09-22 13:59:48.000000000 +0200
@@ -0,0 +1,5 @@
+import sys
+
+from mox3 import mox
+
+sys.modules['mox'] = mox
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/python-heatclient-1.4.0/heatclient/tests/unit/osc/v1/test_template.py 
new/python-heatclient-1.5.0/heatclient/tests/unit/osc/v1/test_template.py
--- old/python-heatclient-1.4.0/heatclient/tests/unit/osc/v1/test_template.py   
2016-08-25 13:55:11.000000000 +0200
+++ new/python-heatclient-1.5.0/heatclient/tests/unit/osc/v1/test_template.py   
2016-09-22 13:59:48.000000000 +0200
@@ -117,7 +117,7 @@
         self.assertEqual(1, self.stack_client.validate.call_count)
         args = self.stack_client.validate.call_args[1]
         self.assertEqual(args.get('environment'), {'parameters': {}})
-        self.assertTrue(self.env_path in args.get('environment_files')[0])
+        self.assertIn(self.env_path, args.get('environment_files')[0])
         self.assertEqual([], columns)
         self.assertEqual([], data)
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/python-heatclient-1.4.0/heatclient/tests/unit/test_common_http.py 
new/python-heatclient-1.5.0/heatclient/tests/unit/test_common_http.py
--- old/python-heatclient-1.4.0/heatclient/tests/unit/test_common_http.py       
2016-08-25 13:55:11.000000000 +0200
+++ new/python-heatclient-1.5.0/heatclient/tests/unit/test_common_http.py       
2016-09-22 13:59:48.000000000 +0200
@@ -18,7 +18,7 @@
 
 from keystoneauth1 import adapter
 import mock
-from mox3 import mox
+import mox
 from oslo_serialization import jsonutils
 import requests
 import six
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/python-heatclient-1.4.0/heatclient/tests/unit/test_environment_format.py 
new/python-heatclient-1.5.0/heatclient/tests/unit/test_environment_format.py
--- 
old/python-heatclient-1.4.0/heatclient/tests/unit/test_environment_format.py    
    2016-08-25 13:55:11.000000000 +0200
+++ 
new/python-heatclient-1.5.0/heatclient/tests/unit/test_environment_format.py    
    2016-09-22 13:59:48.000000000 +0200
@@ -27,15 +27,31 @@
         yaml1 = ''
         yaml2 = '''
 parameter_defaults: {}
+encrypted_param_names: []
 parameters: {}
 resource_registry: {}
-event_sinks: {}
+event_sinks: []
 '''
         tpl1 = environment_format.parse(yaml1)
         environment_format.default_for_missing(tpl1)
         tpl2 = environment_format.parse(yaml2)
         self.assertEqual(tpl2, tpl1)
 
+    def test_param_valid_strategy_section(self):
+        yaml1 = ''
+        yaml2 = '''
+parameters: {}
+encrypted_param_names: []
+parameter_defaults: {}
+parameter_merge_strategies: {}
+event_sinks: []
+resource_registry: {}
+'''
+        tpl1 = environment_format.parse(yaml1)
+        environment_format.default_for_missing(tpl1)
+        tpl2 = environment_format.parse(yaml2)
+        self.assertNotEqual(tpl1, tpl2)
+
     def test_wrong_sections(self):
         env = '''
 parameters: {}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/python-heatclient-1.4.0/heatclient/tests/unit/test_events.py 
new/python-heatclient-1.5.0/heatclient/tests/unit/test_events.py
--- old/python-heatclient-1.4.0/heatclient/tests/unit/test_events.py    
2016-08-25 13:55:11.000000000 +0200
+++ new/python-heatclient-1.5.0/heatclient/tests/unit/test_events.py    
2016-09-22 13:59:48.000000000 +0200
@@ -13,7 +13,7 @@
 #    under the License.
 
 import mock
-from mox3 import mox
+import mox
 import testtools
 
 from heatclient.common import utils
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/python-heatclient-1.4.0/heatclient/tests/unit/test_resources.py 
new/python-heatclient-1.5.0/heatclient/tests/unit/test_resources.py
--- old/python-heatclient-1.4.0/heatclient/tests/unit/test_resources.py 
2016-08-25 13:55:11.000000000 +0200
+++ new/python-heatclient-1.5.0/heatclient/tests/unit/test_resources.py 
2016-09-22 13:59:48.000000000 +0200
@@ -12,7 +12,7 @@
 #    License for the specific language governing permissions and limitations
 #    under the License.
 
-from mox3 import mox
+import mox
 from six.moves.urllib import parse
 import testtools
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/python-heatclient-1.4.0/heatclient/tests/unit/test_shell.py 
new/python-heatclient-1.5.0/heatclient/tests/unit/test_shell.py
--- old/python-heatclient-1.4.0/heatclient/tests/unit/test_shell.py     
2016-08-25 13:55:11.000000000 +0200
+++ new/python-heatclient-1.5.0/heatclient/tests/unit/test_shell.py     
2016-09-22 13:59:48.000000000 +0200
@@ -19,7 +19,7 @@
 import fixtures
 from keystoneauth1 import fixture as keystone_fixture
 import mock
-from mox3 import mox
+import mox
 from oslo_serialization import jsonutils
 from oslo_utils import encodeutils
 from oslotest import mockpatch
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/python-heatclient-1.4.0/heatclient/tests/unit/test_template_utils.py 
new/python-heatclient-1.5.0/heatclient/tests/unit/test_template_utils.py
--- old/python-heatclient-1.4.0/heatclient/tests/unit/test_template_utils.py    
2016-08-25 13:55:11.000000000 +0200
+++ new/python-heatclient-1.5.0/heatclient/tests/unit/test_template_utils.py    
2016-09-22 13:59:48.000000000 +0200
@@ -15,7 +15,7 @@
 import json
 import tempfile
 
-from mox3 import mox
+import mox
 import six
 from six.moves.urllib import error
 from six.moves.urllib import request
@@ -411,7 +411,7 @@
                          files['file:///home/b/a.yaml'])
 
         self.assertEqual(['file:///home/my/dir/env1.yaml'], env_file_list)
-        self.assertTrue('file:///home/my/dir/env1.yaml' in files)
+        self.assertIn('file:///home/my/dir/env1.yaml', files)
         self.assertEqual(expected_env,
                          json.loads(files['file:///home/my/dir/env1.yaml']))
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/python-heatclient-1.4.0/heatclient/tests/unit/test_utils.py 
new/python-heatclient-1.5.0/heatclient/tests/unit/test_utils.py
--- old/python-heatclient-1.4.0/heatclient/tests/unit/test_utils.py     
2016-08-25 13:55:11.000000000 +0200
+++ new/python-heatclient-1.5.0/heatclient/tests/unit/test_utils.py     
2016-09-22 13:59:48.000000000 +0200
@@ -191,6 +191,148 @@
         self.assertEqual(expected, utils.event_log_formatter(events_list))
         self.assertEqual('', utils.event_log_formatter([]))
 
+    def test_event_log_formatter_resource_path_old_heat(self):
+
+        events = [{
+            'resource_name': 'nested',
+            'event_time': '2016-09-05T04:10:24Z',
+            'links': [{
+                'href': 'http://192.0.2.1:8004/v1/t/stacks/'
+                'nested/1bed5d4d-41d6-4451-b274-c073ebee375d',
+                'rel': 'stack'
+            }],
+            'logical_resource_id': 'nested',
+            'resource_status': 'CREATE_IN_PROGRESS',
+            'resource_status_reason': 'Stack CREATE started',
+            'physical_resource_id': '1bed5d4d-41d6-4451-b274-c073ebee375d',
+        }, {
+            'resource_name': 'rg1',
+            'event_time': '2016-09-05T04:10:24Z',
+            'links': [{
+                'href': 'http://192.0.2.1:8004/v1/t/stacks/'
+                'nested/1bed5d4d-41d6-4451-b274-c073ebee375d',
+                'rel': 'stack'
+            }],
+            'logical_resource_id': 'rg1',
+            'resource_status': 'CREATE_IN_PROGRESS',
+            'resource_status_reason': 'state changed',
+            'physical_resource_id': None,  # note the None from old heat
+            'id': '375c49ae-cefb-4fb3-8f4d-1d5f1b9e3e5d'
+        }, {
+            'resource_name': 'nested-rg1-m4zxcs4pra6t',
+            'event_time': '2016-09-05T04:10:24Z',
+            'links': [{
+                'href': 'http://192.0.2.1:8004/v1/t/stacks/'
+                'nested-rg1-m4zxcs4pra6t/'
+                '3400bbad-a825-4226-ac23-c607846420db',
+                'rel': 'stack'
+            }],
+            'logical_resource_id': 'nested-rg1-m4zxcs4pra6t',
+            'resource_status': 'CREATE_IN_PROGRESS',
+            'resource_status_reason': 'Stack CREATE started',
+            'physical_resource_id': '3400bbad-a825-4226-ac23-c607846420db',
+            'id': '7e521c84-cd35-4f4c-b0de-962bd3cc40a8'
+        }, {
+            'resource_name': '1',
+            'event_time': '2016-09-05T04:10:24Z',
+            'links': [{
+                'href': 'http://192.0.2.1:8004/v1/t/stacks/'
+                'nested-rg1-m4zxcs4pra6t/'
+                '3400bbad-a825-4226-ac23-c607846420db',
+                'rel': 'stack'
+            }],
+            'logical_resource_id': '1',
+            'resource_status': 'CREATE_IN_PROGRESS',
+            'resource_status_reason': 'state changed',
+            'physical_resource_id': None,  # note the None from old heat
+            'id': 'c6186c16-94ef-4214-a11a-7e3cc8a17f82'
+        }]
+
+        events_list = [hc_res.Resource(manager=None, info=event)
+                       for event in events]
+
+        expected = '''\
+2016-09-05 04:10:24Z [nested]: \
+CREATE_IN_PROGRESS  Stack CREATE started
+2016-09-05 04:10:24Z [nested.rg1]: \
+CREATE_IN_PROGRESS  state changed
+2016-09-05 04:10:24Z [nested-rg1-m4zxcs4pra6t]: \
+CREATE_IN_PROGRESS  Stack CREATE started
+2016-09-05 04:10:24Z [nested-rg1-m4zxcs4pra6t.1]: \
+CREATE_IN_PROGRESS  state changed'''
+        self.assertEqual(expected, utils.event_log_formatter(events_list))
+
+    def test_event_log_formatter_resource_path(self):
+
+        events = [{
+            'resource_name': 'nested',
+            'event_time': '2016-09-05T04:10:24Z',
+            'links': [{
+                'href': 'http://192.0.2.1:8004/v1/t/stacks/'
+                'nested/1bed5d4d-41d6-4451-b274-c073ebee375d',
+                'rel': 'stack'
+            }],
+            'logical_resource_id': 'nested',
+            'resource_status': 'CREATE_IN_PROGRESS',
+            'resource_status_reason': 'Stack CREATE started',
+            'physical_resource_id': '1bed5d4d-41d6-4451-b274-c073ebee375d',
+        }, {
+            'resource_name': 'rg1',
+            'event_time': '2016-09-05T04:10:24Z',
+            'links': [{
+                'href': 'http://192.0.2.1:8004/v1/t/stacks/'
+                'nested/1bed5d4d-41d6-4451-b274-c073ebee375d',
+                'rel': 'stack'
+            }],
+            'logical_resource_id': 'rg1',
+            'resource_status': 'CREATE_IN_PROGRESS',
+            'resource_status_reason': 'state changed',
+            'physical_resource_id': 'nested-rg1-m4zxcs4pra6t',
+            'id': '375c49ae-cefb-4fb3-8f4d-1d5f1b9e3e5d'
+        }, {
+            'resource_name': 'nested-rg1-m4zxcs4pra6t',
+            'event_time': '2016-09-05T04:10:24Z',
+            'links': [{
+                'href': 'http://192.0.2.1:8004/v1/t/stacks/'
+                'nested-rg1-m4zxcs4pra6t/'
+                '3400bbad-a825-4226-ac23-c607846420db',
+                'rel': 'stack'
+            }],
+            'logical_resource_id': 'nested-rg1-m4zxcs4pra6t',
+            'resource_status': 'CREATE_IN_PROGRESS',
+            'resource_status_reason': 'Stack CREATE started',
+            'physical_resource_id': '3400bbad-a825-4226-ac23-c607846420db',
+            'id': '7e521c84-cd35-4f4c-b0de-962bd3cc40a8'
+        }, {
+            'resource_name': '1',
+            'event_time': '2016-09-05T04:10:24Z',
+            'links': [{
+                'href': 'http://192.0.2.1:8004/v1/t/stacks/'
+                'nested-rg1-m4zxcs4pra6t/'
+                '3400bbad-a825-4226-ac23-c607846420db',
+                'rel': 'stack'
+            }],
+            'logical_resource_id': '1',
+            'resource_status': 'CREATE_IN_PROGRESS',
+            'resource_status_reason': 'state changed',
+            'physical_resource_id': 'nested-rg1-m4zxcs4pra6t-1-z6sgpq54n6e7',
+            'id': 'c6186c16-94ef-4214-a11a-7e3cc8a17f82'
+        }]
+
+        events_list = [hc_res.Resource(manager=None, info=event)
+                       for event in events]
+
+        expected = '''\
+2016-09-05 04:10:24Z [nested]: \
+CREATE_IN_PROGRESS  Stack CREATE started
+2016-09-05 04:10:24Z [nested.rg1]: \
+CREATE_IN_PROGRESS  state changed
+2016-09-05 04:10:24Z [nested.rg1]: \
+CREATE_IN_PROGRESS  Stack CREATE started
+2016-09-05 04:10:24Z [nested.rg1.1]: \
+CREATE_IN_PROGRESS  state changed'''
+        self.assertEqual(expected, utils.event_log_formatter(events_list))
+
 
 class ShellTestParameterFiles(testtools.TestCase):
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-heatclient-1.4.0/heatclient/v1/shell.py 
new/python-heatclient-1.5.0/heatclient/v1/shell.py
--- old/python-heatclient-1.4.0/heatclient/v1/shell.py  2016-08-25 
13:55:11.000000000 +0200
+++ new/python-heatclient-1.5.0/heatclient/v1/shell.py  2016-09-22 
13:59:48.000000000 +0200
@@ -417,7 +417,7 @@
 @utils.arg('id', metavar='<NAME or ID>',
            help=_('Name or ID of stack to describe.'))
 @utils.arg('--no-resolve-outputs', action="store_true",
-           help='Do not resolve outputs of the stack.')
+           help=_('Do not resolve outputs of the stack.'))
 def do_stack_show(hc, args):
     '''Describe the stack.'''
     show_deprecated('heat stack-show', 'openstack stack show')
@@ -462,10 +462,10 @@
                   'updated.')
            % {'true': strutils.TRUE_STRINGS, 'false': strutils.FALSE_STRINGS})
 @utils.arg('-y', '--dry-run', default=False, action="store_true",
-           help='Do not actually perform the stack update, but show what '
-           'would be changed')
+           help=_('Do not actually perform the stack update, but show what '
+                  'would be changed'))
 @utils.arg('-n', '--show-nested', default=False, action="store_true",
-           help='Show nested stacks when performing --dry-run')
+           help=_('Show nested stacks when performing --dry-run'))
 @utils.arg('-P', '--parameters', metavar='<KEY1=VALUE1;KEY2=VALUE2...>',
            help=_('Parameter values used to create the stack. '
                   'This can be specified multiple times, or once with '
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/python-heatclient-1.4.0/python_heatclient.egg-info/PKG-INFO 
new/python-heatclient-1.5.0/python_heatclient.egg-info/PKG-INFO
--- old/python-heatclient-1.4.0/python_heatclient.egg-info/PKG-INFO     
2016-08-25 13:58:47.000000000 +0200
+++ new/python-heatclient-1.5.0/python_heatclient.egg-info/PKG-INFO     
2016-09-22 14:01:27.000000000 +0200
@@ -1,6 +1,6 @@
 Metadata-Version: 1.1
 Name: python-heatclient
-Version: 1.4.0
+Version: 1.5.0
 Summary: OpenStack Orchestration API Client Library
 Home-page: http://docs.openstack.org/developer/python-heatclient/
 Author: OpenStack
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/python-heatclient-1.4.0/python_heatclient.egg-info/pbr.json 
new/python-heatclient-1.5.0/python_heatclient.egg-info/pbr.json
--- old/python-heatclient-1.4.0/python_heatclient.egg-info/pbr.json     
2016-08-25 13:58:47.000000000 +0200
+++ new/python-heatclient-1.5.0/python_heatclient.egg-info/pbr.json     
2016-09-22 14:01:27.000000000 +0200
@@ -1 +1 @@
-{"git_version": "fb7802e", "is_release": true}
\ No newline at end of file
+{"is_release": true, "git_version": "3c3f8ee"}
\ No newline at end of file


Reply via email to