Change in vdsm[master]: qemuimg: Move private functions to end of module

2014-09-25 Thread nsoffer
Nir Soffer has uploaded a new change for review.

Change subject: qemuimg: Move private functions to end of module
..

qemuimg: Move private functions to end of module

_supports_qcow_compat() is a private helper and should be after public
functions.

Change-Id: I060d3bb817ee543dabaf401756a909984cca9f8e
Signed-off-by: Nir Soffer 
---
M lib/vdsm/qemuimg.py
1 file changed, 25 insertions(+), 25 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/66/33366/1

diff --git a/lib/vdsm/qemuimg.py b/lib/vdsm/qemuimg.py
index 07c91e7..1d9632b 100644
--- a/lib/vdsm/qemuimg.py
+++ b/lib/vdsm/qemuimg.py
@@ -137,31 +137,6 @@
 raise QImgError(rc, out, err)
 
 
-def _supports_qcow2_compat(command):
-"""
-qemu-img "create:, "convert", and "ammend" commands support a "compat"
-option in recent versions. This will run the specified command using the
-"-o ?" option to find if "compat" option is available.
-
-Raises KeyError if called with another command.
-
-TODO: Remove this when qemu versions providing the "compat" option are
-available on all platforms.
-"""
-flag = {"create": "-f", "convert": "-O", "ammend": "-f"}[command]
-cmd = [_qemuimg.cmd, command, flag, FORMAT.QCOW2, "-o", "?", "/dev/null"]
-
-rc, out, err = utils.execCmd(cmd, raw=True)
-
-if rc != 0:
-raise QImgError(rc, out, err)
-
-# Supported options:
-# compat   Compatibility level (0.10 or 1.1)
-
-return '\ncompat ' in out
-
-
 def check(image, format=None):
 cmd = [_qemuimg.cmd, "check"]
 
@@ -244,3 +219,28 @@
 
 if rc != 0:
 raise QImgError(rc, out, err)
+
+
+def _supports_qcow2_compat(command):
+"""
+qemu-img "create:, "convert", and "ammend" commands support a "compat"
+option in recent versions. This will run the specified command using the
+"-o ?" option to find if "compat" option is available.
+
+Raises KeyError if called with another command.
+
+TODO: Remove this when qemu versions providing the "compat" option are
+available on all platforms.
+"""
+flag = {"create": "-f", "convert": "-O", "ammend": "-f"}[command]
+cmd = [_qemuimg.cmd, command, flag, FORMAT.QCOW2, "-o", "?", "/dev/null"]
+
+rc, out, err = utils.execCmd(cmd, raw=True)
+
+if rc != 0:
+raise QImgError(rc, out, err)
+
+# Supported options:
+# compat   Compatibility level (0.10 or 1.1)
+
+return '\ncompat ' in out


-- 
To view, visit http://gerrit.ovirt.org/33366
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I060d3bb817ee543dabaf401756a909984cca9f8e
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer 
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: qemuimg: Move private functions to end of module

2014-09-25 Thread nsoffer
Nir Soffer has posted comments on this change.

Change subject: qemuimg: Move private functions to end of module
..


Patch Set 1: Verified+1

-- 
To view, visit http://gerrit.ovirt.org/33366
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I060d3bb817ee543dabaf401756a909984cca9f8e
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer 
Gerrit-Reviewer: Nir Soffer 
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: qemuimg: Move private functions to end of module

2014-09-25 Thread oVirt Jenkins CI Server
oVirt Jenkins CI Server has posted comments on this change.

Change subject: qemuimg: Move private functions to end of module
..


Patch Set 1:

Build Successful 

http://jenkins.ovirt.org/job/vdsm_master_unit_tests_gerrit_el/11639/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_master_unit-tests_created/12583/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_master_pep8_gerrit/12428/ : SUCCESS

-- 
To view, visit http://gerrit.ovirt.org/33366
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I060d3bb817ee543dabaf401756a909984cca9f8e
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer 
Gerrit-Reviewer: Allon Mureinik 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Federico Simoncelli 
Gerrit-Reviewer: Nir Soffer 
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: qemuimg: Move private functions to end of module

2014-09-25 Thread Federico Simoncelli
Federico Simoncelli has posted comments on this change.

Change subject: qemuimg: Move private functions to end of module
..


Patch Set 1: Code-Review+1

I'll have some trouble to rebase on this but ok.

-- 
To view, visit http://gerrit.ovirt.org/33366
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I060d3bb817ee543dabaf401756a909984cca9f8e
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer 
Gerrit-Reviewer: Allon Mureinik 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Federico Simoncelli 
Gerrit-Reviewer: Nir Soffer 
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: qemuimg: Move private functions to end of module

