alephdata / aleph

Search and browse documents and data; find the people and companies you look for.
http://docs.aleph.occrp.org
MIT License
1.97k stars 263 forks source link

Exit op_index early in Aleph Worker #3781

Closed catileptic closed 3 weeks ago

catileptic commented 3 weeks ago

This hotfix addresses the following stacktrace:

Traceback (most recent call last):
  File "/aleph/aleph/worker.py", line 146, in periodic
    self.run_indexing_batches()
  File "/aleph/aleph/worker.py", line 208, in run_indexing_batches
    op_index(collection_id, batch, worker=self)
  File "/aleph/aleph/worker.py", line 45, in op_index
    index_many(collection, sync=sync, tasks=batch)
  File "/aleph/aleph/logic/processing.py", line 22, in index_many
    aggregator = get_aggregator(collection)
  File "/aleph/aleph/logic/aggregator.py", line 14, in get_aggregator
    dataset = get_aggregator_name(collection)
  File "/aleph/aleph/logic/aggregator.py", line 9, in get_aggregator_name
    return "collection_%s" % collection.id
AttributeError: 'NoneType' object has no attribute 'id'"