check we don't delte anythin unintended

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)