Skip to content

Commit 3c8cbe9

Browse files
committed
Mention collections.abc for Sequence
In the deprecation comment for importing Sequence from the top level git module. Although the git module imports it from typing, collections.abc.Sequence supports __class_getitem__ since Python 3.9 (and typing.Sequence is actually itself deprecated since then).
1 parent c8ad3a3 commit 3c8cbe9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

git/__init__.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@
5858
"RepositoryDirtyError",
5959
"RootModule",
6060
"RootUpdateProgress",
61-
"Sequence", # Deprecated - import this from `typing` instead.
61+
"Sequence", # Deprecated - import from `typing`, or `collections.abc` in 3.9+.
6262
"StageType",
6363
"Stats",
6464
"Submodule",

0 commit comments

Comments
 (0)