@@ -890,7 +890,7 @@ def blame(self, rev: Union[str, HEAD], file: str, incremental: bool = False, **k
890
890
commits : Dict [str , Commit ] = {}
891
891
blames : List [List [Commit | List [str | bytes ] | None ]] = []
892
892
893
- class InfoTC (TypedDict , total = False ):
893
+ class InfoTD (TypedDict , total = False ):
894
894
sha : str
895
895
id : str
896
896
filename : str
@@ -992,19 +992,20 @@ class InfoDC(Dict[str, Union[str, int]]):
992
992
commits [sha ] = c
993
993
blames [- 1 ][0 ] = c
994
994
# END if commit objects needs initial creation
995
- if blames [- 1 ][1 ] is not None :
996
- if not is_binary :
997
- if line_str and line_str [0 ] == '\t ' :
998
- line_str = line_str [1 :]
999
-
1000
- blames [- 1 ][1 ].append (line_str )
1001
- else :
1002
- # NOTE: We are actually parsing lines out of binary data, which can lead to the
1003
- # binary being split up along the newline separator. We will append this to the
1004
- # blame we are currently looking at, even though it should be concatenated with
1005
- # the last line we have seen.
1006
- blames [- 1 ][1 ].append (line_bytes )
995
+ if not is_binary :
996
+ if line_str and line_str [0 ] == '\t ' :
997
+ line_str = line_str [1 :]
998
+ line_AnyStr : str | bytes = line_str
999
+ else :
1000
+ line_AnyStr = line_bytes
1001
+ # NOTE: We are actually parsing lines out of binary data, which can lead to the
1002
+ # binary being split up along the newline separator. We will append this to the
1003
+ # blame we are currently looking at, even though it should be concatenated with
1004
+ # the last line we have seen.
1005
+
1007
1006
# end handle line contents
1007
+ if blames [- 1 ][1 ] is not None :
1008
+ blames [- 1 ][1 ].append (line_AnyStr )
1008
1009
1009
1010
info .id = sha
1010
1011
# END if we collected commit info
0 commit comments