def _message_valid(self, message):
        if not hasattr(message, '__iter__'):
            return False
        if not ('name' in message and 'value' in message or
                    ('id' in message and message in 'data') or
                    ('id' in message and 'bus' in message) or
                    'command_response' in message):
            return False
        return True
dataset/ETHPy150Open openxc/openxc-python/openxc/sources/base.py/BytestreamDataSource._message_valid/swapped operands of `in`