Iris, cannot send emails
  • Order of the Butterfly
    Order of the Butterfly
    emeck
    Posts: 173 from 2014/7/15
    Hello,

    I tried a clean setup with Iris beta 62 for imap. OAuth is not working for me. After clicking Allow/Agree to grant access to Iris I get this after sometime for yahoo:

    Code:
    Unable to open http://127.0.0.1/?code=CODEHERE&state=2E4E1574
    Error 7: Couldn't connect to server


    And for gmail:

    Code:
    Unable to open http://localhost:1985/?state=CODEHERE&scope=https://mail.google.com/
    Error 7: Couldn't connect to server


    Is it normal to point to localhost/127.0.0.1 when setting the accounts?

    Anyway, I decided to use the config from my other email clients, like SimpleMail which is working in the same machine. Now with Iris emails are stored locallly and all works fine, except I can't send mail from neither account. This is the Iris log when sending with yahoo account:

    Code:
    Connected to smtp.mail.yahoo.com
    Storing email in a remote folder...
    Email stored.
    Storing email in a remote folder...


    My setup for sending is

    Code:

    server: smtp.mail.yahoo.com
    port: 465
    security: TLS


    I have tried Authentication with password, GSSAPI, none and default and in all cases test ouputs Succes! But still can't send emails.

    Any ideas what is wrong?
    PowerBook 5.8 MorphOS 3.18
    Mac Mini MorphOS 3.18
  • »07.08.19 - 15:18
    Profile
  • MorphOS Developer
    jacadcaps
    Posts: 3108 from 2003/3/5
    From: Canada
    It looks like the local http server is failing for you for some reason. Using localhost IS normal for OAuth2 as this is the only way the authentication website can communicate with the mail app.

    If nothing else works, I'll build a debug-enabled binary for you.
  • »08.08.19 - 06:45
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    emeck
    Posts: 173 from 2014/7/15
    Quote:

    jacadcaps wrote:
    It looks like the local http server is failing for you for some reason. Using localhost IS normal for OAuth2 as this is the only way the authentication website can communicate with the mail app.

    Well, lo0 loopback didn't show in ifconfig, although it was active in Network prefs. Had to changed config to static ip to make it work. Now back to dhcp and loopback still there in ifconfig output.

    So, with that solved OAuth2 worked for both gmail and yahoo account..

    I even could send test emails between my accounts. But after closing and restarting Iris, sending doesnt work again. Message stays in Outgoing Mail folder although the log windows says:

    Code:

    Storing email in a remote folder...
    Email stored.
    PowerBook 5.8 MorphOS 3.18
    Mac Mini MorphOS 3.18
  • »08.08.19 - 10:15
    Profile
  • MorphOS Developer
    jacadcaps
    Posts: 3108 from 2003/3/5
    From: Canada
    OK, great that you've solved the local networking issue. I'll be sure to add some additional error reporting to Iris to deal with this.

    As for SMTP: could you run Iris from shell with TRACE NOSYNC parameters and email the log to me? This should give me some insight into what is failing for you.

    Note: the trace log contains no password nor email bodies, but it may contain email headers.
  • »08.08.19 - 10:57
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    emeck
    Posts: 173 from 2014/7/15
    Quote:

    jacadcaps wrote:
    OK, great that you've solved the local networking issue. I'll be sure to add some additional error reporting to Iris to deal with this.

    As for SMTP: could you run Iris from shell with TRACE NOSYNC parameters and email the log to me? This should give me some insight into what is failing for you.

    Note: the trace log contains no password nor email bodies, but it may contain email headers.


    How do I capture the log?

    I opened System log from Ambient's menu and set it to save to a file in RAM. Ran "Iris TRACE NOSYNC" from shell but nothing is captured in System log window and no file created in RAM.

    UPDATE: Got it! With log tool...
    UPDATE2: logs sent.

    [ Edited by emeck 08.08.2019 - 14:52 ]
    PowerBook 5.8 MorphOS 3.18
    Mac Mini MorphOS 3.18
  • »08.08.19 - 12:20
    Profile
  • MorphOS Developer
    jacadcaps
    Posts: 3108 from 2003/3/5
    From: Canada
    Sorry, should have been more specific.

    Edit: ok, looking at the log, it looks like the vmime library is failing to store the email in Drafts, so the whole process just stops there. While this is most likely a problem with the server itself (not following the spec), I'll try to add a workaround for it tonight.

    [ Edited by jacadcaps 08.08.2019 - 15:03 ]
  • »08.08.19 - 12:48
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    emeck
    Posts: 173 from 2014/7/15
    Great, hope it is not too difficult to fix.

    Just in case it may be relevant, when accessing yahoo mail through the web, I see a Drafts folder. But in my KMail and K-9 Mail clients it is named as Draft (singular). I know it is the same because I can see the draft email I left there with both clients (and the web).

    But in SimpleMail, I have an empty Drafts folder. I can see the one from yahoo server when reloading the list from server folders to subscribe, and it also is listed as Draft, but subscribing doesn't work.
    PowerBook 5.8 MorphOS 3.18
    Mac Mini MorphOS 3.18
  • »08.08.19 - 14:17
    Profile
  • MorphOS Developer
    jacadcaps
    Posts: 3108 from 2003/3/5
    From: Canada
    So I've tried sending an email from my Iris test Yahoo account and it went fine - no errors. It could be something with the email itself (and how it got encoded perhaps). If it's not something private, could you save it and send it as an attachment to me? Otherwise, just delete it and see if sending some simple test message works.
  • »09.08.19 - 18:55
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    emeck
    Posts: 173 from 2014/7/15
    Sorry, I deleted the email from Outgoing folder after I sent it with my phone. After that, I have reinstalled Iris 3 times and all failing mails where just test mails, with "test" as subject and body.

    I have reinstalled Iris las night again, just with my yahoo account and problem continues when sending emails.

    Is there a global config or cache file outside Iris folder that can be messing things?

    Also, after configuring the account, is it normal when using the test button to authenticate again through OWB?
    PowerBook 5.8 MorphOS 3.18
    Mac Mini MorphOS 3.18
  • »10.08.19 - 07:41
    Profile
  • MorphOS Developer
    jacadcaps
    Posts: 3108 from 2003/3/5
    From: Canada
    Quote:

    I have reinstalled Iris las night again, just with my yahoo account and problem continues when sending emails.


    Doubt it'd be any different. The more I think about this, this is likely related to some meta data of your email (like the header). Really odd stuff. Once an email has failed, please open cache/.outgoing in the Iris folder and send me the file(s). Best if you lha them.

    Quote:

    Is there a global config or cache file outside Iris folder that can be messing things?


    No.

    Quote:

    Also, after configuring the account, is it normal when using the test button to authenticate again through OWB?


    Yes, because the test re-authenticates everything via OAuth2.
  • »10.08.19 - 11:10
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    emeck
    Posts: 173 from 2014/7/15
    Quote:

    jacadcaps wrote:
    Doubt it'd be any different. The more I think about this, this is likely related to some meta data of your email (like the header). Really odd stuff. Once an email has failed, please open cache/.outgoing in the Iris folder and send me the file(s). Best if you lha them.



    Sent an lha with an outgoing email. It is the first I tried sending with a new yahoo account and it has the same problem. No other account configured right now with Iris.
    PowerBook 5.8 MorphOS 3.18
    Mac Mini MorphOS 3.18
  • »10.08.19 - 15:20
    Profile
  • MorphOS Developer
    jacadcaps
    Posts: 3108 from 2003/3/5
    From: Canada
    Yea, I'll make a new account myself and try to get a repro on this tonight.
  • »10.08.19 - 16:43
    Profile Visit Website
  • MorphOS Developer
    jacadcaps
    Posts: 3108 from 2003/3/5
    From: Canada
    Interesting. SMTP works with my old account yet fails with the one I've just created. Will get to the bottom of this.
  • »10.08.19 - 19:00
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    emeck
    Posts: 173 from 2014/7/15
    Quote:

    jacadcaps wrote:
    Interesting. SMTP works with my old account yet fails with the one I've just created. Will get to the bottom of this.


    It worked for me since the first release you made, and I just copied the new betas over the old ones. But I recently changed the HD so started from zero. I think I have a working Iris setup in the old HD. I can search and send any file you need if you want to compare config with my new setup using the same yahoo account.
    PowerBook 5.8 MorphOS 3.18
    Mac Mini MorphOS 3.18
  • »10.08.19 - 19:13
    Profile
  • MorphOS Developer
    jacadcaps
    Posts: 3108 from 2003/3/5
    From: Canada
    From what I was able to determine, yahoo is actively blocking SMTP on new accounts. Will be contacting their support about this...
  • »11.08.19 - 08:16
    Profile Visit Website