This is an archive of the discontinued Mercurial Phabricator instance.

montone: fix addition to list by using .append() instead of '+'
ClosedPublic

Authored by pulkit on Jan 29 2019, 5:27 PM.

Diff Detail

Repository
rHG Mercurial
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

pulkit created this revision.Jan 29 2019, 5:27 PM
yuja added a subscriber: yuja.Jan 30 2019, 7:21 AM
command.append('l')
for arg in args:
  • command += "%d:%s" % (len(arg), arg)

+ command += pycompat.bytestr("%d:%s" % (len(arg), arg))

It's okay, but I think the original code would mean to do command.append(...).

command.append('e')
command = ''.join(command)
pulkit retitled this revision from py3: use pycompat.bytestr() so that slicing does not result in ascii values to montone: fix addition to list by using .append() instead of '+'.Feb 1 2019, 6:31 PM
pulkit updated this revision to Diff 13677.
This revision was automatically updated to reflect the committed changes.