File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change 2020from git .exc import (
2121 InvalidGitRepositoryError ,
2222 NoSuchPathError ,
23- RepositoryDirtyError
23+ RepositoryDirtyError ,
24+ BadName
2425)
2526from git .objects .base import IndexObject , Object
2627from git .objects .util import Traversable
@@ -1153,10 +1154,10 @@ def children(self):
11531154 @classmethod
11541155 def iter_items (cls , repo , parent_commit = 'HEAD' ):
11551156 """:return: iterator yielding Submodule instances available in the given repository"""
1156- pc = repo .commit (parent_commit ) # parent commit instance
11571157 try :
1158+ pc = repo .commit (parent_commit ) # parent commit instance
11581159 parser = cls ._config_parser (repo , pc , read_only = True )
1159- except IOError :
1160+ except ( IOError , BadName ) :
11601161 return
11611162 # END handle empty iterator
11621163
You can’t perform that action at this time.
0 commit comments