D3354: hgweb: inform hgweb.hgweb() entrypoint that paths should be bytes

durin42 (Augie Fackler) phabricator at mercurial-scm.org
Sat Apr 14 04:32:31 UTC 2018


durin42 created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.

REPOSITORY
  rHG Mercurial

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

AFFECTED FILES
  mercurial/hgweb/__init__.py

CHANGE DETAILS

diff --git a/mercurial/hgweb/__init__.py b/mercurial/hgweb/__init__.py
--- a/mercurial/hgweb/__init__.py
+++ b/mercurial/hgweb/__init__.py
@@ -38,7 +38,7 @@
     - list of virtual:real tuples (multi-repo view)
     '''
 
-    if ((isinstance(config, str) and not os.path.isdir(config)) or
+    if ((isinstance(config, bytes) and not os.path.isdir(config)) or
         isinstance(config, dict) or isinstance(config, list)):
         # create a multi-dir interface
         return hgwebdir_mod.hgwebdir(config, baseui=baseui)



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


More information about the Mercurial-devel mailing list