[PATCH 1/3] pwclient: dict.iteritems() is deprecated in Python 3
Mike Frysinger
vapier at gentoo.org
Sat Oct 17 10:16:06 AEDT 2015
On 16 Oct 2015 16:12, Brian Norris wrote:
> Just use dict.items(), since there are few fields and we don't really
> care about the extra copying.
Reviewed-by: Mike Frysinger <vapier at chromium.org>
> --- a/patchwork/bin/pwclient
> +++ b/patchwork/bin/pwclient
> @@ -237,7 +237,7 @@ def action_info(rpc, patch_id):
> s = "Information for patch id %d" % (patch_id)
> print(s)
> print('-' * len(s))
> - for key, value in sorted(patch.iteritems()):
> + for key, value in sorted(patch.items()):
the fact we run it through sorted means we end up with the full list
eventually anyways, so i doubt we'd notice the overhead w/py2.
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.ozlabs.org/pipermail/patchwork/attachments/20151016/0af6e395/attachment.sig>
More information about the Patchwork
mailing list