in src/es_pii_tool/redacters/index.py [0:0]
def verify_index(self):
"""Verify the index exists"""
# If the index name changed because of an ILM phase shift from hot to cold
# or cold to frozen, then we should verify the name change here. We should raise
# an exception if the name of the index changed or it disappeared.
if not api.verify_index(self.task.job.client, self.index):
msg = f'Halting execution: Index {self.index} changed or is missing.'
logger.critical(msg)
self.success = False
raise ValueError(msg, 'index not found as expected', self.index)