Commit 8311839f authored by Gabriel Mazetto's avatar Gabriel Mazetto

Rescue from Geo::EmptyCloneUrlPrefixError in sync services

parent 169c894b
......@@ -18,7 +18,7 @@ module Geo
project.repository.fetch_geo_mirror(ssh_url_to_repo)
update_registry(:repository, finished_at: DateTime.now)
rescue Gitlab::Shell::Error => e
rescue Gitlab::Shell::Error, Geo::EmptyCloneUrlPrefixError => e
Rails.logger.error("#{self.class.name}: Error syncing repository for project #{project.path_with_namespace}: #{e}")
rescue Gitlab::Git::Repository::NoRepository => e
Rails.logger.error("#{self.class.name}: Error invalid repository for project #{project.path_with_namespace}: #{e}")
......
......@@ -17,7 +17,10 @@ module Geo
project.wiki.repository.fetch_geo_mirror(ssh_url_to_wiki)
update_registry(:wiki, finished_at: DateTime.now)
rescue Gitlab::Git::Repository::NoRepository, Gitlab::Shell::Error, ProjectWiki::CouldNotCreateWikiError => e
rescue Gitlab::Git::Repository::NoRepository,
Gitlab::Shell::Error,
ProjectWiki::CouldNotCreateWikiError,
Geo::EmptyCloneUrlPrefixError => e
Rails.logger.error("#{self.class.name}: Error syncing wiki repository for project #{project.path_with_namespace}: #{e}")
end
end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment