Patchwork D9518: wireprotov2: re-add tuple around `bundle2` check

login
register
mail settings
Submitter phabricator
Date Dec. 4, 2020, 11:43 a.m.
Message ID <differential-rev-PHID-DREV-6zvv5xuw43czkcmgla2e-req@mercurial-scm.org>
Download mbox | patch
Permalink /patch/47801/
State Superseded
Headers show

Comments

phabricator - Dec. 4, 2020, 11:43 a.m.
Alphare created this revision.
Herald added a reviewer: hg-reviewers.
Herald added a subscriber: mercurial-patches.

REVISION SUMMARY
  I stumbled upon this while looking for the current (v1) `capable` method. It
  looks like 9c2c77c73f23 <https://phab.mercurial-scm.org/rHG9c2c77c73f234dd7ac369ee39aec6d87d63e3b1a> accidentally removed the comma, turning the tuple into
  a simple parenthesis expression.
  
  This has not been detected since wireproto2 is not in use AFAIK.

REPOSITORY
  rHG Mercurial

BRANCH
  stable

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

AFFECTED FILES
  mercurial/httppeer.py

CHANGE DETAILS




To: Alphare, #hg-reviewers
Cc: mercurial-patches, mercurial-devel

Patch

diff --git a/mercurial/httppeer.py b/mercurial/httppeer.py
--- a/mercurial/httppeer.py
+++ b/mercurial/httppeer.py
@@ -892,7 +892,7 @@ 
             return True
 
         # Other concepts.
-        if name in b'bundle2':
+        if name in (b'bundle2',):
             return True
 
         # Alias command-* to presence of command of that name.