2014-09-25 Thread oVirt Jenkins CI Server
oVirt Jenkins CI Server has posted comments on this change.

Change subject: qemuimg: Move private functions to end of module
..


Patch Set 2:

Build Successful 

http://jenkins.ovirt.org/job/vdsm_master_unit_tests_gerrit_el/11651/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_master_unit-tests_created/12595/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_master_pep8_gerrit/12440/ : SUCCESS

-- 
To view, visit http://gerrit.ovirt.org/33366
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I060d3bb817ee543dabaf401756a909984cca9f8e
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer 
Gerrit-Reviewer: Allon Mureinik 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Federico Simoncelli 
Gerrit-Reviewer: Nir Soffer 
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: qemuimg: Move private functions to end of module

2014-09-25 Thread oVirt Jenkins CI Server
oVirt Jenkins CI Server has posted comments on this change.

Change subject: qemuimg: Move private functions to end of module
..


Patch Set 3:

Build Successful 

http://jenkins.ovirt.org/job/vdsm_master_unit_tests_gerrit_el/11653/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_master_unit-tests_created/12597/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_master_pep8_gerrit/12442/ : SUCCESS

-- 
To view, visit http://gerrit.ovirt.org/33366
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I060d3bb817ee543dabaf401756a909984cca9f8e
Gerrit-PatchSet: 3
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer 
Gerrit-Reviewer: Allon Mureinik 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Federico Simoncelli 
Gerrit-Reviewer: Nir Soffer 
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: qemuimg: Move private functions to end of module

2014-09-25 Thread nsoffer
Nir Soffer has posted comments on this change.

Change subject: qemuimg: Move private functions to end of module
..


Patch Set 3: Verified+1

Rebase.

-- 
To view, visit http://gerrit.ovirt.org/33366
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I060d3bb817ee543dabaf401756a909984cca9f8e
Gerrit-PatchSet: 3
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer 
Gerrit-Reviewer: Allon Mureinik 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Federico Simoncelli 
Gerrit-Reviewer: Nir Soffer 
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: qemuimg: Move private functions to end of module

2014-09-25 Thread nsoffer
Nir Soffer has posted comments on this change.

Change subject: qemuimg: Move private functions to end of module
..


Patch Set 4:

Rebase

-- 
To view, visit http://gerrit.ovirt.org/33366
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I060d3bb817ee543dabaf401756a909984cca9f8e
Gerrit-PatchSet: 4
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer 
Gerrit-Reviewer: Allon Mureinik 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Federico Simoncelli 
Gerrit-Reviewer: Nir Soffer 
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: qemuimg: Move private functions to end of module

2014-09-25 Thread oVirt Jenkins CI Server
oVirt Jenkins CI Server has posted comments on this change.

Change subject: qemuimg: Move private functions to end of module
..


Patch Set 4:

Build Successful 

http://jenkins.ovirt.org/job/vdsm_master_unit_tests_gerrit_el/11655/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_master_unit-tests_created/12599/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_master_pep8_gerrit/12444/ : SUCCESS

-- 
To view, visit http://gerrit.ovirt.org/33366
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I060d3bb817ee543dabaf401756a909984cca9f8e
Gerrit-PatchSet: 4
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer 
Gerrit-Reviewer: Allon Mureinik 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Federico Simoncelli 
Gerrit-Reviewer: Nir Soffer 
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: qemuimg: Move private functions to end of module

2014-09-26 Thread Federico Simoncelli
Federico Simoncelli has posted comments on this change.

Change subject: qemuimg: Move private functions to end of module
..


Patch Set 4: Code-Review+2

-- 
To view, visit http://gerrit.ovirt.org/33366
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I060d3bb817ee543dabaf401756a909984cca9f8e
Gerrit-PatchSet: 4
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer 
Gerrit-Reviewer: Allon Mureinik 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Federico Simoncelli 
Gerrit-Reviewer: Nir Soffer 
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: qemuimg: Move private functions to end of module

2014-09-26 Thread nsoffer
Nir Soffer has posted comments on this change.

Change subject: qemuimg: Move private functions to end of module
..


Patch Set 5: Verified+1

Rebase

-- 
To view, visit http://gerrit.ovirt.org/33366
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I060d3bb817ee543dabaf401756a909984cca9f8e
Gerrit-PatchSet: 5
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer 
Gerrit-Reviewer: Allon Mureinik 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Federico Simoncelli 
Gerrit-Reviewer: Nir Soffer 
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: qemuimg: Move private functions to end of module

