3636
3737# typing-------------------------------------------------------
3838
39- from typing import Any , Callable , Dict , Iterator , Optional , TYPE_CHECKING , Union , cast , overload
39+ from typing import Any , Callable , Dict , Iterator , List , Optional , TYPE_CHECKING , Union , cast , overload
4040
41- from git .types import PathLike , Literal
41+ from git .types import PathLike , Literal , TBD
4242
4343if TYPE_CHECKING :
4444 from git .repo .base import Repo
@@ -666,7 +666,7 @@ def rename(self, new_name: str) -> 'Remote':
666666
667667 return self
668668
669- def update (self , ** kwargs ) :
669+ def update (self , ** kwargs : Any ) -> 'Remote' :
670670 """Fetch all changes for this remote, including new branches which will
671671 be forced in ( in case your local remote branch is not part the new remote branches
672672 ancestry anymore ).
@@ -680,7 +680,8 @@ def update(self, **kwargs):
680680 self .repo .git .remote (scmd , self .name , ** kwargs )
681681 return self
682682
683- def _get_fetch_info_from_stderr (self , proc , progress ):
683+ def _get_fetch_info_from_stderr (self , proc : TBD ,
684+ progress : Union [Callable [..., Any ], RemoteProgress , None ]) -> IterableList :
684685 progress = to_progress_instance (progress )
685686
686687 # skip first line as it is some remote info we are not interested in
@@ -739,7 +740,8 @@ def _get_fetch_info_from_stderr(self, proc, progress):
739740 log .warning ("Git informed while fetching: %s" , err_line .strip ())
740741 return output
741742
742- def _get_push_info (self , proc , progress ):
743+ def _get_push_info (self , proc : TBD ,
744+ progress : Union [Callable [..., Any ], RemoteProgress , None ]) -> List [PushInfo ]:
743745 progress = to_progress_instance (progress )
744746
745747 # read progress information from stderr
@@ -749,7 +751,7 @@ def _get_push_info(self, proc, progress):
749751 progress_handler = progress .new_message_handler ()
750752 output = []
751753
752- def stdout_handler (line ) :
754+ def stdout_handler (line : str ) -> None :
753755 try :
754756 output .append (PushInfo ._from_line (self , line ))
755757 except ValueError :
0 commit comments