From: Benoît Pin Date: Tue, 24 Jun 2014 14:05:50 +0000 (+0200) Subject: bugfix. X-Git-Url: https://scm.cri.ensmp.fr/git/Plinn.git/commitdiff_plain/3292a62dac2b35937180dcf9dfcae565d7dea333?ds=sidebyside;hp=a35ff73524728da76bb6346dbc3c5da136903d99 bugfix. --- diff --git a/catalog.py b/catalog.py index d353d6d..1f08a83 100644 --- a/catalog.py +++ b/catalog.py @@ -117,13 +117,14 @@ class DelegatedCatalog(Catalog) : None signifie : pas de délégation, il faut continuer à interroger les autres index. IISet() vide : pas de résultat lors de la délégation, on peut arrêter la recherche. ''' - indexes = set(plan).intersection(set(self.zcat.delegatedIndexes)) + indexes = set(query.keys()).intersection(set(self.zcat.delegatedIndexes)) if not indexes : return None delegatedQuery = {} for i in indexes : delegatedQuery[i] = query.pop(i) - plan.remove(i) + try : plan.remove(i) + except ValueError : pass c = SolrConnection(self.zcat.solr_url) q =' AND '.join(['%s:"%s"' % item for item in delegatedQuery.items()]) resp = c.query(q, fields='id', rows=len(self))