various path stubs: re-export to reduce duplication (#5382)

Co-authored-by: hauntsaninja <>
Co-authored-by: Akuli <akuviljanen17@gmail.com>
This commit is contained in:
Shantanu
2021-05-10 22:27:13 -07:00
committed by GitHub
parent 0ac3531a93
commit a91c89ea94
7 changed files with 164 additions and 349 deletions

View File

@@ -1,7 +1,6 @@
import os
import sys
from _typeshed import AnyPath, BytesPath, StrPath
from genericpath import exists as exists
from typing import Any, AnyStr, Callable, List, Optional, Sequence, Text, Tuple, TypeVar, overload
_T = TypeVar("_T")
@@ -40,6 +39,7 @@ else:
# Also, in Python 2 mixed sequences of Text and bytes results in either Text or bytes
# So, fall back to Any
def commonprefix(m: Sequence[AnyPath]) -> Any: ...
def exists(path: AnyPath) -> bool: ...
def lexists(path: AnyPath) -> bool: ...
# These return float if os.stat_float_times() == True,