From 11f996a096e43092da0c7b8cf5b9d7a19de57828 Mon Sep 17 00:00:00 2001 From: AUTOMATIC1111 <16777216c@gmail.com> Date: Tue, 25 Jul 2023 15:23:35 +0300 Subject: [PATCH] Merge pull request #11979 from AUTOMATIC1111/catch-exception-for-non-git-extensions catch exception for non git extensions --- modules/extensions.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/modules/extensions.py b/modules/extensions.py index c561159a..09d1e550 100644 --- a/modules/extensions.py +++ b/modules/extensions.py @@ -56,9 +56,11 @@ class Extension: self.do_read_info_from_repo() return self.to_dict() - - d = cache.cached_data_for_file('extensions-git', self.name, os.path.join(self.path, ".git"), read_from_repo) - self.from_dict(d) + try: + d = cache.cached_data_for_file('extensions-git', self.name, os.path.join(self.path, ".git"), read_from_repo) + self.from_dict(d) + except FileNotFoundError: + pass self.status = 'unknown' def do_read_info_from_repo(self):