<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:

def delete_log(self, log):
        '''check we don't delte anythin unintended'''
        if os.path.splitext(log)[-1] != '.log':
            raise Exception('File without .log was passed in for deletoin')
        with suppress(Exception):
            os.remove(log)