

def tunnel_destroy_handler(self, payload):
    ' Destroy tunnel (response side) '
    try:
        self.network.link_check(payload['to_rt_uuid'])
    except:
        raise Exception('ERROR_UNKNOWN_RUNTIME')
    try:
        tunnel = self.tunnels[payload['from_rt_uuid']][payload['tunnel_id']]
    except:
        raise Exception('ERROR_UNKNOWN_TUNNEL')
        _log.analyze(self.rt_id, '+ ERROR_UNKNOWN_TUNNEL', payload, peer_node_id=payload['from_rt_uuid'])
    tunnel.close(local_only=True)
    ok = False
    try:
        ok = tunnel.down_handler()
    except:
        pass
    msg = {
        'cmd': 'REPLY',
        'msg_uuid': payload['msg_uuid'],
        'value': response.CalvinResponse(ok).encode(),
    }
    self.network.links[payload['from_rt_uuid']].send(msg)

dataset/ETHPy150Open EricssonResearch/calvin-base/calvin/runtime/north/calvin_proto.py CalvinProto.tunnel_destroy_handler/original