comparison mercurial/branchmap.py @ 36396:743b293c3ca0

py3: use util.forcebytestr to convert error messages to bytes Differential Revision: https://phab.mercurial-scm.org/D2421
author Pulkit Goyal <7895pulkit@gmail.com>
date Sat, 24 Feb 2018 16:20:15 +0530
parents 46260fac5563
children d139eb308358
comparison
equal deleted inserted replaced
36395:fb7897e53d49 36396:743b293c3ca0
253 repo.ui.log('branchcache', 253 repo.ui.log('branchcache',
254 'wrote %s branch cache with %d labels and %d nodes\n', 254 'wrote %s branch cache with %d labels and %d nodes\n',
255 repo.filtername, len(self), nodecount) 255 repo.filtername, len(self), nodecount)
256 except (IOError, OSError, error.Abort) as inst: 256 except (IOError, OSError, error.Abort) as inst:
257 # Abort may be raised by read only opener, so log and continue 257 # Abort may be raised by read only opener, so log and continue
258 repo.ui.debug("couldn't write branch cache: %s\n" % inst) 258 repo.ui.debug("couldn't write branch cache: %s\n" %
259 util.forcebytestr(inst))
259 260
260 def update(self, repo, revgen): 261 def update(self, repo, revgen):
261 """Given a branchhead cache, self, that may have extra nodes or be 262 """Given a branchhead cache, self, that may have extra nodes or be
262 missing heads, and a generator of nodes that are strictly a superset of 263 missing heads, and a generator of nodes that are strictly a superset of
263 heads missing, this function updates self to be correct. 264 heads missing, this function updates self to be correct.