num_searches = 0
for assignment in yield_token_assignments(query):
searches.extend(search_builder.build(assignment))
- log().table_dump('Searches for assignment',
- _dump_searches(searches, query, num_searches))
+ if num_searches < len(searches):
+ log().table_dump('Searches for assignment',
+ _dump_searches(searches, query, num_searches))
num_searches = len(searches)
searches.sort(key=lambda s: s.penalty)
return f'{c[0]}^{c[1]}'
for search in searches[start:]:
- fields = ('name_lookups', 'name_ranking', 'countries', 'housenumbers',
+ fields = ('lookups', 'rankings', 'countries', 'housenumbers',
'postcodes', 'qualifier')
iters = itertools.zip_longest([f"{search.penalty:.3g}"],
*(getattr(search, attr, []) for attr in fields),