diff options
author | Santos Gallegos <santos_g@outlook.com> | 2018-12-23 21:28:17 -0500 |
---|---|---|
committer | Sebastian Thiel <byronimo@gmail.com> | 2019-07-20 19:48:09 +0800 |
commit | a77a17f16ff59f717e5c281ab4189b8f67e25f53 (patch) | |
tree | 659aa3768f95545b9dca77ca64c0c286453703da | |
parent | 21b176732ba16379d57f53e956456bc2c5970baf (diff) | |
download | gitpython-a77a17f16ff59f717e5c281ab4189b8f67e25f53.tar.gz |
Skip on keyerror
-rw-r--r-- | git/objects/submodule/base.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/git/objects/submodule/base.py b/git/objects/submodule/base.py index 446c88fc..a75826eb 100644 --- a/git/objects/submodule/base.py +++ b/git/objects/submodule/base.py @@ -1184,8 +1184,9 @@ class Submodule(IndexObject, Iterable, Traversable): entry = index.entries[index.entry_key(p, 0)] sm = Submodule(repo, entry.binsha, entry.mode, entry.path) except KeyError: - raise InvalidGitRepositoryError( - "Gitmodule path %r did not exist in revision of parent commit %s" % (p, parent_commit)) + # The submodule doesn't exist, probably it wasn't + # removed from the .gitmodules file. + continue # END handle keyerror # END handle critical error |