Patchwork D6070: py3: use bytes instead of str in isinstance()

login
register
mail settings
Submitter phabricator
Date March 4, 2019, 10:04 p.m.
Message ID <differential-rev-PHID-DREV-mymckap3s36tsah6jemu-req@phab.mercurial-scm.org>
Download mbox | patch
Permalink /patch/39052/
State Superseded
Headers show

Comments

phabricator - March 4, 2019, 10:04 p.m.
pulkit created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.

REVISION SUMMARY
  We use bytes everywhere.

REPOSITORY
  rHG Mercurial

REVISION DETAIL
  https://phab.mercurial-scm.org/D6070

AFFECTED FILES
  mercurial/tags.py

CHANGE DETAILS




To: pulkit, #hg-reviewers
Cc: mercurial-devel

Patch

diff --git a/mercurial/tags.py b/mercurial/tags.py
--- a/mercurial/tags.py
+++ b/mercurial/tags.py
@@ -548,7 +548,7 @@ 
 
 def _tag(repo, names, node, message, local, user, date, extra=None,
          editor=False):
-    if isinstance(names, str):
+    if isinstance(names, bytes):
         names = (names,)
 
     branches = repo.branchmap()