code: def untag(self, querystring, tags, afterwards=None):
          
          if self.ro:
              raise DatabaseROError()
          self.writequeue.append(('untag', afterwards, querystring, tags))
docs: removes tags from messages that match `querystring`.
          This appends an untag operation to the write queue and raises
          :exc:`~errors.DatabaseROError` if in read only mode.
  
          :param querystring: notmuch search string
          :type querystring: str
          :param tags: a list of tags to be added
          :type tags: list of str
          :param afterwards: callback that gets called after successful
                             application of this tagging operation
          :type afterwards: callable
          :exception: :exc:`~errors.DatabaseROError`
  
          .. note::
              This only adds the requested operation to the write queue.
              You need to call :meth:`DBManager.flush` to actually write out.