Hello community,

here is the log from the commit of package crmsh for openSUSE:Factory checked 
in at 2015-09-08 17:39:46
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/crmsh (Old)
 and      /work/SRC/openSUSE:Factory/.crmsh.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "crmsh"

Changes:
--------
--- /work/SRC/openSUSE:Factory/crmsh/crmsh.changes      2015-08-31 
22:59:27.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.crmsh.new/crmsh.changes 2015-09-08 
17:44:35.000000000 +0200
@@ -1,0 +2,11 @@
+Fri Sep 04 08:08:48 UTC 2015 - kgronl...@suse.com
+
+- Update to version 2.2.0~rc3+git.1441319359.d823416:
+  + high: scripts: Generate actions for includes if none are defined
+  + high: script: Fix subscript agent reference bug
+  + medium: crm_pssh: Timeout is an int (bsc#943820)
+  + medium: scripts: Fix typo in lvm script
+  + low: scripts: [virtual-ip] make lvs_support an advanced parameter
+  + low: constants: Add meta attributes for remote nodes
+
+-------------------------------------------------------------------

Old:
----
  crmsh-2.2.0~rc3+git.1440887645.cd6ac8a.tar.bz2

New:
----
  crmsh-2.2.0~rc3+git.1441319359.d823416.tar.bz2

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

Other differences:
------------------
++++++ crmsh.spec ++++++
--- /var/tmp/diff_new_pack.2xqdkY/_old  2015-09-08 17:44:37.000000000 +0200
+++ /var/tmp/diff_new_pack.2xqdkY/_new  2015-09-08 17:44:37.000000000 +0200
@@ -36,7 +36,7 @@
 Summary:        High Availability cluster command-line interface
 License:        GPL-2.0+
 Group:          %{pkg_group}
-Version:        2.2.0~rc3+git.1440887645.cd6ac8a
+Version:        2.2.0~rc3+git.1441319359.d823416
 Release:        0
 Url:            http://crmsh.github.io
 Source0:        %{name}-%{version}.tar.bz2

++++++ _servicedata ++++++
--- /var/tmp/diff_new_pack.2xqdkY/_old  2015-09-08 17:44:37.000000000 +0200
+++ /var/tmp/diff_new_pack.2xqdkY/_new  2015-09-08 17:44:37.000000000 +0200
@@ -1,4 +1,4 @@
 <servicedata>
 <service name="tar_scm">
             <param name="url">git://github.com/ClusterLabs/crmsh.git</param>
-          <param 
name="changesrevision">cd6ac8af585a2f35074fcdeafba7a8e50bcd568f</param></service></servicedata>
\ No newline at end of file
+          <param 
name="changesrevision">d823416786d3e5c66d27d6de2fe43228df22fdac</param></service></servicedata>
\ No newline at end of file

++++++ crmsh-2.2.0~rc3+git.1440887645.cd6ac8a.tar.bz2 -> 
crmsh-2.2.0~rc3+git.1441319359.d823416.tar.bz2 ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/crmsh-2.2.0~rc3+git.1440887645.cd6ac8a/modules/constants.py 
new/crmsh-2.2.0~rc3+git.1441319359.d823416/modules/constants.py
--- old/crmsh-2.2.0~rc3+git.1440887645.cd6ac8a/modules/constants.py     
2015-08-31 08:45:12.000000000 +0200
+++ new/crmsh-2.2.0~rc3+git.1441319359.d823416/modules/constants.py     
2015-09-04 10:08:47.000000000 +0200
@@ -206,7 +206,7 @@
     "migration-threshold", "priority", "multiple-active",
     "failure-timeout", "resource-stickiness", "target-role",
     "restart-type", "description", "remote-node", "requires",
-    "provides"
+    "provides", "remote-port", "remote-addr", "remote-connect-timeout"
 )
 group_meta_attributes = ("container", )
 clone_meta_attributes = (
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/crmsh-2.2.0~rc3+git.1440887645.cd6ac8a/modules/crm_pssh.py 
new/crmsh-2.2.0~rc3+git.1441319359.d823416/modules/crm_pssh.py
--- old/crmsh-2.2.0~rc3+git.1440887645.cd6ac8a/modules/crm_pssh.py      
2015-08-31 08:45:12.000000000 +0200
+++ new/crmsh-2.2.0~rc3+git.1441319359.d823416/modules/crm_pssh.py      
2015-09-04 10:08:47.000000000 +0200
@@ -31,7 +31,7 @@
     Parse the given commandline arguments.
     '''
     opts = Options()
-    opts.timeout = t
+    opts.timeout = int(t)
     opts.quiet = True
     opts.inline = False
     opts.outdir = outdir
@@ -195,7 +195,7 @@
         l.append([node, cmd])
     if not l:
         return True
-    opts = parse_args(outdir, errdir, t=str(int(timeout/1000)))
+    opts = parse_args(outdir, errdir, t=int(timeout/1000))
     return do_pssh(l, opts)
 
 # vim:ts=4:sw=4:et:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/crmsh-2.2.0~rc3+git.1440887645.cd6ac8a/modules/scripts.py 
new/crmsh-2.2.0~rc3+git.1441319359.d823416/modules/scripts.py
--- old/crmsh-2.2.0~rc3+git.1440887645.cd6ac8a/modules/scripts.py       
2015-08-31 08:45:12.000000000 +0200
+++ new/crmsh-2.2.0~rc3+git.1441319359.d823416/modules/scripts.py       
2015-09-04 10:08:47.000000000 +0200
@@ -923,6 +923,11 @@
     if 'actions' not in script:
         script['actions'] = []
 
+        # if we include subscripts but have no defined actions, assume that's a
+        # mistake and generate include actions for all includes
+        for inc in [{"include": inc['name']} for inc in script.get('include', 
[])]:
+            script['actions'].append(inc)
+
     _postprocess_script_steps(script)
 
     # Includes may add steps, or modify parameters,
@@ -1455,7 +1460,7 @@
         for step in context.get('steps', []):
             name = step.get('name', '')
             if name:
-                if step['required'] or 'name' in params:
+                if step['required'] or name in params:
                     obj = {}
                     vobj = handles.value(obj, '')
                     to[name] = vobj
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/crmsh-2.2.0~rc3+git.1440887645.cd6ac8a/scripts/lvm/main.yml 
new/crmsh-2.2.0~rc3+git.1441319359.d823416/scripts/lvm/main.yml
--- old/crmsh-2.2.0~rc3+git.1440887645.cd6ac8a/scripts/lvm/main.yml     
2015-08-31 08:45:12.000000000 +0200
+++ new/crmsh-2.2.0~rc3+git.1441319359.d823416/scripts/lvm/main.yml     
2015-09-04 10:08:47.000000000 +0200
@@ -13,5 +13,5 @@
           required: true
           type: string
       ops: |
-        op monitor=130s timeout=130s
+        op monitor interval=130s timeout=130s
         op stop timeout=130s on_fail=fence
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/crmsh-2.2.0~rc3+git.1440887645.cd6ac8a/scripts/virtual-ip/main.yml 
new/crmsh-2.2.0~rc3+git.1441319359.d823416/scripts/virtual-ip/main.yml
--- old/crmsh-2.2.0~rc3+git.1440887645.cd6ac8a/scripts/virtual-ip/main.yml      
2015-08-31 08:45:12.000000000 +0200
+++ new/crmsh-2.2.0~rc3+git.1441319359.d823416/scripts/virtual-ip/main.yml      
2015-09-04 10:08:47.000000000 +0200
@@ -18,9 +18,6 @@
         - name: broadcast
           type: ip_address
           required: false
-        - name: lvs_support
-          required: false
-          type: boolean
       ops: |
         op start timeout="20" op stop timeout="20"
         op monitor interval="10" timeout="20"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/crmsh-2.2.0~rc3+git.1440887645.cd6ac8a/test/unittests/test_scripts.py 
new/crmsh-2.2.0~rc3+git.1441319359.d823416/test/unittests/test_scripts.py
--- old/crmsh-2.2.0~rc3+git.1440887645.cd6ac8a/test/unittests/test_scripts.py   
2015-08-31 08:45:12.000000000 +0200
+++ new/crmsh-2.2.0~rc3+git.1441319359.d823416/test/unittests/test_scripts.py   
2015-09-04 10:08:47.000000000 +0200
@@ -597,3 +597,50 @@
     pprint(actions)
     assert actions[0]['text'] == "SARUMAN+SARUMAN"
 
+
+@with_setup(setup_func, teardown_func)
+def test_optional_step_ref():
+    """
+    It seems I have a bug in referencing ids from substeps.
+    """
+    a = '''---
+- version: 2.2
+  category: Script
+  include:
+    - agent: test:apache
+      name: apache
+      parameters:
+        - name: id
+          required: true
+'''
+    b = '''---
+- version: 2.2
+  category: Script
+  include:
+    - script: apache
+      required: false
+  parameters:
+    - name: wiz
+      required: true
+  actions:
+    - cib: "primitive {{wiz}} {{apache:id}}"
+'''
+
+    script_a = scripts.load_script_string('apache', a)
+    script_b = scripts.load_script_string('test-b', b)
+    assert script_a is not None
+    assert script_b is not None
+
+    actions = scripts.verify(script_a,
+                             {"id": "apacho"})
+    eq_(len(actions), 1)
+    pprint(actions)
+    assert actions[0]['text'] == "primitive apacho test:apache"
+
+    #import ipdb
+    #ipdb.set_trace()
+    actions = scripts.verify(script_b,
+                             {'wiz': "SARUMAN", "apache": {"id": "apacho"}})
+    eq_(len(actions), 1)
+    pprint(actions)
+    assert actions[0]['text'] == "primitive SARUMAN apacho"


Reply via email to