@@ -410,7 +410,7 @@ def raise_exc(e):
410410 # whose name contains wildcard characters.
411411 if abs_path not in resolved_paths :
412412 for f in self ._iter_expand_paths (glob .glob (abs_path )):
413- yield f .replace (rs , '' )
413+ yield str ( f ) .replace (rs , '' )
414414 continue
415415 # END glob handling
416416 try :
@@ -635,7 +635,7 @@ def _store_path(self, filepath: PathLike, fprogress: Callable) -> BaseIndexEntry
635635 @git_working_dir
636636 def _entries_for_paths (self , paths : List [str ], path_rewriter : Callable , fprogress : Callable ,
637637 entries : List [BaseIndexEntry ]) -> List [BaseIndexEntry ]:
638- entries_added = [] # type: List[BaseIndexEntry ]
638+ entries_added : List [ BaseIndexEntry ] = [ ]
639639 if path_rewriter :
640640 for path in paths :
641641 if osp .isabs (path ):
@@ -769,7 +769,7 @@ def add(self, items: Sequence[Union[PathLike, Blob, BaseIndexEntry, Submodule]],
769769 # automatically
770770 # paths can be git-added, for everything else we use git-update-index
771771 paths , entries = self ._preprocess_add_items (items )
772- entries_added = []
772+ entries_added : List [ BaseIndexEntry ] = []
773773 # This code needs a working tree, therefore we try not to run it unless required.
774774 # That way, we are OK on a bare repository as well.
775775 # If there are no paths, the rewriter has nothing to do either
0 commit comments