Skip to content

Fix incomplete typehinting for PathLike #1474

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Aug 8, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
fix: incorrect PathLike corrected
Signed-off-by: Predeactor <predeactor0@gmail.com>
  • Loading branch information
Predeactor committed Aug 7, 2022
commit 2303971c73f4ceda1d2d50e55a7c9d99864b883e
4 changes: 2 additions & 2 deletions git/types.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,10 @@


if sys.version_info[:2] < (3, 9):
PathLike = Union[str, os.PathLike[str]]
PathLike = Union[str, os.PathLike]
else:
# os.PathLike only becomes subscriptable from Python 3.9 onwards
PathLike = Union[str, bytes, os.PathLike[str], os.PathLike[bytes]]
PathLike = Union[str, os.PathLike[str]]

if TYPE_CHECKING:
from git.repo import Repo
Expand Down