def channels_for_peer(self, node_id):
    assert (type(node_id) is bytes)
    return {chan_id: chan for (chan_id, chan) in self.channels.items() if (chan.node_id == node_id)}
def channels_for_peer(self, node_id):
    assert (type(node_id) is bytes)
    return {chan_id: chan for (chan_id, chan) in self.channels.items() if (chan.node_id == node_id)}