Discussion:
[bug-mailutils] Unable to access gmail imap
Carlos Pita
2014-07-28 15:58:39 UTC
Permalink
Maybe it's my fault but I'm not able to tell what's wrong with the following:

movemail --set .tls.enable=true -p
'imap://carlosjosepita:***@imap.gmail.com:993' test

Cheers
--
Carlos
Carlos Pita
2014-07-28 16:20:25 UTC
Permalink
Ok, I got it working downgrading to 2.2 and following the instructions here:

https://github.com/ibvk/org-notes/blob/master/mailutils.org

That is:

movemail --tls 'imaps://carlosjosepita%40gmail.com:X
***@imap.gmail.com:993/INBOX' test

I think a note/example in the docs will be of great help.
Post by Carlos Pita
movemail --set .tls.enable=true -p
Cheers
--
Carlos
Sergey Poznyakoff
2014-08-05 07:23:28 UTC
Permalink
Post by Carlos Pita
I think a note/example in the docs will be of great help.
FWIW, it's documented in detail here:

http://mailutils.org/wiki/Fetching_Mail_with_Movemail

Regards,
Sergey
Carlos Pita
2014-08-05 21:16:46 UTC
Permalink
Hi Sergey,

thank you very much for the fix, I tested the patched rmail.el with:

(setq rmail-primary-inbox-list
'("imaps://carlosjosepita%***@imap.gmail.com:993/INBOX"))
(setq rmail-pop-password-required t)
(setq rmail-preserve-inbox t)

And it worked just fine out of the box.

Have you write access to the emacs repo? Do you want me to attach your
patch to the bug report? Btw, my report is somewhat misguiding since
at first I thought the problem was a different, lower priority, one:
lack of support for imaps. It turned out to be a more severe issue so
it may be convenient to refile the bug with a new header and
description and invalidate the previous report.
Post by Sergey Poznyakoff
http://mailutils.org/wiki/Fetching_Mail_with_Movemail
I meant an example using imaps to connect gmail, as it's such a popular case.

Best regards
--
Carlos
Sergey Poznyakoff
2014-08-06 06:02:08 UTC
Permalink
Hi Carlos,
Post by Carlos Pita
And it worked just fine out of the box.
Great. Thanks for the info.
Post by Carlos Pita
Have you write access to the emacs repo?
I'll check if I have. In fact, it was me who added support for MU
movemail to rmail back in 2005, but I don't remember whether I'd been
committing to the repo directly or just sending patches to emacs-dev :)
Besides, they happened to change VCS engine twice since then.
Post by Carlos Pita
I meant an example using imaps to connect gmail, as it's such a popular case.
Ah, yes, you're right. I'll add it to the docs.

Regards,
Sergey

Sergey Poznyakoff
2014-07-29 04:02:34 UTC
Permalink
Hi Carlos,
Post by Carlos Pita
movemail --set .tls.enable=true -p
No, that's wrong. Google uses imaps, not imap. The correct way is:

movemail -p imaps://carlosjosepita:***@imap.gmail.com test

Regards,
Sergey
Carlos Pita
2014-07-29 04:16:04 UTC
Permalink
Yep, sadly rmail is not working with any protocol besides pop and
imap, so no rmail+gmail for now. Fortunately, it's a more or less
trivial bug while parsing the protocol prefix. I've reported it to
bug-gnu-emacs. Thanks, Carlos.
Post by Sergey Poznyakoff
Hi Carlos,
Post by Carlos Pita
movemail --set .tls.enable=true -p
Regards,
Sergey
Sergey Poznyakoff
2014-07-30 07:27:50 UTC
Permalink
Post by Carlos Pita
Yep, sadly rmail is not working with any protocol besides pop and
imap, so no rmail+gmail for now.
That's easy to fix. There are two possibilities:

1) Apply the patch (attachment 1) to your rmail.el file. Normally
it is gzipped and lives in /usr/share/emacs/VERSION/lisp/mail, so
you'll need to decompress it first,

or

2) Drop the fixed version of rmail.el (attachment 2) somewhere in
your load-path and make sure it is loaded instead of the shipped
one.

I'll update the docs submit the cumulative patch to emacs team later
today.

Regards,
Sergey
Jordi Mallach
2014-07-30 08:14:05 UTC
Permalink
El dc 30 de 07 de 2014 a les 10:27 +0300, en/na Sergey Poznyakoff va
Post by Sergey Poznyakoff
Post by Carlos Pita
Yep, sadly rmail is not working with any protocol besides pop and
imap, so no rmail+gmail for now.
1) Apply the patch (attachment 1) to your rmail.el file. Normally
it is gzipped and lives in /usr/share/emacs/VERSION/lisp/mail, so
you'll need to decompress it first,
Hm, isn't the pop proto hunk missing a "?" ?

- (if (string-equal proto "pop")
+ (if (string-match "pops" proto)

Jordi
--
Jordi Mallach PĂ©rez -- Debian developer http://www.debian.org/
***@sindominio.net ***@debian.org http://www.sindominio.net/
GnuPG public key information available at http://oskuro.net/
Sergey Poznyakoff
2014-07-30 11:38:23 UTC
Permalink
Post by Jordi Mallach
Hm, isn't the pop proto hunk missing a "?" ?
Yes, of course, it should have been

- (if (string-equal proto "pop")
+ (if (string-match "pops?" proto)

instead. Thanks, Jordi!

Regards,
Sergey
Carlos Pita
2014-07-30 13:23:18 UTC
Permalink
Hi guys, thanks for the patch, but notice that the bug is more general than
that, although still pretty simple to fix:

http://lists.gnu.org/archive/html/bug-gnu-emacs/2014-07/msg00867.html
http://lists.gnu.org/archive/html/bug-gnu-emacs/2014-07/msg00869.html

I find it a bit surprising that it has gone unnoticed all this time. Maybe
you could contribute you patch there :).

Regards
--
Carlos
Post by Sergey Poznyakoff
Post by Jordi Mallach
Hm, isn't the pop proto hunk missing a "?" ?
Yes, of course, it should have been
- (if (string-equal proto "pop")
+ (if (string-match "pops?" proto)
instead. Thanks, Jordi!
Regards,
Sergey
Carlos Pita
2014-07-31 22:49:58 UTC
Permalink
Hi guys,
Post by Carlos Pita
http://lists.gnu.org/archive/html/bug-gnu-emacs/2014-07/msg00867.html
http://lists.gnu.org/archive/html/bug-gnu-emacs/2014-07/msg00869.html
have you been able to take a look at this? I'm no elisp guru but I guess
that with a little effort I would be able to fix the issue. But if you
prefer to do that yourself, go ahead. Or I could write a patch and then
you will review and submit it. Just tell me. I think it's a pretty severe
bug, as rmail really cripples movemail here. It would be nice to get
this fixed before the next pretest.

Best regards
--
Carlos
Sergey Poznyakoff
2014-08-05 07:12:42 UTC
Permalink
Hi Carlos,
Post by Carlos Pita
have you been able to take a look at this?
Please find attached a fixed version (att#1) and a patch (att#2). I'd
appreciate your feedback.

Regards,
Sergey
Loading...