[PATCH bootstrap] [py3] dict.iteritems() -> dict.items()

Philippe Pepiot philippe.pepiot at logilab.fr
Wed Jun 13 18:04:13 CEST 2018


# HG changeset patch
# User Philippe Pepiot <philippe.pepiot at logilab.fr>
# Date 1528905786 -7200
#      Wed Jun 13 18:03:06 2018 +0200
# Node ID d1ae659d45a2cc12de86032eb74d59c0d76266fc
# Parent  ee27da563be9e64112ffd6f587b7f4d87035655c
# Available At https://hg.logilab.org/review/cubes/bootstrap
#              hg pull https://hg.logilab.org/review/cubes/bootstrap -r d1ae659d45a2
# EXP-Topic py3
[py3] dict.iteritems() -> dict.items()

diff --git a/cubicweb_bootstrap/views/cwproperties.py b/cubicweb_bootstrap/views/cwproperties.py
--- a/cubicweb_bootstrap/views/cwproperties.py
+++ b/cubicweb_bootstrap/views/cwproperties.py
@@ -35,7 +35,7 @@ def wrap_grouped_form(self, group, label
     self.w(u'<div class="%s" id="fieldset_%s">' % (cssclass, group))
 
     sorted_objects = sorted((self._cw.__('%s_%s' % (group, o)), o, f)
-                            for o, f in objects.iteritems())
+                            for o, f in objects.items())
     for label, oid, form in sorted_objects:
         self.wrap_object_form(group, oid, label, form)
     self.w(u'</div>')
diff --git a/cubicweb_bootstrap/views/debug.py b/cubicweb_bootstrap/views/debug.py
--- a/cubicweb_bootstrap/views/debug.py
+++ b/cubicweb_bootstrap/views/debug.py
@@ -115,7 +115,7 @@ def call(self, **kwargs):
             continue
         self.w(u'<h3 id="%s">%s</h3>' % (key, key))
         if self._cw.vreg[key]:
-            values = sorted(self._cw.vreg[key].iteritems())
+            values = sorted(self._cw.vreg[key].items())
             self.wview('pyvaltable', pyvalue=[(key, xml_escape(repr(val)))
                                               for key, val in values])
         else:


More information about the cubicweb-devel mailing list