Mercurial > libervia-backend
changeset 397:ccfd69d090c3
core: workaround to avoid a bug in item detection on jabber.fr. Need more investigation with jabber.fr admins (may be a bug in ejabberd)
author | Goffi <goffi@goffi.org> |
---|---|
date | Wed, 05 Oct 2011 16:48:25 +0200 (2011-10-05) |
parents | cecd22241d56 |
children | cb0285372818 |
files | src/core/sat_main.py |
diffstat | 1 files changed, 7 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/core/sat_main.py Tue Oct 04 23:43:06 2011 +0200 +++ b/src/core/sat_main.py Wed Oct 05 16:48:25 2011 +0200 @@ -507,10 +507,16 @@ debug (_('Identity added: (%(category)s,%(type)s) ==> %(entity)s [%(profile)s]') % { 'category':category, 'type':type, 'entity':entity, 'profile':profile}) self.memory.addServerIdentity(category, type, entity, profile) + + def _errback(result, entity, profile): + warning(_("Can't get information on identity [%(entity)s] for profile [%(profile)s]") % {'entity':entity, 'profile': profile}) defer_list = [] for item in disco_result._items: - defer_list.append(disco_client.requestInfo(item.entity).addCallback(_check_entity_cb, item.entity, profile)) + if item.entity.full().count('.') == 1: #XXX: workaround for a bug on jabberfr, tmp + continue + args = [item.entity, profile] + defer_list.append(disco_client.requestInfo(item.entity).addCallbacks(_check_entity_cb, _errback, args, None, args)) defer.DeferredList(defer_list).chainDeferred(initialized)