def _raise_name_warning(self, node, node_type, name, confidence, warning='invalid-name'):
    type_label = HUMAN_READABLE_TYPES[node_type]
    hint = self._name_hints[node_type]
    if self.config.include_naming_hint:
        hint += (' (%r pattern)' % self._name_regexps[node_type].pattern)
    args = ((type_label.capitalize(), name, hint) if (warning == 'invalid-name') else (type_label.capitalize(), name))
    self.add_message(warning, node=node, args=args, confidence=confidence)
    self.stats[('badname_' + node_type)] += 1
def _raise_name_warning(self, node, node_type, name, confidence, warning='invalid-name'):
    type_label = HUMAN_READABLE_TYPES[node_type]
    hint = self._name_hints[node_type]
    if self.config.include_naming_hint:
        hint += (' (%r pattern)' % self._name_regexps[node_type].pattern)
    args = ((type_label.capitalize(), name, hint) if (warning == 'invalid-name') else (type_label.capitalize(), name))
    self.add_message(warning, node=node, args=args, confidence=confidence)
    self.stats[('badname_' + node_type)] += 1