@@ -82,16 +82,16 @@ class Diffable(object):
82
82
class Index (object ):
83
83
pass
84
84
85
- def _process_diff_args (self , args : List [Union [PathLike , 'Diffable' , Type ['Diffable.Index' ]]]
86
- ) -> List [Union [PathLike , 'Diffable' , Type ['Diffable.Index' ]]]:
85
+ def _process_diff_args (self , args : List [Union [str , 'Diffable' , Type ['Diffable.Index' ], object ]]
86
+ ) -> List [Union [str , 'Diffable' , Type ['Diffable.Index' ], object ]]:
87
87
"""
88
88
:return:
89
89
possibly altered version of the given args list.
90
90
Method is called right before git command execution.
91
91
Subclasses can use it to alter the behaviour of the superclass"""
92
92
return args
93
93
94
- def diff (self , other : Union [Type ['Index' ], 'Tree' , 'Commit' , None , str ] = Index , # object for git.NULL_TREE
94
+ def diff (self , other : Union [Type ['Index' ], 'Tree' , 'Commit' , None , str , object ] = Index ,
95
95
paths : Union [PathLike , List [PathLike ], Tuple [PathLike , ...], None ] = None ,
96
96
create_patch : bool = False , ** kwargs : Any ) -> 'DiffIndex' :
97
97
"""Creates diffs between two items being trees, trees and index or an
@@ -124,7 +124,7 @@ def diff(self, other: Union[Type['Index'], 'Tree', 'Commit', None, str] = Index,
124
124
:note:
125
125
On a bare repository, 'other' needs to be provided as Index or as
126
126
as Tree/Commit, or a git command error will occur"""
127
- args : List [Union [PathLike , Diffable , Type ['Diffable.Index' ]]] = []
127
+ args : List [Union [PathLike , Diffable , Type ['Diffable.Index' ], object ]] = []
128
128
args .append ("--abbrev=40" ) # we need full shas
129
129
args .append ("--full-index" ) # get full index paths, not only filenames
130
130
0 commit comments