ChiliProject is not maintained anymore. Please be advised that there will be no more updates.
We do not recommend that you setup new ChiliProject instances and we urge all existing users to migrate their data to a maintained system, e.g. Redmine. We will provide a migration script later. In the meantime, you can use the instructions by Christian Daehn.
Testing email in admin area doesn't work (Bug #824)
Description
I'm clicking http://host/admin/test_email, get successful message, but /usr/sbin/sendmail don't runs. But notification of the new materials are sent fine.
Related issues
duplicates Bug #762: "Send a test email" should override "don't notify of chan... | Ready for review | 2011-12-10 |
History
Updated by Vladislav Poluhin at 2012-01-11 02:41 am
My settings:
production: email_delivery: delivery_method: :async_sendmail raise_delivery_errors: true perform_deliveries: true
Updated by Holger Just at 2012-01-11 11:08 am
If you are using async_sendmail
or async_smtp
as the delivery method, there will always be a new thread created for delivering emails, even for the test email. Thus, the HTTP request handler which schedules the email creation has no way of knowing the result of the delivery as it has already finished once the email is delivered.
If you have issues, please consult either your mailserver log or (temporarily) use sendmail
or smtp
where delivery errors are actually handled and shown to the user. Currently there is no way around that, sorry.
Updated by Vladislav Poluhin at 2012-01-12 01:12 pm
But /usr/sbin/sendmail doesn't run when I press "Send test letter", in other cases everything is ok.
I can see in the logs when someone sends mail by using the /usr/sbin/sendmail:
Jan 11 10:20:10 localhost msmtp: host=smtp.gmail.com tls=on auth=on user=robot@u-mind.ru from=robot@u-mind.ru recipients=nuklea@gmail.com mailsize=669 smtpstatus=250 smtpmsg='250 2.0.0 OK 1326248410 fg16sm154515067bkb.16' exitcode=EX_OK Jan 11 10:36:03 localhost msmtp: host=smtp.gmail.com tls=on auth=on user=development@u-mind.ru from=development@u-mind.ru recipients=nuklea@gmail.com,strikes62@gmail.com mailsize=4005 smtpstatus=250 smtpmsg='250 2.0.0 OK 1326249363 t23sm135684798bkv.10' exitcode=EX_OK
Updated by Holger Just at 2012-01-16 12:53 pm
The way async_sendmail
and async_smtp
are implemented might cause problems in certain deployment options, especially when there is no persistent application Server. Please check if it works with just sendmail
. Also please tell us which plugins and which application server (passenger, thin, ...) you use.
- Status changed from Open to Needs more information
Updated by Kris Lou at 2012-01-16 11:05 pm
From my production.log:
Processing AdminController#test_email (for x.x.x.x at 2012-01-16 14:58:06) [GET] Parameters: {"action"=>"test_email", "controller"=>"admin"} Sending email notification to: Redirected to http://redmine.themusiclink.net/settings/edit?tab=notifications Completed in 49ms (DB: 1) | 302 Found [http://redmine.themusiclink.net/admin/test_email]
The test email apparently doesn't send/populate if the user has "I don't want to be notified of changes that I make myself" checked. Removing this option temporarily results in the test email.
Either way, its somewhat counterintuitive.
This is with SMTP to an internal sendmail relay, CP 2.5 with only WikiNG installed.
Updated by Kris Lou at 2012-01-18 09:19 pm
Sorry, my comment is a duplicate of #762.
Issues with async may still exist (needs more information).
Updated by Vladislav Poluhin at 2012-01-19 03:15 pm
Holger Just wrote:
The way
async_sendmail
andasync_smtp
are implemented might cause problems in certain deployment options, especially when there is no persistent application Server. Please check if it works with justsendmail
. Also please tell us which plugins and which application server (passenger, thin, ...) you use.
I'm using redmine-bitbucket-0.1.2
(https://bitbucket.org/nolith/redmine-bitbucket) and unicorn_rails
as app server. Nothing changed after replace :async_sendmail
to :sendmail
.
Updated by Vladislav Poluhin at 2012-01-19 03:21 pm
I'm grepping logs:
$ grep '"test_email' -A3 -B1 log/production.log -- :async_sendmail Processing AdminController#test_email (for 192.168.0.8 at 2012-01-12 21:07:20) [GET] Parameters: {"controller"=>"admin", "action"=>"test_email"} Sending email notification to: Redirected to http://dev.u-mind.ru/settings/edit?tab=notifications Completed in 29ms (DB: 2) | 302 Found [http://dev.u-mind.ru/admin/test_email] -- :sendmail Processing AdminController#test_email (for 192.168.0.8 at 2012-01-19 23:09:38) [GET] Parameters: {"controller"=>"admin", "action"=>"test_email"} Sending email notification to: Redirected to http://dev.u-mind.ru/settings/edit?tab=notifications Completed in 121ms (DB: 2) | 302 Found [http://dev.u-mind.ru/admin/test_email]
Updated by Holger Just at 2012-01-24 11:47 am
Currently, the test email is only send if you have disabled the option to not receive changes you made yourself on your My Account page.
The flash will be green, but the email will not be send if that option is activated. Could you please check that?
Updated by Vladislav Poluhin at 2012-01-24 12:00 pm
Yep, if "don't receive changes you made" is checked — email will not be send.
Updated by Rocco Stanzione at 2012-01-25 08:03 pm
I think this duplicates #762
Updated by Holger Just at 2012-01-25 08:04 pm
It turned out it is. Thanks.
- Status changed from Needs more information to Duplicate