From 158b3c75d9c621820e3f34b8567acb7898dccce4 Mon Sep 17 00:00:00 2001 From: Yobmod Date: Sun, 16 May 2021 18:48:32 +0100 Subject: Add types to index.typ.py --- git/index/base.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'git/index/base.py') diff --git a/git/index/base.py b/git/index/base.py index d939e1af..54f73617 100644 --- a/git/index/base.py +++ b/git/index/base.py @@ -79,6 +79,8 @@ if TYPE_CHECKING: StageType = int Treeish = Union[Tree, Commit, str, bytes] +# ------------------------------------------------------------------------------------ + __all__ = ('IndexFile', 'CheckoutError') @@ -287,8 +289,9 @@ class IndexFile(LazyMixin, diff.Diffable, Serializable): inst = cls(repo) # convert to entries dict - entries = dict(zip(((e.path, e.stage) for e in base_entries), - (IndexEntry.from_base(e) for e in base_entries))) + entries = dict(zip( + ((e.path, e.stage) for e in base_entries), + (IndexEntry.from_base(e) for e in base_entries))) # type: Dict[Tuple[PathLike, int], IndexEntry] inst.entries = entries return inst -- cgit v1.2.1