Skip to content

Commit

Permalink
Use comment to specify the re.Pattern type
Browse files Browse the repository at this point in the history
  • Loading branch information
WangGithubUser committed Sep 15, 2023
1 parent 8717c8a commit dbb289a
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions client/configuration/search_path.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,9 @@

dist_info_in_root: Dict[str, List[str]] = {}

# pyre-fixme[5]: Globally accessible variable `_site_filter` has type `re.Pattern[str]` but no type is specified.
_site_filter = re.compile(r".*-([0-99]\.)*dist-info")
_site_filter = re.compile(r".*-([0-99]\.)*dist-info") # type: re.Pattern

Check failure

Code scanning / Pyre

Invalid type parameters Error

Invalid type parameters [24]: Generic type re.Pattern expects 1 type parameter.

# pyre-fixme[5]: Globally accessible variable `_PYCACHE` has type `re.Pattern[str]` but no type is specified.
_PYCACHE = re.compile("__pycache__(/)*.*")
_PYCACHE = re.compile("__pycache__(/)*.*") # type: re.Pattern

Check failure

Code scanning / Pyre

Invalid type parameters Error

Invalid type parameters [24]: Generic type re.Pattern expects 1 type parameter.


def _expand_relative_root(path: str, relative_root: str) -> str:
Expand Down

0 comments on commit dbb289a

Please sign in to comment.