# HG changeset patch # User Sylvain Thénault # Date 1395301552 -3600 # Node ID 9fb2f15d5e850545f809aa6f4028c21e83a77937 # Parent e5a80bd337e83740471bf63a3c9c6e40dc2befe9 [sources] Skip problematic sources when starting shell instead of crashing. Closes #3670208 At least this gives an opportunity to fix the problem in using c-c shell, which is currently not possible because it crashes during initialization. Notice that since sources are copy based, it should not be a problem at all to have some disabled, beside for services such as authentication sources as ldapfeed. diff -r e5a80bd337e8 -r 9fb2f15d5e85 server/repository.py --- a/server/repository.py Fri Apr 04 17:32:12 2014 +0200 +++ b/server/repository.py Thu Mar 20 08:45:52 2014 +0100 @@ -282,8 +282,14 @@ clear_cache(self, 'source_defs') def add_source(self, sourceent): - source = self.get_source(sourceent.type, sourceent.name, - sourceent.host_config, sourceent.eid) + try: + source = self.get_source(sourceent.type, sourceent.name, + sourceent.host_config, sourceent.eid) + except RuntimeError: + if self.config.repairing: + self.exception('cant setup source %s, skipped', sourceent.name) + return + raise self.sources_by_eid[sourceent.eid] = source self.sources_by_uri[sourceent.name] = source if self.config.source_enabled(source):