Patchwork [stable] context: add missing b prefix

login
register
mail settings
Submitter Augie Fackler
Date July 30, 2018, 1:50 p.m.
Message ID <71d6886d27cf94dc45d0.1532958643@augie-macbookpro2.roam.corp.google.com>
Download mbox | patch
Permalink /patch/32968/
State Accepted
Headers show

Comments

Augie Fackler - July 30, 2018, 1:50 p.m.
# HG changeset patch
# User Augie Fackler <augie@google.com>
# Date 1532958632 14400
#      Mon Jul 30 09:50:32 2018 -0400
# Branch stable
# Node ID 71d6886d27cf94dc45d0e495c3912d3c6e74794e
# Parent  a8bfaf592033a8c10e5c8bf8d5edda90ba45c611
context: add missing b prefix

This fixes
  mercurial/context.py:593: SyntaxError: cannot mix bytes and nonbytes literals (context.py, line 593)
in Python 3.
Yuya Nishihara - July 30, 2018, 2:20 p.m.
On Mon, 30 Jul 2018 09:50:43 -0400, Augie Fackler wrote:
> # HG changeset patch
> # User Augie Fackler <augie@google.com>
> # Date 1532958632 14400
> #      Mon Jul 30 09:50:32 2018 -0400
> # Branch stable
> # Node ID 71d6886d27cf94dc45d0e495c3912d3c6e74794e
> # Parent  a8bfaf592033a8c10e5c8bf8d5edda90ba45c611
> context: add missing b prefix

Queued, thanks.

Patch

diff --git a/mercurial/context.py b/mercurial/context.py
--- a/mercurial/context.py
+++ b/mercurial/context.py
@@ -591,7 +591,7 @@  class changectx(basectx):
 
     def descendant(self, other):
         msg = (b'ctx.descendant(other) is deprecated, '
-               'use ctx.isancestorof(other)')
+               b'use ctx.isancestorof(other)')
         self._repo.ui.deprecwarn(msg, b'4.7')
         return self.isancestorof(other)