@classmethod
def _decode_channel_update_msg(cls, chan_upd_msg: bytes) -> Optional[Dict[(str, Any)]]:
    channel_update_as_received = chan_upd_msg
    channel_update_typed = (258 .to_bytes(length=2, byteorder='big') + channel_update_as_received)
    try:
        (message_type, payload) = decode_msg(channel_update_typed)
        if (payload['chain_hash'] != constants.net.rev_genesis_bytes()):
            raise Exception()
        payload['raw'] = channel_update_typed
        return payload
    except:
        try:
            (message_type, payload) = decode_msg(channel_update_as_received)
            if (payload['chain_hash'] != constants.net.rev_genesis_bytes()):
                raise Exception()
            payload['raw'] = channel_update_as_received
            return payload
        except:
            return None
@classmethod
def _decode_channel_update_msg(cls, chan_upd_msg: bytes) -> Optional[Dict[(str, Any)]]:
    channel_update_as_received = chan_upd_msg
    channel_update_typed = (258 .to_bytes(length=2, byteorder='big') + channel_update_as_received)
    try:
        (message_type, payload) = decode_msg(channel_update_typed)
        if (payload['chain_hash'] != constants.net.rev_genesis_bytes()):
            raise Exception()
        payload['raw'] = channel_update_typed
        return payload
    except:
        try:
            (message_type, payload) = decode_msg(channel_update_as_received)
            if (payload['chain_hash'] != constants.net.rev_genesis_bytes()):
                raise Exception()
            payload['raw'] = channel_update_as_received
            return payload
        except:
            return None