2014-09-26 Thread oVirt Jenkins CI Server
oVirt Jenkins CI Server has posted comments on this change.

Change subject: qemuimg: Move private functions to end of module
..


Patch Set 5:

Build Successful 

http://jenkins.ovirt.org/job/vdsm_master_unit_tests_gerrit_el/11679/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_master_unit-tests_created/12623/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_master_pep8_gerrit/12468/ : SUCCESS

-- 
To view, visit http://gerrit.ovirt.org/33366
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I060d3bb817ee543dabaf401756a909984cca9f8e
Gerrit-PatchSet: 5
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer 
Gerrit-Reviewer: Allon Mureinik 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Federico Simoncelli 
Gerrit-Reviewer: Nir Soffer 
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: qemuimg: Move private functions to end of module

2014-09-28 Thread amureini
Allon Mureinik has posted comments on this change.

Change subject: qemuimg: Move private functions to end of module
..


Patch Set 5: Code-Review+1

-- 
To view, visit http://gerrit.ovirt.org/33366
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I060d3bb817ee543dabaf401756a909984cca9f8e
Gerrit-PatchSet: 5
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer 
Gerrit-Reviewer: Allon Mureinik 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Federico Simoncelli 
Gerrit-Reviewer: Nir Soffer 
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: qemuimg: Move private functions to end of module

2014-09-29 Thread Federico Simoncelli
Federico Simoncelli has posted comments on this change.

Change subject: qemuimg: Move private functions to end of module
..


Patch Set 5: Code-Review+2

-- 
To view, visit http://gerrit.ovirt.org/33366
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I060d3bb817ee543dabaf401756a909984cca9f8e
Gerrit-PatchSet: 5
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer 
Gerrit-Reviewer: Allon Mureinik 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Federico Simoncelli 
Gerrit-Reviewer: Nir Soffer 
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: qemuimg: Move private functions to end of module

2014-09-29 Thread danken
Dan Kenigsberg has submitted this change and it was merged.

Change subject: qemuimg: Move private functions to end of module
..


qemuimg: Move private functions to end of module

_supports_qcow_compat() is a private helper and should be after public
functions.

Change-Id: I060d3bb817ee543dabaf401756a909984cca9f8e
Signed-off-by: Nir Soffer 
Reviewed-on: http://gerrit.ovirt.org/33366
Reviewed-by: Allon Mureinik 
Reviewed-by: Federico Simoncelli 
---
M lib/vdsm/qemuimg.py
1 file changed, 30 insertions(+), 30 deletions(-)

Approvals:
  Nir Soffer: Verified
  Federico Simoncelli: Looks good to me, approved
  Allon Mureinik: Looks good to me, but someone else must approve



-- 
To view, visit http://gerrit.ovirt.org/33366
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I060d3bb817ee543dabaf401756a909984cca9f8e
Gerrit-PatchSet: 6
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer 
Gerrit-Reviewer: Allon Mureinik 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Federico Simoncelli 
Gerrit-Reviewer: Nir Soffer 
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: qemuimg: Move private functions to end of module

2014-09-29 Thread oVirt Jenkins CI Server
oVirt Jenkins CI Server has posted comments on this change.

Change subject: qemuimg: Move private functions to end of module
..


Patch Set 6:

Build Failed 

http://jenkins.ovirt.org/job/vdsm_master_create-rpms_merged_test_debug/232/ : 
SUCCESS

http://jenkins.ovirt.org/job/vdsm_master_verify-error-codes_merged/5865/ : 
SUCCESS

http://jenkins.ovirt.org/job/vdsm_master_unit-tests_merged/4025/ : FAILURE

http://jenkins.ovirt.org/job/vdsm_master_create-rpms-el7-x86_64_merged/35/ : 
SUCCESS

http://jenkins.ovirt.org/job/vdsm_master_create-rpms-fc20-x86_64_merged/31/ : 
FAILURE

http://jenkins.ovirt.org/job/vdsm_master_create-rpms-el6-x86_64_merged/37/ : 
FAILURE

http://jenkins.ovirt.org/job/vdsm_master_create-rpms-fc21-x86_64_merged/11/ : 
FAILURE

-- 
To view, visit http://gerrit.ovirt.org/33366
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I060d3bb817ee543dabaf401756a909984cca9f8e
Gerrit-PatchSet: 6
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer 
Gerrit-Reviewer: Allon Mureinik 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Federico Simoncelli 
Gerrit-Reviewer: Nir Soffer 
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches