b&w_logo Created with Sketch.
  • Get Started
  • Contact
  • Sign up
  • Sign in

sharks

get started

guide

features

syntax

 

monkeys

mods

REST API

 

platypuses

github

blueprints

tickets

 

everyone

support

ideas

contact

license

 

 
 
ACCOUNT INFO DELIVERY FAILED

Support Ticket

+status
help edit more_horiz
answered
+tag
help edit more_horiz
accounts
 
help edit more_horiz
+issues

The previous post: Error signing up: No project exists with the given API key  was pretty full...

I added smtp settings to wagn.rb to make the email function work. Then I was able to receive the email with title "xxx signed up for My Wagn" , but when I invited this user xxx, he will never receive the invitation email. So he could never get his password... The steps what I did and messages from console are attached in example

Did I overlook anything? Thanks inadvance!

help edit more_horiz
+example

(1) added smtp settings to wagn.rb:

ActionMailer::Base.smtp_settings = {
  :address => "smtp.gmail.com",
  :port => 587,
  :authentication => :login,
  :enable_starttls_auto => true,
  :user_name => "no_reply@gmail.com",
  :password => "123456"
}

 

(2) user named test2 signed up:

msg from console:

Processing AccountController#signup (for 136.160.154.114 at 2011-02-10 21:07:36) [POST]
  Parameters: {"commit"=>"Submit", "content_to_replace"=>"<p>hi</p>", "card"=>{"name"=>"test2", "type"=>"InvitationRequest", "content"=>"<p>hi</p>"}, "element"=>"main-body", "user"=>{"email"=>"test2@gmail.com"}}
Sent mail to admin@mydomain.com
Redirected to http://xxx.com/wagn/Request_Sent
Completed in 2086ms (DB: 64) | 302 Found [http://xxx.com/account/signup]


Processing CardController#show (for 136.160.154.114 at 2011-02-10 21:07:38) [GET]
  Parameters: {"id"=>"Request_Sent"}
Rendering template within layouts/application
Completed in 239ms (View: 230, DB: 4) | 200 OK [http://xxx.com/wagn/Request_Sent]

 

(3) email was received in admin@mydomain.com

email title: test2 signed up for My Magn

content: test2 has requested an account on My Wagn

               [blablah...]

 

(4) login as admin and invite user test2:

msg from console:

Processing AccountController#accept (for 136.160.154.114 at 2011-02-10 21:19:54) [GET]
  Parameters: {"card"=>{"key"=>"test2"}}
Rendering template within layouts/application
Rendering account/invite
Completed in 250ms (View: 242, DB: 5) | 200 OK [http://xxx.com/account/accept?card%5Bkey%5D=test2]
ACCOUNT INFO DELIVERY FAILED:       
        //would this be the problem?
 {"subject"=>"welcome", "message"=>"hi"}

Processing CardController#show to css (for 136.160.154.114 at 2011-02-10 21:19:54) [GET]
  Parameters: {"id"=>"*css", "3074"=>nil}
Completed in 12ms (View: 0, DB: 2) | 200 OK [http://xxx.com/*css.css?3074]

Processing AccountController#accept (for 136.160.154.114 at 2011-02-10 21:20:03) [POST]
  Parameters: {"commit"=>"Invite", "card"=>{"key"=>"test2"}, "element"=>"main-body", "user"=>{"email"=>"test2@gmail.com"}, "email"=>{"subject"=>"welcome", "message"=>"hi"}}
Sent mail to test2@gmail.com
Redirected to http://xxx.com/wagn/Invite_Success
Completed in 768ms (DB: 68) | 302 Found [http://xxx.com/account/accept]

 

(5) But nothing received in test2@gmail.com. Of course it is a valid email address.

 
help edit more_horiz
+discussion

This problem also happens when "invite a friend". Got the same error"ACCOUNT INFO DELIVERY FAILED". I believe this is the reason why users can't receive invitation emails...

 

Processing AccountController#invite (for 136.160.128.175 at 2011-02-10 21:59:14) [GET]
Rendering template within layouts/application
Rendering account/invite
Completed in 251ms (View: 188, DB: 54) | 200 OK [http://xxx.com/account/invite]
ACCOUNT INFO DELIVERY FAILED:
 {"subject"=>"invite test4", "message"=>"hi"}


Processing CardController#show to css (for 136.160.128.175 at 2011-02-10 21:59:14) [GET]
  Parameters: {"id"=>"*css", "3074"=>nil}
Completed in 12ms (View: 0, DB: 2) | 200 OK [http://xxx.com/*css.css?3074]

Processing AccountController#invite (for 136.160.128.175 at 2011-02-10 21:59:43) [POST]
  Parameters: {"commit"=>"Invite", "card"=>{"name"=>"test4"}, "element"=>"main-body", "user"=>{"email"=>"test4@hotmail.com"}, "email"=>{"subject"=>"invite test4", "message"=>"hi"}}
Sent mail to test4@hotmail.com
Redirected to http://xxx.com/wagn/Invite_Success
Completed in 940ms (DB: 23) | 302 Found [http://xxx.com/account/invite]


Here are some things to check:

 

1. can you send email to this address through normal methods?

2. do you have a value for the card "*invite+*from". If so, is it a valid email?

3. does the account of the person inviting have a valid email associated with it?

4. do you have access to a mail log that could give more info about why that delivery failed?

 

You're correct that this is the relevant error. I'm disappointed that the error reporting is so sparse.

  --Ethan McCutchen.....Thu Feb 10 23:02:40 -0800 2011


1. yes. it is my email and i use it frequently

 

2. I can't find a card with name "*invite+*from"... I searched invite and got these cards including the key word "*invite":

"*invite+*thanks"

"*invite"

I can't find "*invite+*from" on wagn.org as well.

 

3. the email address associated with the card "*request+*to" can receive the signup request email. I mean I can receive email and know who signed up but only the users who request accounts or being invited by an inviter can not receive email. In this case they can't get their password so no one can sign in... It is strange because at least email address in card "*request+*to" works...

 

4. do i need to set up a mail server on my machine? I don't have a mail server setup on my machine, so I don't see anything in mail log.

I was using google mail server. These are what I added to wagn.rb as stated here http://www.wagn.org/wagn/Installation+mail_setup :

ActionMailer::Base.smtp_settings = {

:address => "smtp.gmail.com",

:port => 587,

:authentication => :login,

:enable_starttls_auto => true,

:user_name => "no_reply@gmail.com",

:password => "123456"

}

no_reply@gmail.com is a valid mail address. so after that I am able to receive email send from no_reply@gmail.com. I suppose users who signed up should also be able to receive emails from no_reply@gmail.com with their passwords, right?

  --evanyw.....Fri Feb 11 10:39:50 -0800 2011


Does the google mail server give you access to any sort of info about failed messages?

 

for #3, I meant the email associated with your account.

 

Try this:

 

go to app/models/user.rb and comment out or remove line 142, which reads:

 

rescue; warn("ACCOUNT INFO DELIVERY FAILED: #{args.inspect}")

 

this will give you a bigger, louder error when you do the same thing, but maybe it will be more informative

  --Ethan McCutchen.....Fri Feb 11 11:10:40 -0800 2011


Yes! I was thinking to comment out that err msg but didnot find it :(

Below are the msg from console:

 

1) before commenting out line 142:

Processing AccountController#accept (for 216.230.102.66 at 2011-02-11 19:55:55) [GET]
  Parameters: {"card"=>{"key"=>"test3"}}
Rendering template within layouts/application
Rendering account/invite
Completed in 275ms (View: 237, DB: 5) | 200 OK [http://xx.com/account/accept?card%5Bkey%5D=test3]
ACCOUNT INFO DELIVERY FAILED:
 {"subject"=>"welcome", "message"=>""}

Processing CardController#show to css (for 216.230.102.66 at 2011-02-11 19:55:56) [GET]
  Parameters: {"3885"=>nil, "id"=>"*css"}
Completed in 13ms (View: 0, DB: 2) | 200 OK [http://xx.com/*css.css?3885]

Processing AccountController#accept (for 216.230.102.66 at 2011-02-11 19:56:00) [POST]
  Parameters: {"commit"=>"Invite", "card"=>{"key"=>"test3"}, "element"=>"main-body", "user"=>{"email"=>"test3@gmail.com"}, "email"=>{"subject"=>"welcome", "message"=>""}}
Sent mail to test3@gmail.com
Redirected to http://xx.com/wagn/Invite_Success
Completed in 879ms (DB: 52) | 302 Found [http://xx.com/account/accept]

 

2) after commenting out line 142:

Processing AccountController#accept (for 216.230.102.66 at 2011-02-11 19:57:54) [GET]
  Parameters: {"card"=>{"key"=>"test4"}}
Rendering template within layouts/application
Rendering account/invite
Completed in 409ms (View: 375, DB: 5) | 200 OK [http://xx.com/account/accept?card%5Bkey%5D=test4]

Processing CardController#show to css (for 216.230.102.66 at 2011-02-11 19:57:54) [GET]
  Parameters: {"3885"=>nil, "id"=>"*css"}
Completed in 33ms (View: 0, DB: 22) | 200 OK [http://xx.com/*css.css?3885]

Processing AccountController#accept (for 216.230.102.66 at 2011-02-11 19:57:58) [POST]
  Parameters: {"commit"=>"Invite", "card"=>{"key"=>"test4"}, "element"=>"main-body", "user"=>{"email"=>"test4@gmail.com"}, "email"=>{"subject"=>"welcome", "message"=>""}}
Sent mail to test4@gmail.com

Net::SMTPFatalError (555 5.5.2 Syntax error. p13sm798224qcu.29
):
  /opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/1.8/net/smtp.rb:930:in `check_response'
  /opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/1.8/net/smtp.rb:899:in `getok'
  /opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/1.8/net/smtp.rb:828:in `mailfrom'
  /opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/1.8/net/smtp.rb:653:in `sendmail'
  /opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/1.8/net/smtp.rb:526:in `start'
  app/models/user.rb:141:in `send_account_info'
  app/models/user.rb:133:in `accept'
  app/controllers/account_controller.rb:52:in `accept'
  /opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/1.8/webrick/httpserver.rb:104:in `service'
  /opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/1.8/webrick/httpserver.rb:65:in `run'
  /opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/1.8/webrick/server.rb:173:in `start_thread'
  /opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/1.8/webrick/server.rb:162:in `start'
  /opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/1.8/webrick/server.rb:162:in `start_thread'
  /opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/1.8/webrick/server.rb:95:in `start'
  /opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/1.8/webrick/server.rb:92:in `each'
  /opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/1.8/webrick/server.rb:92:in `start'
  /opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/1.8/webrick/server.rb:23:in `start'
  /opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/1.8/webrick/server.rb:82:in `start'

Rendering /root/wagn/public/500.html (500 Internal Server Error)

 

I searched online, and found some one said,

"The from line is the problem. The Net::SMTP library was recently changed

so it adds angle brackets to your sender, so you cannot have any in your

string."

 

I don't know if it is the same reason.

Thanks!

  --evanyw.....Fri Feb 11 12:12:42 -0800 2011


that's probably the problem. If you don't want to mess with that library, you can try changing line 11 of app/models/mailer.rb from

 

 

from (System.setting('*invite+*from') || "#{from_name} <#{from_user.email}>")

 

to:

 

 

from (System.setting('*invite+*from') || from_user.email )

  --Ethan McCutchen.....Fri Feb 11 15:14:59 -0800 2011


Thanks. It works! I remember you said you will add code to stop starting hoptoad automatically. Will it be on the next version? Thanks for your help!

  --evanyw.....Fri Feb 11 20:32:50 -0800 2011


That's the plan, yes. See stop requiring hoptoad.

  --John Abbe.....Fri Feb 11 20:45:06 -0800 2011


It may not get into 1.5.2, but should be in 1.5.3, which is going to be a much smaller, quicker-to-come-out release.

  --Ethan McCutchen.....Sun Feb 13 12:01:26 -0800 2011

keyboard_arrow_up open_in_new edit more_horiz