Cannot send e-mail with rails 2.3.4(I could with 2

2020-05-02 02:47发布

I'm working with ruby on rails 2.3.4 and I yesterday I found out I cannot send emails any more.

The email-related credentials are ok because I could send emails until I upgraded my rails version about two weeks ago.

The error message I get is the following:

ArgumentError in UsersController#create

wrong # of arguments(3 for 2)

D:/Proyectos/Cursometro/www/vendor/plugins/action_mailer_tls/lib/smtp_tls.rb:8:in `check_auth_args'
D:/Proyectos/Cursometro/www/vendor/plugins/action_mailer_tls/lib/smtp_tls.rb:8:in `do_start'
C:/Program Files (x86)/NetBeans 6.8/ruby2/jruby-1.4.0/lib/ruby/1.8/net/smtp.rb:525:in `start'
C:/Program Files (x86)/NetBeans 6.8/ruby2/jruby-1.4.0/lib/ruby/gems/1.8/gems/actionmailer-2.3.4/lib/action_mailer/base.rb:682:in `perform_delivery_smtp'
C:/Program Files (x86)/NetBeans 6.8/ruby2/jruby-1.4.0/lib/ruby/gems/1.8/gems/actionmailer-2.3.4/lib/action_mailer/base.rb:523:in `deliver!'
C:/Program Files (x86)/NetBeans 6.8/ruby2/jruby-1.4.0/lib/ruby/gems/1.8/gems/actionmailer-2.3.4/lib/action_mailer/base.rb:395:in `method_missing'
D:/Proyectos/Cursometro/www/app/models/user_observer.rb:3:in `after_create'
D:/Proyectos/Cursometro/www/app/controllers/users_controller.rb:221:in `create_new_user'
D:/Proyectos/Cursometro/www/app/controllers/users_controller.rb:101:in `create'

Please, help!

2条回答
放我归山
2楼-- · 2020-05-02 03:26

I guess this was happening due to a conflict between my gems environments. I adjusted some things and now it's solved.

查看更多
Explosion°爆炸
3楼-- · 2020-05-02 03:31

Based on the stack trace, it looks like you have a plugin action_mailer_tls that is not working with 2.3.4. You may be required to update that.

You may also want to upgrade to at least Rails 2.3.5 as that was current for some time, or Rails 2.3.8 which is the new current release. If you're going to invest the time to troubleshoot an upgrade, might as well kick it as far forward as you can.

查看更多
登录 后发表回答