Change in vdsm[master]: Adding toolTests.py to python3 check modules

2015-12-06 Thread nsoffer
Nir Soffer has posted comments on this change.

Change subject: Adding toolTests.py to python3 check modules
..


Patch Set 8:

(1 comment)

https://gerrit.ovirt.org/#/c/48052/8/lib/vdsm/tool/configfile.py
File lib/vdsm/tool/configfile.py:

Line 260
Line 261
Line 262
Line 263
Line 264
> using io.open(path, 'r', encoding='utf8') returns unicode on both python 2 
Do we want unicode? open(path, "rb") should return bytes in both 2 and 3.

When we write configuration file containing ascii only content, there is no 
need to work with unicode.


-- 
To view, visit https://gerrit.ovirt.org/48052
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I52f11a1a10cae46773d05d0c09da80ad8eb3b772
Gerrit-PatchSet: 8
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Yaniv Bronhaim 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer 
Gerrit-Reviewer: Yaniv Bronhaim 
Gerrit-Reviewer: Yeela Kaplan 
Gerrit-Reviewer: gerrit-hooks 
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Adding toolTests.py to python3 check modules

2015-11-24 Thread ybronhei
Yaniv Bronhaim has posted comments on this change.

Change subject: Adding toolTests.py to python3 check modules
..


Patch Set 8:

(1 comment)

https://gerrit.ovirt.org/#/c/48052/8/lib/vdsm/tool/configfile.py
File lib/vdsm/tool/configfile.py:

Line 260
Line 261
Line 262
Line 263
Line 264
using io.open(path, 'r', encoding='utf8') returns unicode on both python 2 and 3


-- 
To view, visit https://gerrit.ovirt.org/48052
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I52f11a1a10cae46773d05d0c09da80ad8eb3b772
Gerrit-PatchSet: 8
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Yaniv Bronhaim 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer 
Gerrit-Reviewer: Yaniv Bronhaim 
Gerrit-Reviewer: Yeela Kaplan 
Gerrit-Reviewer: gerrit-hooks 
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Adding toolTests.py to python3 check modules

2015-11-10 Thread automation
automat...@ovirt.org has posted comments on this change.

Change subject: Adding toolTests.py to python3 check modules
..


Patch Set 8:

* Update tracker: IGNORE, no Bug-Url found
* Check Bug-Url::WARN, no bug url found, make sure header matches 'Bug-Url: ' 
and is a valid url.
* Check merged to previous::IGNORE, Not in stable branch (['ovirt-3.5', 
'ovirt-3.4', 'ovirt-3.3'])

-- 
To view, visit https://gerrit.ovirt.org/48052
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I52f11a1a10cae46773d05d0c09da80ad8eb3b772
Gerrit-PatchSet: 8
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Yaniv Bronhaim 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer 
Gerrit-Reviewer: Yeela Kaplan 
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]: Adding toolTests.py to python3 check modules

2015-11-06 Thread nsoffer
Nir Soffer has posted comments on this change.

Change subject: Adding toolTests.py to python3 check modules
..


Patch Set 7: Code-Review-1

(2 comments)

https://gerrit.ovirt.org/#/c/48052/7/lib/vdsm/tool/configfile.py
File lib/vdsm/tool/configfile.py:

Line 22: import os
Line 23: import tempfile
Line 24: import re
Line 25: import selinux
Line 26: from six.moves import configparser as ConfigParser
Keep python3 name, rename usage of old name.
Line 27: import io
Line 28: 
Line 29: from .. import utils
Line 30: 


Line 262: 
Line 263: def read(self, path):
Line 264: with open(path, 'r') as f:
Line 265: return self.wrapped.readfp(
Line 266: io.StringIO(u'[root]\n' + f.read())
Are you sure it works for both 2 and 3?


-- 
To view, visit https://gerrit.ovirt.org/48052
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I52f11a1a10cae46773d05d0c09da80ad8eb3b772
Gerrit-PatchSet: 7
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Yaniv Bronhaim 
Gerrit-Reviewer: Dan Kenigsberg 
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer 
Gerrit-Reviewer: Yeela Kaplan 
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Adding toolTests.py to python3 check modules

2015-11-05 Thread automation
automat...@ovirt.org has posted comments on this change.

Change subject: Adding toolTests.py to python3 check modules
..


Patch Set 7:

* Update tracker: IGNORE, no Bug-Url found
* Check Bug-Url::WARN, no bug url found, make sure header matches 'Bug-Url: ' 
and is a valid url.
* Check merged to previous::IGNORE, Not in stable branch (['ovirt-3.5', 
'ovirt-3.4', 'ovirt-3.3'])

-- 
To view, visit https://gerrit.ovirt.org/48052
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I52f11a1a10cae46773d05d0c09da80ad8eb3b772
Gerrit-PatchSet: 7
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Yaniv Bronhaim 
Gerrit-Reviewer: Jenkins CI
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]: Adding toolTests.py to python3 check modules

2015-11-04 Thread automation
automat...@ovirt.org has posted comments on this change.

Change subject: Adding toolTests.py to python3 check modules
..


Patch Set 6:

* Update tracker: IGNORE, no Bug-Url found
* Check Bug-Url::WARN, no bug url found, make sure header matches 'Bug-Url: ' 
and is a valid url.
* Check merged to previous::IGNORE, Not in stable branch (['ovirt-3.5', 
'ovirt-3.4', 'ovirt-3.3'])

-- 
To view, visit https://gerrit.ovirt.org/48052
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I52f11a1a10cae46773d05d0c09da80ad8eb3b772
Gerrit-PatchSet: 6
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Yaniv Bronhaim 
Gerrit-Reviewer: Jenkins CI
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]: Adding toolTests.py to python3 check modules

