Skip to content

Commit b9d4c6a

Browse files
committed
Fix Repo.__repr__ when subclassed
1 parent f7cff58 commit b9d4c6a

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

Diff for: git/repo/base.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1064,7 +1064,8 @@ def has_separate_working_tree(self):
10641064
rev_parse = rev_parse
10651065

10661066
def __repr__(self):
1067-
return '<git.Repo "%s">' % self.git_dir
1067+
clazz = self.__class__
1068+
return '<%s.%s "%s">' % (clazz.__module__, clazz.__name__, self.git_dir)
10681069

10691070
def currently_rebasing_on(self):
10701071
"""

0 commit comments

Comments
 (0)