[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Conversation View
On Fri, Aug 20, 2010 at 12:07 PM, Erik Hetzner <ehetzner@gmail.com> wrote:
> The real trouble is that we need to
> follow the trail of references up to the first message to really get
> the full thread, which entails a back-and-forth with the IMAP server.
AHA! So I was reading through your code and wondered about this bit:
> (defun egh:wl-all-folder ()
> "%xxx:xxx@xxx.com:993!")
>
> (defun egh:wl-summary-visit-conversation ()
> (interactive)
> (let* ((f (lambda (str)
> (mapcar (lambda (msgid)
> (substring msgid 1 -1))
> (split-string str " "))))
^^^
...because from looking at raw messages, I know that message ids in
"References:" are often split by all kinds of whitespace. In particular,
newlines are common. So then I traced through some of this code with Edebug
and discovered that...
> (msg (elmo-message-entity
> wl-summary-buffer-elmo-folder
> wl-summary-buffer-current-msg))
> (ids (append
> (funcall f (elmo-message-entity-field msg 'message-id))
> (funcall f (elmo-message-entity-field msg 'references)))))
^^^^^^^^^^^^^^^^^^^^^^^^^
...here, elmo was returning only the very last message-ID in all the entity's
References:, which was on a line by itself (maybe why you thought splitting
on spaces was OK?"). So I think we have an elmo bug that presumably
could be easily
fixed!
> (wl-summary-goto-folder-subr
> (concat
> "/"
> (mapconcat
> (lambda (ref)
> (concat "message-id:" ref
> "|references:" ref))
> ids "|")
> "/"
> (egh:wl-all-folder))
> 'update nil nil t)))
>
--
Dave Abrahams
BoostPro Computing
http://www.boostpro.com