Issues an `inspectionType` service message to define generic properties of a given PyLint message type.
        :param utils.Message msg: a PyLint message
976611
def report_message_type(self, msg):
        
        desc = get_message_description(self.linter, msg.msg_id)
        self.tc.message('inspectionType', id=msg.msg_id, name=msg.symbol, description=desc, category=msg.category)
487345
def describe_message(message_definition):
    
    message_descriptor = MessageDescriptor()
    message_descriptor.name = message_definition.definition_name().split(
        '.')[-1]

    fields = sorted(message_definition.all_fields(),
                    key=lambda v: v.number)
    if fields:
        message_descriptor.fields = [describe_field(field) for field in fields]

    try:
        nested_messages = message_definition.__messages__
    except AttributeError:
        pass
    else:
        message_descriptors = []
        for name in nested_messages:
            value = getattr(message_definition, name)
            message_descriptors.append(describe_message(value))

        message_descriptor.message_types = message_descriptors

    try:
        nested_enums = message_definition.__enums__
    except AttributeError:
        pass
    else:
        enum_descriptors = []
        for name in nested_enums:
            value = getattr(message_definition, name)
            enum_descriptors.append(describe_enum(value))

        message_descriptor.enum_types = enum_descriptors

    return message_descriptor
122770
def error(self, msg: str) -> None:
        
        # noinspection PyUnresolvedReferences
        s = "{}: {}".format(self.fullname, msg)
        servicemanager.LogErrorMsg(s)
        if self.debugging:
            log.warning(s)
714001
def special_typechecking(value, msg):
    
    result = True
    if msg.DESCRIPTOR.name == TARGET:
        result &= special_target_typecheck(value)
    elif msg.DESCRIPTOR.name == PLUGIN:
        result &= special_plugin_checking(value)
    return result
745179
def message(self, message: types.Message):
        
        setattr(self, 'from_chat_id', message.chat.id)
        setattr(self, 'message_id', message.message_id)
        return self
711794
def _warn(message, warn_type='user'):
    
    w_id = message.split('[', 1)[1].split(']', 1)[0]  # get ID from string
    if warn_type in SPACY_WARNING_TYPES and w_id not in SPACY_WARNING_IGNORE:
        category = WARNINGS[warn_type]
        stack = inspect.stack()[-1]
        with warnings.catch_warnings():
            if SPACY_WARNING_FILTER:
                warnings.simplefilter(SPACY_WARNING_FILTER, category)
            warnings.warn_explicit(message, category, stack[1], stack[2])
453273
def check_message(keywords, message):
    
    exc_type, exc_value, exc_traceback = sys.exc_info()
    if set(str(exc_value).split(" ")).issuperset(set(keywords)):
        exc_value.message = message
        raise
1163401
def load(cls, bmessage):
        
        message_dict = msgpack.loads(bmessage, encoding="utf8", use_list=False)

        try:
            obj = MessageMeta._registered_messages[message_dict["type"]].__new__(MessageMeta._registered_messages[message_dict["type"]])
            object.__setattr__(obj, "__dict__", message_dict)
        except:
            raise TypeError("Unknown message type") from None

        if not obj._verify():  # pylint: disable=protected-access
            raise TypeError("Invalid message content")

        return obj
1044378
def handle(self, msg_type):
        

        def wrap(callback):
            self._handlers[msg_type] = callback
            return callback

        return wrap
269006
def get_message_type(message):
        
        for msg_type in MessageType.FIELDS:
            if Message.is_type(msg_type, message):
                return msg_type

        return MessageType.UNKNOWN
359056
def from_message(cls, message):
        
        type_ = message.get_text()
        return cls(type_=type_, blob=message.asbytes())
812980
protected boolean checkSupportedMessageTypes(Message msg) {
        if (msg instanceof TextMessage) {
            return true;
        } else {
            try {
                log.error("Unsupported message type: " + msg.getJMSType());
            } catch (JMSException ignore) {
            }
            sendToInvalidMessageQueue(msg);
            return false;
        }
    }
1248595
def _verified_message_type_from_id(message_type_id):
    # type: (int) -> ObjectType
    
    try:
        return ObjectType(message_type_id)
    except ValueError as error:
        raise NotSupportedError("Unsupported type {} discovered in data stream".format(message_type_id), error)
665219
function Message(type, contents) {
  if (false === (this instanceof Message)) throw new Error('new operator required');
  if ('undefined' == typeof type) throw new Error('message type required');
  if (!contains(Message.getTypes(), type)) throw new Error('Invalid message type: ' + type);
  this.type = type;
  this.contents = contents;
}
606677
def unpack_messages(self, partitions_msgs):
        

        for pmsg in partitions_msgs:
            key = pmsg['_key']
            partition = pmsg['partition']
            offset = pmsg['offset']
            msg = pmsg.pop('message')
            if msg:
                try:
                    record = self.deserialize_fun(msg)
                except Exception as e:
                    log.error('Error unpacking record at partition:offset {}:{} (key: {} : {})'.format(partition, offset, key, repr(e)))
                    continue
                else:
                    if isinstance(record, dict):
                        pmsg['record'] = record
                        yield pmsg
                    else:
                        log.info('Record {} has wrong type'.format(key))
            else:
                yield pmsg
509543
def msg(message):
    
    to_stdout(" --- {message}".format(message=message))
    if _logger:
        _logger.info(message)
685991
def format_message_type(message_type):
    
    if message_type == MsgType.NOT_SET:
        return "NOT_SET"
    elif message_type == MsgType.ACK:
        return "ACK"
    elif message_type == MsgType.JOIN:
        return "JOIN"
    elif message_type == MsgType.UNJOIN:
        return "UNJOIN"
    elif message_type == MsgType.CONFIG:
        return "CONFIG"
    elif message_type == MsgType.UPDATE:
        return "UPDATE"
    elif message_type == MsgType.DATA:
        return "DATA"
    else:
        return u"{}".format(message_type)