Ido Barkan has posted comments on this change. Change subject: networkTests: normalize dict keys and values to str (from unicode) ......................................................................
Patch Set 3: Code-Review-1 (1 comment) https://gerrit.ovirt.org/#/c/45201/3/lib/vdsm/netconfpersistence.py File lib/vdsm/netconfpersistence.py: Line 428: return dict( Line 429: (k, v) for k, v in opts.iteritems() if v != defaults.get(k)) Line 430: Line 431: @staticmethod Line 432: def normalize_unicode(self, networks_or_bonds): a nice trick to do so is json.loads(json.dumps(d)) Line 433: for attributes in networks_or_bonds.itervalues(): Line 434: for attr, value in dict(attributes).iteritems(): Line 435: if isinstance(attr, unicode): Line 436: if isinstance(value, unicode): -- To view, visit https://gerrit.ovirt.org/45201 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I6362e04189f134ad27ee4e3c1991020b2eee91aa Gerrit-PatchSet: 3 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Ondřej Svoboda <[email protected]> Gerrit-Reviewer: Dan Kenigsberg <[email protected]> Gerrit-Reviewer: Ido Barkan <[email protected]> Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Ondřej Svoboda <[email protected]> Gerrit-Reviewer: Petr Horáček <[email protected]> Gerrit-Reviewer: [email protected] Gerrit-HasComments: Yes _______________________________________________ vdsm-patches mailing list [email protected] https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
