As a sanity check I've created a test job triggered by SCM that always
fails. The email-ext configuration has a failure trigger that is set to
send emails to culprits (the trigger was added directly to job config.xml
due to JENKINS-19585).

When I commit to SCM the job is triggered, but there is no email sent.
The debug console output has this:

Checking for pre-build
Executing pre-build step
Checking if email needs to be generated
No emails were triggered.
[workspace] $ cmd /c call
C:\Users\dresnick\AppData\Local\Temp\hudson8412388181330090933.bat

C:\Users\dresnick\.jenkins\jobs\email-test\workspace>exit 1
Build step 'Execute Windows batch command' marked build as failure
Checking for post-build
Performing post-build step
Checking if email needs to be generated
Email was triggered for: Failure
Sending email for trigger: Failure
NOT overriding default server settings, using Mailer to create session
messageContentType = text/plain; charset=UTF-8
Successfully created MimeMessage
An attempt to send an e-mail to empty list of recipients, ignored.
Some error occured trying to send the email...check the Jenkins log
Finished: FAILURE


The job is configured like the below. Am I missing something here, or
should I open a bug for this?

    <hudson.plugins.emailext.ExtendedEmailPublisher plugin="email-ext@2.33">
      <recipientList>$DEFAULT_RECIPIENTS</recipientList>
      <configuredTriggers>
        <hudson.plugins.emailext.plugins.trigger.FailureTrigger>
          <email>
            <recipientList></recipientList>
            <subject>$PROJECT_DEFAULT_SUBJECT</subject>
            <body>$PROJECT_DEFAULT_CONTENT</body>
            <sendToDevelopers>false</sendToDevelopers>
            <sendToRequester>false</sendToRequester>
            <sendToCulprits>true</sendToCulprits>
            <sendToRecipientList>false</sendToRecipientList>
            <attachmentsPattern></attachmentsPattern>
            <attachBuildLog>false</attachBuildLog>
            <compressBuildLog>false</compressBuildLog>
            <replyTo>$PROJECT_DEFAULT_REPLYTO</replyTo>
            <contentType>project</contentType>
          </email>
        </hudson.plugins.emailext.plugins.trigger.FailureTrigger>
      </configuredTriggers>
      <contentType>default</contentType>
      <defaultSubject>$DEFAULT_SUBJECT</defaultSubject>
      <defaultContent>$DEFAULT_CONTENT</defaultContent>
      <attachmentsPattern></attachmentsPattern>
      <presendScript>$DEFAULT_PRESEND_SCRIPT</presendScript>
      <attachBuildLog>false</attachBuildLog>
      <compressBuildLog>false</compressBuildLog>
      <replyTo>$DEFAULT_REPLYTO</replyTo>
      <saveOutput>false</saveOutput>
    </hudson.plugins.emailext.ExtendedEmailPublisher>

- David

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to