code: def AddLabel(self, label):
      
      if not isinstance(label, py2to3.STRING_TYPES):
        raise TypeError('label is not a string type. Is {0:s}'.format(
            type(label)))
      if not self._VALID_LABEL_REGEX.match(label):
        raise ValueError((
            'Unsupported label: "{0:s}". A label must only consist of '
            'alphanumeric characters or underscores.').format(label))
  
      if label not in self.labels:
        self.labels.append(label)
docs: Adds a label to the event tag.
  
      Args:
        label (str): label.
  
      Raises:
        TypeError: if the label provided is not a string.
        ValueError: if a label is malformed.