mercurial/narrowspec.py
changeset 43117 8ff1ecfadcd1
parent 43089 c59eb1560c44
child 44563 1922694d638f
equal deleted inserted replaced
43116:defabf63e969 43117:8ff1ecfadcd1
   108     and patterns that are loaded from sources that use the internal,
   108     and patterns that are loaded from sources that use the internal,
   109     prefixed pattern representation (but can't necessarily be fully trusted).
   109     prefixed pattern representation (but can't necessarily be fully trusted).
   110     """
   110     """
   111     if not isinstance(pats, set):
   111     if not isinstance(pats, set):
   112         raise error.ProgrammingError(
   112         raise error.ProgrammingError(
   113             b'narrow patterns should be a set; ' b'got %r' % pats
   113             b'narrow patterns should be a set; got %r' % pats
   114         )
   114         )
   115 
   115 
   116     for pat in pats:
   116     for pat in pats:
   117         if not pat.startswith(VALID_PREFIXES):
   117         if not pat.startswith(VALID_PREFIXES):
   118             # Use a Mercurial exception because this can happen due to user
   118             # Use a Mercurial exception because this can happen due to user