Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 5abcad0

Browse filesBrowse files
committed
Fix calling dict.iteritems().
1 parent 0cd4d84 commit 5abcad0
Copy full SHA for 5abcad0

File tree

Expand file treeCollapse file tree

1 file changed

+2
-2
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+2
-2
lines changed

‎MySQLdb/cursors.py

Copy file name to clipboardExpand all lines: MySQLdb/cursors.py
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ def execute(self, query, args=None):
190190

191191
if args is not None:
192192
if isinstance(args, dict):
193-
args = dict((key, db.literal(item)) for key, item in args.iteritems())
193+
args = dict((key, db.literal(item)) for key, item in args.items())
194194
else:
195195
args = tuple(map(db.literal, args))
196196
if not PY2 and isinstance(query, bytes):
@@ -261,7 +261,7 @@ def executemany(self, query, args):
261261
for a in args:
262262
if isinstance(a, dict):
263263
q.append(qv % dict((key, db.literal(item))
264-
for key, item in a.iteritems()))
264+
for key, item in a.items()))
265265
else:
266266
q.append(qv % tuple([db.literal(item) for item in a]))
267267
except TypeError as msg:

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.