This is an archive of the discontinued Mercurial Phabricator instance.

py3: use bytes in place of basestring
ClosedPublic

Authored by pulkit on Nov 29 2017, 6:09 PM.

Details

Summary

All strings in mercurial must be bytes so we can easily replace basestring with
bytes.

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.Nov 29 2017, 6:09 PM
yuja requested changes to this revision.Nov 30 2017, 7:16 AM
yuja added a subscriber: yuja.

Testing a unicode string is probably wrong since almost all "strings" in Mercurial
must be bytes. Perhaps these basestrings can be replaced with bytes.

This revision now requires changes to proceed.Nov 30 2017, 7:16 AM
pulkit edited the summary of this revision. (Show Details)Dec 1 2017, 9:13 AM
pulkit retitled this revision from py3: add pycompat.basestring and use it to py3: use bytes in place of basestring.
pulkit updated this revision to Diff 4048.
yuja accepted this revision.Dec 1 2017, 9:56 PM
This revision is now accepted and ready to land.Dec 1 2017, 9:56 PM
This revision was automatically updated to reflect the committed changes.