2015-11-04 Thread automation
automat...@ovirt.org has posted comments on this change.

Change subject: Adding toolTests.py to python3 check modules
..


Patch Set 2:

* Update tracker::IGNORE, no Bug-Url found
* Check Bug-Url::WARN, no bug url found, make sure header matches 'Bug-Url: ' 
and is a valid url.
* Check merged to previous::IGNORE, Not in stable branch (['ovirt-3.5', 
'ovirt-3.4', 'ovirt-3.3'])

-- 
To view, visit https://gerrit.ovirt.org/48052
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I52f11a1a10cae46773d05d0c09da80ad8eb3b772
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Yaniv Bronhaim 
Gerrit-Reviewer: Jenkins CI
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]: Adding toolTests.py to python3 check modules

2015-11-04 Thread automation
automat...@ovirt.org has posted comments on this change.

Change subject: Adding toolTests.py to python3 check modules
..


Patch Set 3:

* Update tracker::IGNORE, no Bug-Url found
* Check Bug-Url::WARN, no bug url found, make sure header matches 'Bug-Url: ' 
and is a valid url.
* Check merged to previous::IGNORE, Not in stable branch (['ovirt-3.5', 
'ovirt-3.4', 'ovirt-3.3'])

-- 
To view, visit https://gerrit.ovirt.org/48052
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I52f11a1a10cae46773d05d0c09da80ad8eb3b772
Gerrit-PatchSet: 3
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Yaniv Bronhaim 
Gerrit-Reviewer: Jenkins CI
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]: Adding toolTests.py to python3 check modules

2015-11-04 Thread automation
automat...@ovirt.org has posted comments on this change.

Change subject: Adding toolTests.py to python3 check modules
..


Patch Set 4:

* Update tracker::IGNORE, no Bug-Url found
* Check Bug-Url::WARN, no bug url found, make sure header matches 'Bug-Url: ' 
and is a valid url.
* Check merged to previous::IGNORE, Not in stable branch (['ovirt-3.5', 
'ovirt-3.4', 'ovirt-3.3'])

-- 
To view, visit https://gerrit.ovirt.org/48052
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I52f11a1a10cae46773d05d0c09da80ad8eb3b772
Gerrit-PatchSet: 4
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Yaniv Bronhaim 
Gerrit-Reviewer: Jenkins CI
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]: Adding toolTests.py to python3 check modules

2015-11-04 Thread automation
automat...@ovirt.org has posted comments on this change.

Change subject: Adding toolTests.py to python3 check modules
..


Patch Set 5:

* Update tracker::IGNORE, no Bug-Url found
* Check Bug-Url::WARN, no bug url found, make sure header matches 'Bug-Url: ' 
and is a valid url.
* Check merged to previous::IGNORE, Not in stable branch (['ovirt-3.5', 
'ovirt-3.4', 'ovirt-3.3'])

-- 
To view, visit https://gerrit.ovirt.org/48052
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I52f11a1a10cae46773d05d0c09da80ad8eb3b772
Gerrit-PatchSet: 5
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Yaniv Bronhaim 
Gerrit-Reviewer: Jenkins CI
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]: Adding toolTests.py to python3 check modules

2015-11-04 Thread ybronhei
Yaniv Bronhaim has uploaded a new change for review.

Change subject: Adding toolTests.py to python3 check modules
..

Adding toolTests.py to python3 check modules

Change-Id: I52f11a1a10cae46773d05d0c09da80ad8eb3b772
Signed-off-by: Yaniv Bronhaim 
---
M lib/vdsm/tool/configfile.py
M tests/Makefile.am
2 files changed, 3 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/52/48052/1

diff --git a/lib/vdsm/tool/configfile.py b/lib/vdsm/tool/configfile.py
index 26ec114..0c58205 100644
--- a/lib/vdsm/tool/configfile.py
+++ b/lib/vdsm/tool/configfile.py
@@ -18,12 +18,12 @@
 #
 
 from __future__ import absolute_import
-import ConfigParser
 import functools
 import os
 import tempfile
 import re
 import selinux
+from six.moves import configparser as ConfigParser
 import io
 
 from .. import utils
@@ -263,5 +263,5 @@
 def read(self, path):
 with open(path, 'r') as f:
 return self.wrapped.readfp(
-io.StringIO(u'[root]\n' + f.read().decode())
+io.StringIO(u'[root]\n' + f.read())
 )
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 205289e..3b1f8bf 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -30,6 +30,7 @@
apiData.py \
cmdutilsTests.py \
concurrentTests.py \
+   toolTests.py \
$(NULL)
 
 device_modules = \


-- 
To view, visit https://gerrit.ovirt.org/48052
To unsubscribe, visit https://gerrit.ovirt.org/settings

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


Change in vdsm[master]: Adding toolTests.py to python3 check modules

2015-11-04 Thread automation
automat...@ovirt.org has posted comments on this change.

Change subject: Adding toolTests.py to python3 check modules
..


Patch Set 1:

* Update tracker::IGNORE, no Bug-Url found
* Check Bug-Url::WARN, no bug url found, make sure header matches 'Bug-Url: ' 
and is a valid url.
* Check merged to previous::IGNORE, Not in stable branch (['ovirt-3.5', 
'ovirt-3.4', 'ovirt-3.3'])

-- 
To view, visit https://gerrit.ovirt.org/48052
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I52f11a1a10cae46773d05d0c09da80ad8eb3b772
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Yaniv Bronhaim 
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