[JIRA] (JENKINS-16332) Leading and trailing underscores are added to commiters email address,

216 views
Skip to first unread message

s.a.grigoriev@gmail.com (JIRA)

unread,
Jan 13, 2013, 5:16:53 PM1/13/13
to jenkinsc...@googlegroups.com
Issue Type: Bug Bug
Assignee: Jesse Glick
Components: mercurial
Created: 13/Jan/13 10:15 PM
Description:

Jenkins email-ext plugin fails to send email, the error is

Failed to create e-mail address for devel...@xxx.net
Failed to create e-mail address for devel...@xxx.net
Failed to create e-mail address for devel...@xxx.net
Failed to create e-mail address for devel...@xxx.net

(Names and domain are changed)

Jan 13, 2013 7:15:56 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string ``devel...@xxx.net''
at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
at javax.mail.internet.InternetAddress.<init>(InternetAddress.java:111)
at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:60)
at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:687)
at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:508)
at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:297)
at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:289)
at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:249)
at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810)
at hudson.model.AbstractBuild$AbstractBuildExecution.perJan 13, 2013 7:15:56 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string ``y...@worldticket.net''
at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
at javax.mail.internet.InternetAddress.<init>(InternetAddress.java:111)
at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:60)
at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:687)
at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:508)
at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:297)
at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:289)
at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:249)
at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810)
at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:785)
at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
at hudson.model.Run.execute(Run.java:1587)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
at hudson.model.ResourceController.execute(ResourceController.java:88)
at hudson.model.Executor.run(Executor.java:236)formAllBuildSteps(AbstractBuild.java:785)
at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
at hudson.model.Run.execute(Run.java:1587)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
at hudson.model.ResourceController.execute(ResourceController.java:88)
at hudson.model.Executor.run(Executor.java:236)

First I thought is the problem is in email-ext plugin, but when I went to "Changes" tab and opened the page

https://devel.2mba.dk/jenkins/user/Developer%201%20__dev...@xxx.net_/

it showed

Jenkins User Id: Developer 1 devel...@xxx.net

For unknown reason Jenkins adds a leading and trailing underscore to email address

Project: Jenkins
Priority: Blocker Blocker
Reporter: Sergey Grigoriev
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira

s.a.grigoriev@gmail.com (JIRA)

unread,
Jan 13, 2013, 5:16:53 PM1/13/13
to jenkinsc...@googlegroups.com
Change By: Sergey Grigoriev (13/Jan/13 10:16 PM)
Description:
Jenkins email-ext plugin fails to send email, the error is

Failed to create e-mail address for _deve...@xxx.net_
Failed to create e-mail address for _deve...@xxx.net_
Failed to create e-mail address for _deve...@xxx.net_
Failed to create e-mail address for _deve...@xxx.net_


(Names and domain are changed)

Jan 13, 2013 7:15:56 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string ``_deve...@xxx.net_''

        at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
        at javax.mail.internet.InternetAddress.<init>(InternetAddress.java:111)
        at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:60)
        at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:687)
        at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:508)
        at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:297)
        at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:289)
        at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:249)
        at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perJan 13, 2013 7:15:56 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string ``_y...@worldticket.net_''

        at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
        at javax.mail.internet.InternetAddress.<init>(InternetAddress.java:111)
        at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:60)
        at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:687)
        at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:508)
        at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:297)
        at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:289)
        at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:249)
        at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810)
        at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:785)
        at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
        at hudson.model.Run.execute(Run.java:1587)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
        at hudson.model.ResourceController.execute(ResourceController.java:88)
        at hudson.model.Executor.run(Executor.java:236)formAllBuildSteps(AbstractBuild.java:785)
        at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
        at hudson.model.Run.execute(Run.java:1587)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
        at hudson.model.ResourceController.execute(ResourceController.java:88)
        at hudson.model.Executor.run(Executor.java:236)

First I thought is the problem is in email-ext plugin, but when I went to "Changes" tab and opened the page

https http :// devel.2mba.dk host /jenkins/user/Developer%201%20__dev...@xxx.net_/
(hostname changed)

it showed

Jenkins User Id: Developer 1 _deve...@xxx.net_


For unknown reason Jenkins adds a leading and trailing underscore to email address


s.a.grigoriev@gmail.com (JIRA)

unread,
Jan 13, 2013, 5:20:53 PM1/13/13
to jenkinsc...@googlegroups.com
Change By: Sergey Grigoriev (13/Jan/13 10:18 PM)
Description:
Jenkins email-ext plugin fails to send email, the error is

Failed to create e-mail address for _deve...@xxx.net_
Failed to create e-mail address for _deve...@xxx.net_
Failed to create e-mail address for _deve...@xxx.net_
Failed to create e-mail address for _deve...@xxx.net_


(Names and domain are changed)

Jan 13, 2013 7:15:56 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string ``_deve...@xxx.net_''

        at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
        at javax.mail.internet.InternetAddress.<init>(InternetAddress.java:111)
        at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:60)
        at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:687)
        at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:508)
        at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:297)
        at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:289)
        at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:249)
        at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perJan 13, 2013 7:15:56 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string ``_y...@worldticket.net_''

        at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
        at javax.mail.internet.InternetAddress.<init>(InternetAddress.java:111)
        at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:60)
        at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:687)
        at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:508)
        at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:297)
        at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:289)
        at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:249)
        at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810)
        at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:785)
        at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
        at hudson.model.Run.execute(Run.java:1587)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
        at hudson.model.ResourceController.execute(ResourceController.java:88)
        at hudson.model.Executor.run(Executor.java:236)formAllBuildSteps(AbstractBuild.java:785)
        at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
        at hudson.model.Run.execute(Run.java:1587)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
        at hudson.model.ResourceController.execute(ResourceController.java:88)
        at hudson.model.Executor.run(Executor.java:236)

First I thought is the problem is in email-ext plugin, but when I went to "Changes" tab and opened the page

http://host/jenkins/user/Developer%201%20__dev...@xxx.net_/
(hostname changed)

it showed

Jenkins User Id: Developer 1 _deve...@xxx.net_


For unknown reason Jenkins adds a leading and trailing underscore to email address

Environment
Jenkins ver. 1.498
Jenkins Mercurial plugin 1.42
Jenkins Email Extension Plugin 2.25


s.a.grigoriev@gmail.com (JIRA)

unread,
Jan 13, 2013, 5:20:53 PM1/13/13
to jenkinsc...@googlegroups.com
Change By: Sergey Grigoriev (13/Jan/13 10:19 PM)
Description:
Jenkins email-ext plugin fails to send email, the error is

Failed to create e-mail address for _deve...@xxx.net_
Failed to create e-mail address for _deve...@xxx.net_
Failed to create e-mail address for _deve...@xxx.net_
Failed to create e-mail address for _deve...@xxx.net_


(Names and domain are changed)

Jan 13, 2013 7:15:56 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string ``_deve...@xxx.net_''

        at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
        at javax.mail.internet.InternetAddress.<init>(InternetAddress.java:111)
        at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:60)
        at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:687)
        at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:508)
        at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:297)
        at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:289)
        at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:249)
        at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perJan 13, 2013 7:15:56 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string ``_y...@worldticket.net_''

        at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
        at javax.mail.internet.InternetAddress.<init>(InternetAddress.java:111)
        at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:60)
        at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:687)
        at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:508)
        at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:297)
        at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:289)
        at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:249)
        at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810)
        at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:785)
        at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
        at hudson.model.Run.execute(Run.java:1587)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
        at hudson.model.ResourceController.execute(ResourceController.java:88)
        at hudson.model.Executor.run(Executor.java:236)formAllBuildSteps(AbstractBuild.java:785)
        at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
        at hudson.model.Run.execute(Run.java:1587)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
        at hudson.model.ResourceController.execute(ResourceController.java:88)
        at hudson.model.Executor.run(Executor.java:236)

First I thought is the problem is in email-ext plugin, but when I went to "Changes" tab and opened the page

http://host/jenkins/user/Developer%201%20__dev...@xxx.net_/
(hostname changed)

it showed

Jenkins User Id: Developer 1
 _developer1  __developer1 @xxx. net_ net__

For unknown reason Jenkins adds a leading and trailing underscore to email address

Environment
Jenkins ver. 1.498
Jenkins Mercurial plugin 1.42
Jenkins Email Extension Plugin 2.25


s.a.grigoriev@gmail.com (JIRA)

unread,
Jan 13, 2013, 5:20:53 PM1/13/13
to jenkinsc...@googlegroups.com
Change By: Sergey Grigoriev (13/Jan/13 10:20 PM)
Description:
Jenkins email-ext plugin fails to send email, the error is

Failed to create e-mail address for  _developer1  __developer1 @xxx. net_ net__
Failed to create e-mail address for
 _developer2  __developer2 @xxx. net_ net__
Failed to create e-mail address for
 _developer1  __developer1 @xxx. net_ net__
Failed to create e-mail address for
 _developer1  __developer1 @xxx. net_ net__

(Names and domain are changed)

Jan 13, 2013 7:15:56 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string ``_deve...@xxx.net_''

        at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
        at javax.mail.internet.InternetAddress.<init>(InternetAddress.java:111)
        at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:60)
        at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:687)
        at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:508)
        at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:297)
        at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:289)
        at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:249)
        at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perJan 13, 2013 7:15:56 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string ``_y...@worldticket.net_''

        at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
        at javax.mail.internet.InternetAddress.<init>(InternetAddress.java:111)
        at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:60)
        at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:687)
        at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:508)
        at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:297)
        at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:289)
        at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:249)
        at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810)
        at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:785)
        at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
        at hudson.model.Run.execute(Run.java:1587)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
        at hudson.model.ResourceController.execute(ResourceController.java:88)
        at hudson.model.Executor.run(Executor.java:236)formAllBuildSteps(AbstractBuild.java:785)
        at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
        at hudson.model.Run.execute(Run.java:1587)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
        at hudson.model.ResourceController.execute(ResourceController.java:88)
        at hudson.model.Executor.run(Executor.java:236)

First I thought is the problem is in email-ext plugin, but when I went to "Changes" tab and opened the page

http://host/jenkins/user/Developer%201%20__dev...@xxx.net_/
(hostname changed)

it showed

Jenkins User Id: Developer 1 __deve...@xxx.net__


For unknown reason Jenkins adds a leading and trailing underscore to email address

Environment
Jenkins ver. 1.498
Jenkins Mercurial plugin 1.42
Jenkins Email Extension Plugin 2.25


s.a.grigoriev@gmail.com (JIRA)

unread,
Jan 13, 2013, 5:20:53 PM1/13/13
to jenkinsc...@googlegroups.com
Change By: Sergey Grigoriev (13/Jan/13 10:20 PM)
Description:
Jenkins email-ext plugin fails to send email, the error is

Failed to create e-mail address for __deve...@xxx.net__
Failed to create e-mail address for __deve...@xxx.net__
Failed to create e-mail address for __deve...@xxx.net__
Failed to create e-mail address for __deve...@xxx.net__


(Names and domain are changed)

Jan 13, 2013 7:15:56 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string `` _developer1 __developer1 @xxx. net_ net__ ''

        at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
        at javax.mail.internet.InternetAddress.<init>(InternetAddress.java:111)
        at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:60)
        at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:687)
        at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:508)
        at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:297)
        at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:289)
        at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:249)
        at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perJan 13, 2013 7:15:56 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string ``_y...@worldticket.net_''

        at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
        at javax.mail.internet.InternetAddress.<init>(InternetAddress.java:111)
        at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:60)
        at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:687)
        at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:508)
        at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:297)
        at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:289)
        at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:249)
        at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810)
        at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:785)
        at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
        at hudson.model.Run.execute(Run.java:1587)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
        at hudson.model.ResourceController.execute(ResourceController.java:88)
        at hudson.model.Executor.run(Executor.java:236)formAllBuildSteps(AbstractBuild.java:785)
        at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
        at hudson.model.Run.execute(Run.java:1587)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
        at hudson.model.ResourceController.execute(ResourceController.java:88)
        at hudson.model.Executor.run(Executor.java:236)

First I thought is the problem is in email-ext plugin, but when I went to "Changes" tab and opened the page

http://host/jenkins/user/Developer%201%20__dev...@xxx.net_/
(hostname changed)

it showed

Jenkins User Id: Developer 1 __deve...@xxx.net__


For unknown reason Jenkins adds a leading and trailing underscore to email address

Environment
Jenkins ver. 1.498
Jenkins Mercurial plugin 1.42
Jenkins Email Extension Plugin 2.25


s.a.grigoriev@gmail.com (JIRA)

unread,
Jan 13, 2013, 5:22:52 PM1/13/13
to jenkinsc...@googlegroups.com
Change By: Sergey Grigoriev (13/Jan/13 10:21 PM)
Summary: Leading and trailing underscores are added to commiters email address,    unable to send build notification

s.a.grigoriev@gmail.com (JIRA)

unread,
Jan 13, 2013, 5:25:52 PM1/13/13
to jenkinsc...@googlegroups.com
Change By: Sergey Grigoriev (13/Jan/13 10:25 PM)
Description:
Jenkins email-ext plugin fails to send email, the error is

Failed to create e-mail address for __deve...@xxx.net__
Failed to create e-mail address for __deve...@xxx.net__
Failed to create e-mail address for __deve...@xxx.net__
Failed to create e-mail address for __deve...@xxx.net__


(Names and domain are changed)

Jan 13, 2013 7:15:56 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string ``__deve...@xxx.net__''

        at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
        at javax.mail.internet.InternetAddress.<init>(InternetAddress.java:111)
        at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:60)
        at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:687)
        at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:508)
        at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:297)
        at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:289)
        at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:249)
        at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perJan 13, 2013 7:15:56 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string ``_y...@worldticket.net_''

        at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
        at javax.mail.internet.InternetAddress.<init>(InternetAddress.java:111)
        at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:60)
        at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:687)
        at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:508)
        at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:297)
        at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:289)
        at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:249)
        at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810)
        at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:785)
        at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
        at hudson.model.Run.execute(Run.java:1587)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
        at hudson.model.ResourceController.execute(ResourceController.java:88)
        at hudson.model.Executor.run(Executor.java:236)formAllBuildSteps(AbstractBuild.java:785)
        at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
        at hudson.model.Run.execute(Run.java:1587)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
        at hudson.model.ResourceController.execute(ResourceController.java:88)
        at hudson.model.Executor.run(Executor.java:236)

First I thought is the problem is in email-ext plugin, but when I went to "Changes" tab and opened the page

http://host/jenkins/user/Developer%201%20__dev...@xxx.net_/
(hostname changed)

it showed

Jenkins User Id: Developer 1 __deve...@xxx.net__


For unknown reason Jenkins adds a leading and trailing underscore to email address

Environment
Jenkins ver. 1.498
Jenkins Mercurial plugin 1.42
Jenkins Email Extension Plugin 2.25
Mercurial Distributed SCM (version 1.4.3)
Ubuntu 10.04.4 LTS
Java(TM) SE Runtime Environment (build 1.6.0_32-b05)
Java HotSpot(TM) 64-Bit Server VM (build 20.7-b02, mixed mode)

s.a.grigoriev@gmail.com (JIRA)

unread,
Jan 13, 2013, 5:31:52 PM1/13/13
to jenkinsc...@googlegroups.com
Change By: Sergey Grigoriev (13/Jan/13 10:30 PM)
Description:
Jenkins email-ext plugin fails to send email, the error is

Failed to create e-mail address for __deve...@xxx.net__
Failed to create e-mail address for __deve...@xxx.net__
Failed to create e-mail address for __deve...@xxx.net__
Failed to create e-mail address for __deve...@xxx.net__


(Names and domain are changed)

Jan 13, 2013 7:15:56 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string ``__deve...@xxx.net__''

        at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
        at javax.mail.internet.InternetAddress.<init>(InternetAddress.java:111)
        at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:60)
        at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:687)
        at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:508)
        at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:297)
        at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:289)
        at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:249)
        at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perJan 13, 2013 7:15:56 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string ``_y...@worldticket.net_''

        at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
        at javax.mail.internet.InternetAddress.<init>(InternetAddress.java:111)
        at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:60)
        at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:687)
        at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:508)
        at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:297)
        at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:289)
        at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:249)
        at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810)
        at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:785)
        at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
        at hudson.model.Run.execute(Run.java:1587)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
        at hudson.model.ResourceController.execute(ResourceController.java:88)
        at hudson.model.Executor.run(Executor.java:236)formAllBuildSteps(AbstractBuild.java:785)
        at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
        at hudson.model.Run.execute(Run.java:1587)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
        at hudson.model.ResourceController.execute(ResourceController.java:88)
        at hudson.model.Executor.run(Executor.java:236)

First I thought is the problem is in email-ext plugin, but when I went to "Changes" tab and opened the page

http://host/jenkins/user/Developer%201%20__dev...@xxx.net_/
(hostname changed)

it showed

Jenkins User Id: Developer 1 __deve...@xxx.net__


For unknown reason Jenkins adds a leading and trailing underscore to email address

Environment
Jenkins ver. 1.498
Jenkins Mercurial plugin 1.42
Jenkins Email Extension Plugin 2.25
Mercurial Distributed SCM (version 1.4.3)
Ubuntu 10.04.4 LTS
Java(TM) SE Runtime Environment (build 1.6.0_32-b05)
Java HotSpot(TM) 64-Bit Server VM (build 20.7-b02, mixed mode)


When I type hg log on Jenkins job's workspace, then all changesets have
correct email address without underscores, so it is not Mercurial configuration problem.



s.a.grigoriev@gmail.com (JIRA)

unread,
Jan 13, 2013, 5:33:52 PM1/13/13
to jenkinsc...@googlegroups.com
Change By: Sergey Grigoriev (13/Jan/13 10:32 PM)
Description:
Jenkins email-ext plugin fails to send email, the error is

Failed to create e-mail address for __deve...@xxx.net__
Failed to create e-mail address for __deve...@xxx.net__
Failed to create e-mail address for __deve...@xxx.net__
Failed to create e-mail address for __deve...@xxx.net__


(Names and domain are changed)

Jan 13, 2013 7:15:56 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string ``__deve...@xxx.net__''

        at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
        at javax.mail.internet.InternetAddress.<init>(InternetAddress.java:111)
        at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:60)
        at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:687)
        at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:508)
        at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:297)
        at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:289)
        at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:249)
        at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perJan 13, 2013 7:15:56 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string ``_y...@worldticket.net_''

        at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
        at javax.mail.internet.InternetAddress.<init>(InternetAddress.java:111)
        at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:60)
        at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:687)
        at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:508)
        at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:297)
        at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:289)
        at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:249)
        at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810)
        at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:785)
        at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
        at hudson.model.Run.execute(Run.java:1587)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
        at hudson.model.ResourceController.execute(ResourceController.java:88)
        at hudson.model.Executor.run(Executor.java:236)formAllBuildSteps(AbstractBuild.java:785)
        at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
        at hudson.model.Run.execute(Run.java:1587)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
        at hudson.model.ResourceController.execute(ResourceController.java:88)
        at hudson.model.Executor.run(Executor.java:236)

First I thought is the problem is in email-ext plugin, but when I went to "Changes" tab and opened the page

http://host/jenkins/user/Developer%201%20__dev...@xxx.net_/
(hostname changed)

it showed

Jenkins User Id: Developer 1 __deve...@xxx.net__


For unknown reason Jenkins adds a leading and trailing underscore to email address

Environment
Jenkins ver. 1.498
Jenkins Mercurial plugin 1.42
Jenkins Email Extension Plugin 2.25
Mercurial Distributed SCM (version 1.4.3)
Ubuntu 10.04.4 LTS
Java(TM) SE Runtime Environment (build 1.6.0_32-b05)
Java HotSpot(TM) 64-Bit Server VM (build 20.7-b02, mixed mode)

We have a build cluster with a master and two slaves, this problem happened on the slave machine.


When I type hg log on Jenkins job's workspace, then all changesets have
correct email address without underscores, so it is not Mercurial configuration problem.



s.a.grigoriev@gmail.com (JIRA)

unread,
Jan 13, 2013, 5:41:52 PM1/13/13
to jenkinsc...@googlegroups.com
Change By: Sergey Grigoriev (13/Jan/13 10:41 PM)
Description:
Jenkins email-ext plugin fails to send email, the error is

Failed to create e-mail address for __deve...@xxx.net__
Failed to create e-mail address for __deve...@xxx.net__
Failed to create e-mail address for __deve...@xxx.net__
Failed to create e-mail address for __deve...@xxx.net__


(Names and domain are changed)

Jan 13, 2013 7:15:56 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string ``__deve...@xxx.net__''

        at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
        at javax.mail.internet.InternetAddress.<init>(InternetAddress.java:111)
        at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:60)
        at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:687)
        at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:508)
        at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:297)
        at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:289)
        at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:249)
        at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perJan 13, 2013 7:15:56 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string `` _yin __developer1 @ worldticket xxx . net_ net__ ''

        at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
        at javax.mail.internet.InternetAddress.<init>(InternetAddress.java:111)
        at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:60)
        at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:687)
        at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:508)
        at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:297)
        at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:289)
        at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:249)
        at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:810)
        at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:785)
        at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
        at hudson.model.Run.execute(Run.java:1587)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
        at hudson.model.ResourceController.execute(ResourceController.java:88)
        at hudson.model.Executor.run(Executor.java:236)formAllBuildSteps(AbstractBuild.java:785)
        at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
        at hudson.model.Run.execute(Run.java:1587)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
        at hudson.model.ResourceController.execute(ResourceController.java:88)
        at hudson.model.Executor.run(Executor.java:236)

First I thought is the problem is in email-ext plugin, but when I went to "Changes" tab and opened the page

http://host/jenkins/user/Developer%201%20__dev...@xxx.net_/
(hostname changed)

it showed

Jenkins User Id: Developer 1 __deve...@xxx.net__


For unknown reason Jenkins adds a leading and trailing underscore to email address

Environment
Jenkins ver. 1.498
Jenkins Mercurial plugin 1.42
Jenkins Email Extension Plugin 2.25
Mercurial Distributed SCM (version 1.4.3)
Ubuntu 10.04.4 LTS
Java(TM) SE Runtime Environment (build 1.6.0_32-b05)
Java HotSpot(TM) 64-Bit Server VM (build 20.7-b02, mixed mode)

We have a build cluster with a master and two slaves, this problem happened on the slave machine.


When I type hg log on Jenkins job's workspace, then all changesets have
correct email address without underscores, so it is not Mercurial configuration problem.



jglick@cloudbees.com (JIRA)

unread,
Jan 14, 2013, 12:01:52 PM1/14/13
to jenkinsc...@googlegroups.com
Jesse Glick commented on Bug JENKINS-16332

The user ID will typically include underscores, but there ought to be a separate email property (shown at /user/*/configure) that includes the original email address. Perhaps this got broken by the recent split of the mailer plugin out of core; definitely assigning of emails to users who sign themselves up in the web UI was broken (fix will be in 1.500), but user creation from SCM changelogs is a different code path. Need to check if it is reproducible.

s.a.grigoriev@gmail.com (JIRA)

unread,
Jan 14, 2013, 1:51:52 PM1/14/13
to jenkinsc...@googlegroups.com

In my case the user's don't sign up themselves, they don't have Jenkins accounts. Emails are extracted from SCM log only.

s.a.grigoriev@gmail.com (JIRA)

unread,
Jan 14, 2013, 1:53:52 PM1/14/13
to jenkinsc...@googlegroups.com
 
Sergey Grigoriev edited a comment on Bug JENKINS-16332

In my case the user's don't sign up themselves, they don't have Jenkins accounts and cannot login into Jenkins. Emails are extracted from SCM log only.

s.a.grigoriev@gmail.com (JIRA)

unread,
Jan 14, 2013, 1:53:53 PM1/14/13
to jenkinsc...@googlegroups.com

In my case the commiters don't sign up themselves, they don't have Jenkins accounts and cannot login into Jenkins. Emails are extracted from SCM log only.

s.a.grigoriev@gmail.com (JIRA)

unread,
Jan 15, 2013, 9:58:52 AM1/15/13
to jenkinsc...@googlegroups.com

s.a.grigoriev@gmail.com (JIRA)

unread,
Jan 15, 2013, 9:58:53 AM1/15/13
to jenkinsc...@googlegroups.com

s.a.grigoriev@gmail.com (JIRA)

unread,
Jan 15, 2013, 10:00:52 AM1/15/13
to jenkinsc...@googlegroups.com
 
Sergey Grigoriev edited a comment on Bug JENKINS-16332

The problem has gone after 'sudo service jenkins restart'.

jglick@cloudbees.com (JIRA)

unread,
Jan 15, 2013, 1:44:52 PM1/15/13
to jenkinsc...@googlegroups.com
Jesse Glick commented on Bug JENKINS-16332

Hmm if even @sgr cannot reproduce after restarting Jenkins then it is unlikely I will be able to reproduce either.

s.a.grigoriev@gmail.com (JIRA)

unread,
Jan 15, 2013, 2:47:53 PM1/15/13
to jenkinsc...@googlegroups.com
Sergey Grigoriev resolved Bug JENKINS-16332 as Cannot Reproduce

Cannot reproduce

Change By: Sergey Grigoriev (15/Jan/13 7:46 PM)
Status: Open Resolved
Resolution: Cannot Reproduce

s.a.grigoriev@gmail.com (JIRA)

unread,
Jan 15, 2013, 2:47:53 PM1/15/13
to jenkinsc...@googlegroups.com

pykler2@mailinator.com (JIRA)

unread,
Mar 1, 2013, 12:06:53 AM3/1/13
to jenkinsc...@googlegroups.com

Try setting up a repo with your username = First MyName <em...@email.com>

then make a commit that fails the build, or triggers the email and look at the console log ... it will clearly have underscores instead of <> ... also check the details log as mentioned ... the issue should be visible. We hit this as soon as we upgraded to the lates jenkins.

Change By: pykler pykler (01/Mar/13 5:06 AM)
Resolution: Cannot Reproduce
Status: Closed Reopened

jglick@cloudbees.com (JIRA)

unread,
Mar 1, 2013, 1:46:53 PM3/1/13
to jenkinsc...@googlegroups.com
Jesse Glick resolved Bug JENKINS-16332 as Cannot Reproduce

Still cannot reproduce. Using 1.505-SNAPSHOT (Mailer Plugin 1.4 was bundled) and dev version of Mercurial plugin, created a Maven job based on a new Hg repo created from a quickstart archetype, built it. Committed a test failure where my ~/.hgrc has

[ui]
username = Jesse Glick <jgl...@netbeans.org>

and checked changelog. http://localhost:8080/user/Jesse%20Glick%20_j...@netbeans.org_/configure now has Your name set to Jesse Glick <jgl...@netbeans.org> and E-mail address set to jgl...@netbeans.org, as expected.

(Again it is normal for http://localhost:8080/user/Jesse%20Glick%20_j...@netbeans.org_/ to show Jesse Glick <jgl...@netbeans.org> as the display name followed by Jenkins User Id: Jesse Glick jgl...@netbeans.org since IDs are always escaped to not contain dangerous characters such as <, but this should not affect mail delivery or other functions since the email address is stored as a user property.)

Also installed email-ext plugin, added an Unstable trigger to send to committers, committed another test failure and built again. Log showed

Sending email to: jgl...@netbeans.org

as expected (I did not configure SMTP so did not check that it really sent mail).

If you can still reproduce an issue with the latest versions of the Mercurial plugin, Jenkins core, and the Mailer plugin (now responsible for email address maintenance in a User), feel free to debug and file a pull request with a fix.

Change By: Jesse Glick (01/Mar/13 6:45 PM)
Status: Reopened Resolved
Resolution: Cannot Reproduce

s.a.grigoriev@gmail.com (JIRA)

unread,
Mar 3, 2013, 7:11:53 AM3/3/13
to jenkinsc...@googlegroups.com

jenkins@g.zazu.com (JIRA)

unread,
Apr 19, 2013, 4:19:32 PM4/19/13
to jenkinsc...@googlegroups.com

I hope it's ok to reopen this, because I'm also seeing the same issue and have not seen it go away across jenkins upgrades. I'm currently running version 1.511-1.1 on a RHEL 5 system, using the officially supplied rpm. I also he emailext plugin, in case that has anything to do with this. There are not full user accounts that were explicitly registered with passwords. These are all auto-created users from the mercurial SCM change sets.

My main concern with this bug is that submitters are no longer receiving email notifications when the build fails.

Change By: GlennZ (19/Apr/13 8:18 PM)
Resolution: Cannot Reproduce
Status: Resolved Reopened

s.a.grigoriev@gmail.com (JIRA)

unread,
Apr 19, 2013, 4:33:32 PM4/19/13
to jenkinsc...@googlegroups.com

This issue happen again 1 week ago on the latest version of Jenkins.

s.a.grigoriev@gmail.com (JIRA)

unread,
Apr 20, 2013, 1:00:32 PM4/20/13
to jenkinsc...@googlegroups.com

Another incident happened in the following environment

Name ↓ Value
dozer.configuration META-INF/dozer/configuration.properties
executable-war /var/lib/jenkins/jenkins.war
file.encoding UTF-8
file.encoding.pkg sun.io
file.separator /
hudson.diyChunking true
java.awt.graphicsenv sun.awt.X11GraphicsEnvironment
java.awt.headless true
java.awt.printerjob sun.print.PSPrinterJob
java.class.path /var/lib/jenkins/jenkins.war
java.class.version 50.0
java.endorsed.dirs /opt/sun-jdk-1.6.0.26/jre/lib/endorsed
java.ext.dirs /opt/sun-jdk-1.6.0.26/jre/lib/ext:/usr/java/packages/lib/ext
java.home /opt/sun-jdk-1.6.0.26/jre
java.io.tmpdir /tmp
java.library.path /opt/sun-jdk-1.6.0.26/jre/lib/amd64/server:/opt/sun-jdk-1.6.0.26/jre/lib/amd64:/opt/sun-jdk-1.6.0.26/jre/../lib/amd64:/usr/java/packages/lib/amd64:/usr/lib64:/lib64:/lib:/usr/lib
java.runtime.name Java(TM) SE Runtime Environment
java.runtime.version 1.6.0_26-b03
java.specification.name Java Platform API Specification
java.specification.vendor Sun Microsystems Inc.
java.specification.version 1.6
java.vendor Sun Microsystems Inc.
java.vendor.url http://java.sun.com/
java.vendor.url.bug http://java.sun.com/cgi-bin/bugreport.cgi
java.version 1.6.0_26
java.vm.info mixed mode
java.vm.name Java HotSpot(TM) 64-Bit Server VM
java.vm.specification.name Java Virtual Machine Specification
java.vm.specification.vendor Sun Microsystems Inc.
java.vm.specification.version 1.0
java.vm.vendor Sun Microsystems Inc.
java.vm.version 20.1-b02
jna.platform.library.path /usr/lib64:/lib64:/usr/lib:/lib
line.separator
mail.smtp.sendpartial true
mail.smtps.sendpartial true
os.arch amd64
os.name Linux
os.version 2.6.39-gentoo-r3
path.separator :
sun.arch.data.model 64
sun.boot.class.path /opt/sun-jdk-1.6.0.26/jre/lib/resources.jar:/opt/sun-jdk-1.6.0.26/jre/lib/rt.jar:/opt/sun-jdk-1.6.0.26/jre/lib/sunrsasign.jar:/opt/sun-jdk-1.6.0.26/jre/lib/jsse.jar:/opt/sun-jdk-1.6.0.26/jre/lib/jce.jar:/opt/sun-jdk-1.6.0.26/jre/lib/charsets.jar:/opt/sun-jdk-1.6.0.26/jre/lib/modules/jdk.boot.jar:/opt/sun-jdk-1.6.0.26/jre/classes
sun.boot.library.path /opt/sun-jdk-1.6.0.26/jre/lib/amd64
sun.cpu.endian little
sun.cpu.isalist
sun.io.unicode.encoding UnicodeLittle
sun.java.command /var/lib/jenkins/jenkins.war --httpPort=8081 --ajp13Port=-1 --prefix=/jenkins --logfile=/var/log/jenkins/jenkins.log --webroot=/var/run/jenkins/work
sun.java.launcher SUN_STANDARD
sun.jnu.encoding UTF-8
sun.management.compiler HotSpot 64-Bit Tiered Compilers
sun.os.patch.level unknown
user.country US
user.dir /
user.home /var/lib/jenkins
user.language en
user.name jenkins
user.timezone Europe/Copenhagen
Environment Variables
Name ↓ Value
ANT_HOME /usr/share/ant-core
CONFIG_PROTECT_MASK /etc/gentoo-release /etc/sandbox.d /etc/env.d/java/ /etc/php/cli-php5.3/ext-active/ /etc/php/cgi-php5.3/ext-active/ /etc/php/apache2-php5.3/ext-active/ /etc/terminfo /etc/revdep-rebuild
EDITOR /usr/bin/vi
EINFO_LOG /var/lib/jenkins/init.d/jenkins
GCC_SPECS
GENERATION 2
HG /usr/bin/hg
HOME /var/lib/jenkins
INFOPATH /usr/share/info:/usr/share/binutils-data/x86_64-pc-linux-gnu/2.20.1/info:/usr/share/gcc-data/x86_64-pc-linux-gnu/4.4.5/info
JAVA_HOME /opt/blackdown-jdk-1.4.2.03
JAVAC /opt/blackdown-jdk-1.4.2.03/bin/javac
JDK_HOME /opt/blackdown-jdk-1.4.2.03
JENKINS_ARGS --httpPort=8081 --ajp13Port=-1 --prefix=/jenkins --logfile=/var/log/jenkins/jenkins.log --webroot=/var/run/jenkins/work
JENKINS_HOME /var/lib/jenkins
LANG en_US.utf8
LD_LIBRARY_PATH /opt/sun-jdk-1.6.0.26/jre/lib/amd64/server:/opt/sun-jdk-1.6.0.26/jre/lib/amd64:/opt/sun-jdk-1.6.0.26/jre/../lib/amd64
LESS -R -M --shift 5
MANPATH /usr/local/share/man:/usr/share/man:/usr/share/binutils-data/x86_64-pc-linux-gnu/2.20.1/man:/usr/share/gcc-data/x86_64-pc-linux-gnu/4.4.5/man:/opt/blackdown-jdk-1.4.2.03/man:/etc/java-config/system-vm/man/:/usr/lib64/php5.3/man/
NLSPATH /usr/dt/lib/nls/msg/%L/%N.cat
OPENGL_PROFILE xorg-x11
PATH /bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:/opt/bin:/usr/x86_64-pc-linux-gnu/gcc-bin/4.4.5:/opt/blackdown-jdk-1.4.2.03/bin:/opt/blackdown-jdk-1.4.2.03/jre/bin
PIDFILE /var/run/jenkins/jenkins.pid
PWD /
RC_SERVICE /var/lib/jenkins/init.d/jenkins
RC_SVCNAME jenkins
ROOTPATH /opt/bin:/usr/x86_64-pc-linux-gnu/gcc-bin/4.4.5:/opt/blackdown-jdk-1.4.2.03/bin:/opt/blackdown-jdk-1.4.2.03/jre/bin
RUBYOPT -rauto_gem
SHELL /bin/bash
SHLVL 2
SVCNAME jenkins
TERM xterm
USER jenkins
VISUAL /usr/bin/vi
VMHANDLE blackdown-jdk-1.4.2
XFILESEARCHPATH /usr/dt/app-defaults/%L/Dt
Plugins
Name ↓ Version Enabled Pinned
analysis-core 1.49 true false
ant 1.2 true true
checkstyle 3.35 true false
chucknorris 0.5 true false
credentials 1.4 true true
cvs 2.8 true true
dry 2.34 true false
email-ext 2.28 true false
emma 1.29 true false
external-monitor-job 1.1 true false
findbugs 4.48 true false
greenballs 1.12 true false
hudson-apiv2-plugin 5.0.4 true false
hudson-jirareporter-plugin 5.0.4 true false
javadoc 1.1 true true
job-exporter 0.4 true false
job-import-plugin 1.0 true false
jquery 1.7.2-1 true false
ldap 1.2 true true
mailer 1.4 true false
maven-plugin 1.511 true true
mercurial 1.44 true false
next-build-number 1.0 true false
pam-auth 1.0 true false
pmd 3.34 true false
ssh-credentials 0.3 true true
ssh-slaves 0.25 true true
subversion 1.45 false true
translation 1.10 true true
violations 0.7.11 false

s.a.grigoriev@gmail.com (JIRA)

unread,
Apr 20, 2013, 1:04:32 PM4/20/13
to jenkinsc...@googlegroups.com
 
Sergey Grigoriev edited a comment on Bug JENKINS-16332

Another incident happened in Jenkins 1.511. The build was triggered by an SCM change (Mercurial), culrprits have received emails, but the commiter didn't recieve the email because Jenkins appended leading and trailing underscores to his email address

s.a.grigoriev@gmail.com (JIRA)

unread,
Apr 20, 2013, 1:04:32 PM4/20/13
to jenkinsc...@googlegroups.com

Another incident happened in the following environment. The build was triggered by an SCM change (Mercurial), culrprits have received emails, but the commiter didn't recieve the email because Jenkins appended leading and trailing underscores to his email address

s.a.grigoriev@gmail.com (JIRA)

unread,
Apr 20, 2013, 1:08:32 PM4/20/13
to jenkinsc...@googlegroups.com

Another incident happened in Jenkins 1.511. The build was triggered by an SCM change (Mercurial), culrprits have received emails, but the commiter didn't recieve the email because Jenkins appended leading and trailing underscores to his email address

Apr 20, 2013 5:22:04 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList


WARNING: Could not create email address.

javax.mail.internet.AddressException: Domain contains illegal character in string ``deve...@yyyy.com''


at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)

at javax.mail.internet.InternetAddress.parse(InternetAddress.java:610)
at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:33)
at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:706)
at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:522)
at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:304)
at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:296)
at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:256)
at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:802)
at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:774)
at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
at hudson.model.Run.execute(Run.java:1620)


at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
at hudson.model.ResourceController.execute(ResourceController.java:88)

at hudson.model.Executor.run(Executor.java:237)

s.a.grigoriev@gmail.com (JIRA)

unread,
Apr 20, 2013, 1:08:32 PM4/20/13
to jenkinsc...@googlegroups.com

Another incident happened in Jenkins 1.511. The build was triggered by an SCM change (Mercurial), culrprits have received emails, but the commiter didn't recieve the email because Jenkins appended leading and trailing underscores to his email address

Apr 20, 2013 5:22:04 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string ``_deve...@yyyy.com_''
        at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:610)
        at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:33)
        at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:706)
        at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:522)
        at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:304)
        at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:296)
        at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:256)
        at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:802)
        at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:774)
        at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
        at hudson.model.Run.execute(Run.java:1620)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
        at hudson.model.ResourceController.execute(ResourceController.java:88)
        at hudson.model.Executor.run(Executor.java:237)

jglick@cloudbees.com (JIRA)

unread,
Apr 25, 2013, 11:25:32 AM4/25/13
to jenkinsc...@googlegroups.com
Jesse Glick commented on Bug JENKINS-16332

You can reopen whatever you like, but until someone who is able to reproduce the bug goes through it with a debugger, nothing is going to happen.

By the way I no longer use Mercurial and barely maintain this plugin. If there is someone who does use Mercurial full-time and is proficient at Jenkins plugin development, please consider taking it over.

s.a.grigoriev@gmail.com (JIRA)

unread,
May 3, 2013, 5:07:58 AM5/3/13
to jenkinsc...@googlegroups.com

The body of the email sent by ext-email contains invalid emails.

Changes for Build #10770
[John Doe _d...@xyz.com_] Fixed JUnit tests

s.a.grigoriev@gmail.com (JIRA)

unread,
May 3, 2013, 5:11:58 AM5/3/13
to jenkinsc...@googlegroups.com
 
Sergey Grigoriev edited a comment on Bug JENKINS-16332

The body of the email sent by ext-email contains invalid emails.

Changes for Build #10770
[John Doe _d...@xyz.com_] Fixed JUnit tests

However, the Mercurial changeset contain a correct email

changeset: 71777:dd8d779c3d30
parent: 71760:76b2fa2dfefb
user: John Doe <d...@xyz.com>
date: Thu Apr 18 11:30:02 2013 +0300
summary: Fixed JUnit tests

s.a.grigoriev@gmail.com (JIRA)

unread,
May 3, 2013, 5:11:58 AM5/3/13
to jenkinsc...@googlegroups.com

The body of the email sent by ext-email contains invalid emails.

Changes for Build #10770
[John Doe _d...@xyz.com_] Fixed JUnit tests

However, the Mercurial changeset contain invalid changelog entries

changeset: 71777:dd8d779c3d30
parent: 71760:76b2fa2dfefb
user: John Doe <d...@xyz.com>
date: Thu Apr 18 11:30:02 2013 +0300
summary: Fixed JUnit tests

s.a.grigoriev@gmail.com (JIRA)

unread,
May 3, 2013, 5:13:58 AM5/3/13
to jenkinsc...@googlegroups.com

The body of the email sent by ext-email contains invalid emails.

Changes for Build #10770
[John Doe _d...@xyz.com_] Fixed JUnit tests

However, the Mercurial changeset has a correct email

changeset: 71777:dd8d779c3d30
parent: 71760:76b2fa2dfefb
user: John Doe <d...@xyz.com>
date: Thu Apr 18 11:30:02 2013 +0300
summary: Fixed JUnit tests

s.a.grigoriev@gmail.com (JIRA)

unread,
May 4, 2013, 6:23:58 AM5/4/13
to jenkinsc...@googlegroups.com
Unable to find source-code formatter for language: groovy. Available languages are: javascript, sql, xhtml, actionscript, none, html, xml, java
import java.util.logging.Logger
import java.util.logging.Level;
import hudson.model.*
import hudson.plugins.emailext.EmailRecipientUtils  
import hudson.tasks.MailAddressResolver  
import hudson.model.User  
  
def mailAddressResolverLogger = Logger.getLogger(MailAddressResolver.class.getName());
mailAddressResolverLogger.setLevel(Level.FINE)


def job = Hudson.instance.getJob("sms-dev-jdk7");  
def build = job.getBuild("46")

def userWithWrongEmail = User.get('John Doe')
println  userWithWrongEmail 
def userMailProp = userWithWrongEmail.properties.find { it.toString().contains('Mailer') }.value
userMailProp.address.getAddress()

evaluates to "John Doe"

s.a.grigoriev@gmail.com (JIRA)

unread,
May 4, 2013, 6:25:59 AM5/4/13
to jenkinsc...@googlegroups.com
 
Sergey Grigoriev edited a comment on Bug JENKINS-16332
Unable to find source-code formatter for language: groovy. Available languages are: javascript, sql, xhtml, actionscript, none, html, xml, java
import java.util.logging.Logger
import java.util.logging.Level;
import hudson.model.*
import hudson.plugins.emailext.EmailRecipientUtils  
import hudson.tasks.MailAddressResolver  
import hudson.model.User  
  
def mailAddressResolverLogger = Logger.getLogger(MailAddressResolver.class.getName());
mailAddressResolverLogger.setLevel(Level.FINE)


def job = Hudson.instance.getJob("sms-dev-jdk7");  
def build = job.getBuild("46")

def userWithWrongEmail = User.get('John Doe')
println  userWithWrongEmail 
def userMailProp = userWithWrongEmail.properties.find { it.toString().contains('Mailer') }.value
userMailProp.address.getAddress()

evaluates to "John Doe" which indicates that the user doesn't have a correct email property

s.a.grigoriev@gmail.com (JIRA)

unread,
May 4, 2013, 6:52:58 AM5/4/13
to jenkinsc...@googlegroups.com

I have run a script in Jenkins console

Unable to find source-code formatter for language: groovy. Available languages are: javascript, sql, xhtml, actionscript, none, html, xml, java
import java.util.logging.Logger
import java.util.logging.Level;
import hudson.model.*
import hudson.plugins.emailext.EmailRecipientUtils  
import hudson.tasks.MailAddressResolver  
import hudson.model.User  
  
def mailAddressResolverLogger = Logger.getLogger(MailAddressResolver.class.getName());
mailAddressResolverLogger.setLevel(Level.FINE)


def job = Hudson.instance.getJob("sms-dev-jdk7");  
def build = job.getBuild("46"
)

build.culprits.each {   
  def userMailProp = it.properties.find { it.toString().contains('Mailer') }.value	
  println "${it.id} -- ${userMailProp.address}"  
}

it prints

Igor Ivanov igor...@yahoo.comigor...@yahoo.com
John Doe d...@xyz.com – John Doe d...@xyz.com

So the user object for which Jenkins uses a wrong email, returns a different value than normal users, see hudson.tasks.Mailer.UserProperty#getAddress.
For normal users getAddress returns email, while for John Doe not email, but user's id is returned.

s.a.grigoriev@gmail.com (JIRA)

unread,
May 4, 2013, 6:52:58 AM5/4/13
to jenkinsc...@googlegroups.com

I have run a script in Jenkins console

Unable to find source-code formatter for language: groovy. Available languages are: javascript, sql, xhtml, actionscript, none, html, xml, java
import java.util.logging.Logger
import java.util.logging.Level;
import hudson.model.*
import hudson.plugins.emailext.EmailRecipientUtils  
import hudson.tasks.MailAddressResolver  
import hudson.model.User  
  
def mailAddressResolverLogger = Logger.getLogger(MailAddressResolver.class.getName());
mailAddressResolverLogger.setLevel(Level.FINE)


def job = Hudson.instance.getJob("sms-dev-jdk7");  
def build = job.getBuild("46")

build.culprits.each {   
  def userMailProp = it.properties.find { it.toString().contains('Mailer') }.value	
  println "${it.id} -- ${userMailProp.address}"  
}

it prints

Igor Ivanov _igor...@yahoo.com_ -- igor...@yahoo.com
John Doe  _d...@xyz.com_ -- John Doe  _d...@xyz.com_

So the user object for which Jenkins uses a wrong email, returns a different value than normal users, see hudson.tasks.Mailer.UserProperty#getAddress.
For normal users getAddress returns email, while for John Doe not email, but user's id is returned.

s.a.grigoriev@gmail.com (JIRA)

unread,
May 4, 2013, 6:54:58 AM5/4/13
to jenkinsc...@googlegroups.com

I have run a script in Jenkins console

Unable to find source-code formatter for language: groovy. Available languages are: javascript, sql, xhtml, actionscript, none, html, xml, java
import java.util.logging.Logger
import java.util.logging.Level;
import hudson.model.*
import hudson.plugins.emailext.EmailRecipientUtils  
import hudson.tasks.MailAddressResolver  
import hudson.model.User  
  
def mailAddressResolverLogger = Logger.getLogger(MailAddressResolver.class.getName());
mailAddressResolverLogger.setLevel(Level.FINE)


def job = Hudson.instance.getJob("sms-dev-jdk7");  
def build = job.getBuild("46")

build.culprits.each {   
  def userMailProp = it.properties.find { it.toString().contains('Mailer') }.value	
  println "${it.id} -- ${userMailProp.address}"  
}

it prints

Igor Ivanov _igor...@yahoo.com_ -- igor...@yahoo.com
John Doe  _d...@xyz.com_ -- John Doe  _d...@xyz.com_

So the user object for which Jenkins uses a wrong email, has a different value for email than normal users, see hudson.tasks.Mailer.UserProperty#getAddress.


For normal users getAddress returns email, while for John Doe not email, but user's id is returned.

s.a.grigoriev@gmail.com (JIRA)

unread,
May 4, 2013, 6:54:58 AM5/4/13
to jenkinsc...@googlegroups.com

I have run a script in Jenkins console

import java.util.logging.Logger
import java.util.logging.Level;
import hudson.model.*
import hudson.plugins.emailext.EmailRecipientUtils  
import hudson.tasks.MailAddressResolver  
import hudson.model.User  
  
def mailAddressResolverLogger = Logger.getLogger(MailAddressResolver.class.getName());
mailAddressResolverLogger.setLevel(Level.FINE)


def job = Hudson.instance.getJob("sms-dev-jdk7");  
def build = job.getBuild("46")

build.culprits.each {   
  def userMailProp = it.properties.find { it.toString().contains('Mailer') }.value	
  println "${it.id} -- ${userMailProp.address}"  
}

it prints

Igor Ivanov _igor...@yahoo.com_ -- igor...@yahoo.com
John Doe  _d...@xyz.com_ -- John Doe  _d...@xyz.com_

So the user object for which Jenkins uses a wrong email, has a different value for email than normal users, see hudson.tasks.Mailer.UserProperty#getAddress.
For normal users getAddress returns email, while for John Doe not email, but user's id is returned.

s.a.grigoriev@gmail.com (JIRA)

unread,
May 4, 2013, 6:56:57 AM5/4/13
to jenkinsc...@googlegroups.com

s.a.grigoriev@gmail.com (JIRA)

unread,
May 4, 2013, 7:08:57 AM5/4/13
to jenkinsc...@googlegroups.com

I don't think that this bug is mercurial-specific, the script shows that the problem is that Jenkins cannot detect a user's email by user's id, even though the email is the part of the id.

Change By: Sergey Grigoriev (04/May/13 11:07 AM)
Component/s: core
Component/s: mercurial

s.a.grigoriev@gmail.com (JIRA)

unread,
May 4, 2013, 7:12:57 AM5/4/13
to jenkinsc...@googlegroups.com
 
Sergey Grigoriev edited a comment on Bug JENKINS-16332

I have run a script in Jenkins console

import java.util.logging.Logger
import java.util.logging.Level;
import hudson.model.*
import hudson.plugins.emailext.EmailRecipientUtils  
import hudson.tasks.MailAddressResolver  
import hudson.model.User  
  
def mailAddressResolverLogger = Logger.getLogger(MailAddressResolver.class.getName());
mailAddressResolverLogger.setLevel(Level.FINE)


def job = Hudson.instance.getJob("sms-dev-jdk7");  
def build = job.getBuild("46"
)

build.culprits.each {   
  def userMailProp = it.properties.find { it.toString().contains('Mailer') }.value	
  println "${it.id} -- ${userMailProp.address}  resolved to  ${MailAddressResolver.resolve(it)}"  
}

it prints

Igor Ivanov _igor...@yahoo.com_ -- igor...@yahoo.com resolved to igor...@yahoo.com
John Doe  _d...@xyz.com_ -- John Doe  _d...@xyz.com_ resolved to John Doe  _d...@xyz.com_  

So the user object for which Jenkins uses a wrong email, has a different value for email than normal users, see hudson.tasks.Mailer.UserProperty#getAddress.
For normal users getAddress returns email, while for John Doe not email, but user's id is returned.

This message is automatically generated by JIRA.

s.a.grigoriev@gmail.com (JIRA)

unread,
May 4, 2013, 7:29:57 AM5/4/13
to jenkinsc...@googlegroups.com

This bug was introduced when extracting sending mails to the "mailer plugin"

s.a.grigoriev@gmail.com (JIRA)

unread,
May 4, 2013, 7:37:58 AM5/4/13
to jenkinsc...@googlegroups.com

Attached Jenkins system information

Change By: Sergey Grigoriev (04/May/13 11:37 AM)
Attachment: System Information [Jenkins].html

s.a.grigoriev@gmail.com (JIRA)

unread,
May 4, 2013, 7:37:58 AM5/4/13
to jenkinsc...@googlegroups.com
 
Sergey Grigoriev edited a comment on Bug JENKINS-16332

Another incident happened in Jenkins 1.511. The build was triggered by an SCM change (Mercurial), culrprits have received emails, but the commiter didn't recieve the email because Jenkins appended leading and trailing underscores to his email address

Apr 20, 2013 5:22:04 PM hudson.plugins.emailext.ExtendedEmailPublisher addAddressesFromRecipientList
WARNING: Could not create email address.
javax.mail.internet.AddressException: Domain contains illegal character in string ``_deve...@yyyy.com_''
        at javax.mail.internet.InternetAddress.checkAddress(InternetAddress.java:1269)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:1091)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:633)
        at javax.mail.internet.InternetAddress.parse(InternetAddress.java:610)
        at hudson.plugins.emailext.EmailRecipientUtils.convertRecipientString(EmailRecipientUtils.java:33)
        at hudson.plugins.emailext.ExtendedEmailPublisher.addAddressesFromRecipientList(ExtendedEmailPublisher.java:706)
        at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:522)
        at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:304)
        at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:296)
        at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:256)
        at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:36)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:802)
        at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:774)
        at hudson.model.Build$BuildExecution.cleanUp(Build.java:192)
        at hudson.model.Run.execute(Run.java:1620)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
        at hudson.model.ResourceController.execute(ResourceController.java:88)
        at hudson.model.Executor.run(Executor.java:237)

s.a.grigoriev@gmail.com (JIRA)

unread,
May 4, 2013, 12:19:58 PM5/4/13
to jenkinsc...@googlegroups.com

scm_issue_link@java.net (JIRA)

unread,
May 4, 2013, 1:13:58 PM5/4/13
to jenkinsc...@googlegroups.com

Code changed in jenkins
User: Sergey Grigoriev
Path:
src/main/java/hudson/plugins/emailext/EmailRecipientUtils.java
http://jenkins-ci.org/commit/email-ext-plugin/51174890104c9a225577f01c2ed96e0f3177375e
Log:
Log a user's email to figure out why https://issues.jenkins-ci.org/browse/JENKINS-16332 happens.

scm_issue_link@java.net (JIRA)

unread,
May 4, 2013, 1:13:58 PM5/4/13
to jenkinsc...@googlegroups.com

jglick@cloudbees.com (JIRA)

unread,
May 7, 2013, 11:03:58 AM5/7/13
to jenkinsc...@googlegroups.com

Setting component to mailer based on comment suggesting that the extraction of the email resolver to a separate plugin somehow triggered this bug.

Change By: Jesse Glick (07/May/13 3:02 PM)
Component/s: mailer
Component/s: core

mr.wee.thomas@gmail.com (JIRA)

unread,
May 15, 2013, 6:52:58 PM5/15/13
to jenkinsc...@googlegroups.com
wee thomas commented on Bug JENKINS-16332

I've been experiencing this issue as well. I found that it occurs with my build-pipeline. Initially, a clone is made from an Hg repository. This then kicks off a build of the source. If successful, I archive the workspace and then I trigger another job (to run lint). This downstream job uses the saved successful workspace.

I've noticed that when I manually trigger builds within Jenkins, at that point, the email gets screwed up. This occurs with a fresh (1.514) Jenkins build with only the Mercurial and Clone Workspace plugins installed. This occurs whether I do it on the initial build job or the downstream lint job. I'd been doing this (triggering builds manually) to test job configuration. My current workaround is to make a small comment change in my source, commit and push. Both jobs have email user who broke the build as a post-build step.

I didn't experience this bug when experimenting with build configurations using a project on a subversion repository.

mr.wee.thomas@gmail.com (JIRA)

unread,
May 15, 2013, 6:54:58 PM5/15/13
to jenkinsc...@googlegroups.com
 
wee thomas edited a comment on Bug JENKINS-16332

I've been experiencing this issue as well. I found that it occurs with my build-pipeline. Initially, a clone is made from an Hg repository. This then kicks off a build of the source. If successful, I archive the workspace and then I trigger another job (to run lint). This downstream job uses the saved successful workspace.

I've noticed that when I manually trigger builds within Jenkins, at that point, the email gets screwed up. This occurs with a fresh (1.514) Jenkins build with only the Mercurial and Clone Workspace plugins installed. This occurs whether I do it on the initial build job or the downstream lint job. I'd been doing this (triggering builds manually) to test job configuration. My current workaround is to make a small comment change in my source, commit and push. Both jobs have email user who broke the build as a post-build step.

I didn't experience this bug when experimenting with build configurations using a project on a subversion repository.

To fix the phantom invalid user which Jenkins then recognizes for future SCM changes, I have to delete history of all builds that involve that user (if the build was successful, all jobs builds that it triggered), then restart Jenkins. At this point, the invalid user disappears and I can proceed. The other option is to just clone the jobs, then delete the old ones and rename them back. The downside of both approaches is that you lose a bit (or a lot) of build history.

mr.wee.thomas@gmail.com (JIRA)

unread,
May 15, 2013, 6:54:58 PM5/15/13
to jenkinsc...@googlegroups.com

I've been experiencing this issue as well. I found that it occurs with my build-pipeline. Initially, a clone is made from an Hg repository. This then kicks off a build of the source. If successful, I archive the workspace and then I trigger another job (to run lint). This downstream job uses the saved successful workspace.

I've noticed that when I manually trigger builds within Jenkins, at that point, the email gets screwed up. This occurs with a fresh (1.514) Jenkins build with only the Mercurial and Clone Workspace plugins installed. This occurs whether I do it on the initial build job or the downstream lint job. I'd been doing this (triggering builds manually) to test job configuration. My current workaround is to make a small comment change in my source, commit and push. Both jobs have email user who broke the build as a post-build step.

I didn't experience this bug when experimenting with build configurations using a project on a subversion repository.

To fix the phantom invalid user which Jenkins then recognizes for future SCM changes, I have to delete history of all builds that involve that user (if the build was successful, all jobs builds that it triggered), then restart Jenkins. At this point, the invalid user disappears and I can proceed. The other option is to just clone the jobs, then delete the old ones and rename them back (still requires a restart after this). The downside of both approaches is that you lose a bit (or a lot) of build history.

mr.wee.thomas@gmail.com (JIRA)

unread,
May 16, 2013, 7:21:58 PM5/16/13
to jenkinsc...@googlegroups.com
wee thomas commented on Bug JENKINS-16332

I should also indicate that my manual access of Jenkins is anonymous. While I've created accounts for all users in SCM, I don't actually login to Jenkins when making changes, manually triggering builds, etc.

cremoni@gmail.com (JIRA)

unread,
May 24, 2013, 3:22:58 AM5/24/13
to jenkinsc...@googlegroups.com

We are also using Mercurial and have the same problem. We log in to Jenkins to run jobs.

IT has asked us to turn off email notifications because the bad email addresses are choking our servers.

peter@peterbecker.de (JIRA)

unread,
Jun 2, 2013, 9:32:58 PM6/2/13
to jenkinsc...@googlegroups.com

We are using Mercurial as well, having normal looking commits on that end. Jenkins 1.506 adds underscores to some but not all email addresses.

In one build two out of three email addresses failed. They all look the same in hg, the one big different is that the two failing ones belong to users with Jenkins accounts, the one that works belongs to a user that never created a Jenkins account. The user profiles in the Jenkins installation look fine, the addresses in there seem to be ok. The person that gets the build notification does not have a profile at all.

One thing we noticed is that there are two additional user profiles in the file system that follow the pattern "FirstName LastName email@address" as folder names. These are about a month old now and belong to other users, both of which have a normal profile as well. I don't know if that is related somehow.

peter@peterbecker.de (JIRA)

unread,
Jun 3, 2013, 7:16:58 PM6/3/13
to jenkinsc...@googlegroups.com
 
Peter Becker edited a comment on Bug JENKINS-16332

We are using Mercurial as well, having normal looking commits on that end. Jenkins 1.506 adds underscores to some but not all email addresses.

In one build two out of three email addresses failed. They all look the same in hg, the one big different is that the two failing ones belong to users with Jenkins accounts, the one that works belongs to a user that never created a Jenkins account. The user profiles in the Jenkins installation look fine, the addresses in there seem to be ok. The person that gets the build notification does not have a profile at all.

One thing we noticed is that there are two additional user profiles in the file system that follow the pattern FirstName LastName _email@address_ as folder names. These are about a month old now and belong to other users, both of which have a normal profile as well. I don't know if that is related somehow.

peter@peterbecker.de (JIRA)

unread,
Jun 3, 2013, 7:20:57 PM6/3/13
to jenkinsc...@googlegroups.com

Upgrading to 1.509.1 seems to have resolved this issue for us. The one thing we did notice while looking at this is that it was not actually just adding underscores to the email addresses, it was using the whole Mercurial username with the lesser than/greater than symbols replaced. For example Peter Becker <pbe...@example.com> should have turned into pbe...@example.com but resulted in Peter Becker _pbe...@example.com_ being used as email address.

s.a.grigoriev@gmail.com (JIRA)

unread,
Jun 24, 2013, 5:45:58 AM6/24/13
to jenkinsc...@googlegroups.com

gpjerrymaloney@gmail.com (JIRA)

unread,
Jun 26, 2013, 10:48:58 PM6/26/13
to jenkinsc...@googlegroups.com

I believe there may be an issue in MercurialChangeLogParser method MercurialChangeSetList parse(AbstractBuild build, File changelogFile). If I pass in a changelog that looks like the following:

changelog.xml
<?xml version='1.0' encoding='UTF-8'?>
<changesets>
<changeset author='joe.schmo &lt;joe....@example.com&gt;'/> <!-- note that those escape characters are on purpose and not some relic of posting in Jira -->
</changesets>

I get a changeset author with the ID and fullname "joe.schmo _joe....@example.com_", which is the error reported in this ticket. I believe the Digester class from Apache Commons is taking the escaped XML characters in the changesets/changeset/@author attribute and rendering them as underscores.

I pushed a unit test showing this to my fork of mercurial-plugin, but not requesting a pull because I don't have a fix yet.

goodspeedj@comcast.net (JIRA)

unread,
Nov 21, 2013, 10:47:59 AM11/21/13
to jenkinsc...@googlegroups.com

If it helps I am also seeing this using 1.537 on Windows with RTC as my SCM tool along with the email-ext plugin. Editing the people (these are not real users, they are picked up from SCM changes) to fix the email address seems to fix the issue for a short period of time, but the records are being updated again intermittently.

jglick@cloudbees.com (JIRA)

unread,
Nov 21, 2013, 11:55:58 AM11/21/13
to jenkinsc...@googlegroups.com
Jesse Glick commented on Bug JENKINS-16332

@jgoodspeed it helps if you can reproduce the problem and are willing to run the logger (FINE in hudson.model.User).

cowwoc@java.net (JIRA)

unread,
Dec 19, 2013, 1:46:37 PM12/19/13
to jenkinsc...@googlegroups.com
cowwoc commented on Bug JENKINS-16332

Jesse,

I just reproduced the problem. Unfortunately I didn't have the logger enabled so we missed an opportunity.

I did notice something very interesting though:

1. A build failed and tried to send an email to an auto-generated user with underscores
2. I went into Jenkins -> People and sure enough the user's email address had underscores
3. I rebooted Jenkins and went into Manage Jenkins -> Manage Users and all of a sudden that same user no longer had underscores in the email address.

It's not clear whether the reboot or Manage Users fixed the email address, but that's another clue of what's going on. I've enabled the logger, so the next time this happens I will catch it.

jglick@cloudbees.com (JIRA)

unread,
Dec 19, 2013, 3:41:37 PM12/19/13
to jenkinsc...@googlegroups.com
Jesse Glick commented on Bug JENKINS-16332

If you figure out how to reproduce it from scratch then I can fix it. I am pretty sure the problem somehow lies with a userId getting passed from one place to another without a User context, and then Jenkins serializing the user record at the wrong time, but I do not know the sequence of events that makes this happen to some people some times.

cowwoc@java.net (JIRA)

unread,
Jan 8, 2014, 6:43:38 PM1/8/14
to jenkinsc...@googlegroups.com
cowwoc commented on Bug JENKINS-16332

Jesse,

I triggered a build that failed, and tried emailing the author:

Invalid address: First Last _firs...@gmail.com_

I opened the logger and saw these two lines:

Jan 08, 2014 6:36:06 PM FINE hudson.model.User
hudson.model.User$FullNameIdResolver@934e9b mapped First Last _firs...@gmail.com_ to First Last _firs...@gmail.com_
Jan 08, 2014 6:36:06 PM FINE hudson.model.User
hudson.model.User$FullNameIdResolver@934e9b mapped First Last _firs...@gmail.com_ to First Last _firs...@gmail.com_

(I've replaced the person's actual name with "First Last" but the rest of the log is identical)

Does this help? Where do we go from here?

jglick@cloudbees.com (JIRA)

unread,
Jan 9, 2014, 12:14:39 PM1/9/14
to jenkinsc...@googlegroups.com
Jesse Glick commented on Bug JENKINS-16332

@cowwoc so something called

User.get("First Last _firs...@gmail.com_")
which is OK, but there was already a User which had that not only as an id but also as a fullName, which is wrong. The question is how and when that User got created, which this log snippet does not indicate. To learn that, we would need an (earlier) log message starting with
[JENKINS-16332] Suspicious fullName being stored: First Last _firs...@gmail.com_
which includes a stack trace possibly indicating the culprit.

cowwoc@java.net (JIRA)

unread,
Jan 9, 2014, 1:09:37 PM1/9/14
to jenkinsc...@googlegroups.com
cowwoc commented on Bug JENKINS-16332

I didn't see such a log entry but I will keep my eye open if this happens again.

Mail-Ext just committed an interesting bugfix: https://issues.jenkins-ci.org/browse/JENKINS-20215

Do you think this could have been at fault?

cowwoc@java.net (JIRA)

unread,
Jan 9, 2014, 1:11:37 PM1/9/14
to jenkinsc...@googlegroups.com
 
cowwoc edited a comment on Bug JENKINS-16332

I didn't see such a log entry but I will keep my eye open if this happens again.

The EMail-ext plugin just fixed an interesting bug: https://issues.jenkins-ci.org/browse/JENKINS-20215

Do you think this could have been at fault?

jglick@cloudbees.com (JIRA)

unread,
Jan 9, 2014, 1:50:37 PM1/9/14
to jenkinsc...@googlegroups.com

cowwoc@java.net (JIRA)

unread,
Jan 9, 2014, 2:50:37 PM1/9/14
to jenkinsc...@googlegroups.com
cowwoc commented on Bug JENKINS-16332

Okay, so to reiterate, I did not see

[JENKINS-16332] Suspicious fullName being stored: First Last _firs...@gmail.com_

in the log file even though the problem occurred. Doesn't that imply that we need to add more logs?

jglick@cloudbees.com (JIRA)

unread,
Jan 9, 2014, 3:42:39 PM1/9/14
to jenkinsc...@googlegroups.com
Jesse Glick commented on Bug JENKINS-16332

Doesn't that imply that we need to add more logs?

Not necessarily; you might have turned on logging after this user record ($JENKINS_HOME/users/*.xml) was created with the faulty information.

cowwoc@java.net (JIRA)

unread,
Jan 9, 2014, 5:05:37 PM1/9/14
to jenkinsc...@googlegroups.com
cowwoc commented on Bug JENKINS-16332

@Jesse,

I enabled this log a few weeks ago, so that's unlikely. That being said, the log did seem pretty short (2 pages long).

  1. Does Jenkins truncate the log on startup?
  2. Does it begin logging automatically or do I need to intervene manually every startup?
  3. Does it log to disk or just to memory?

jglick@cloudbees.com (JIRA)

unread,
Jan 9, 2014, 5:09:37 PM1/9/14
to jenkinsc...@googlegroups.com
Jesse Glick commented on Bug JENKINS-16332

The log displayed in /log/all is just the last hundred or so messages in memory (since Jenkins was started). Depending on how you launch Jenkins, typically a log file will be written somewhere to disk.

jglick@cloudbees.com (JIRA)

unread,
Jan 9, 2014, 5:11:37 PM1/9/14
to jenkinsc...@googlegroups.com

And custom loggers are normally not written to disk at all. I have an unreleased change in the Support Core plugin which writes custom logs to a location inside the Jenkins home dir (rotated after restart). Plan to release that update soonish.

toomasr@java.net (JIRA)

unread,
Feb 19, 2014, 10:59:39 AM2/19/14
to jenkinsc...@googlegroups.com
 
toomasr edited a comment on Bug JENKINS-16332

Experiencing similar problem. Unable to send out the emails to the build failed culprits. I went checked out the relevant code in Jenkins, Mercurial plugin and the Mailer plugin. Here is my understanding based on the read source code:

Mercurial states that the author format is FirstName LastName <email@address_ ( see http://www.selenic.com/mercurial/hgrc.5.html )

Now the mercurial plugin sees the author part with that format and asks Jenkins to get a user or create one by indirectly invoking https://github.com/jenkinsci/jenkins/blob/master/core/src/main/java/hudson/model/User.java#L298

During the creation Jenkins will introduce some replacing ( https://github.com/jenkinsci/jenkins/blob/master/core/src/main/java/jenkins/model/DefaultUserCanonicalIdResolver.java#L44 ) and all < and > turn into underscores.

And now we've created a Jenkins user FirstName LastName _email@address_. Not sure why we want to do this but probably a good thing for later to pick up the culprits.

Now a build fails and Mailer plugin asks Jenkins to give him the culprits. Jenkins has recorded those users for the build and provides the list of FirstName Lastname _email@address_ users.

Now Mailer asks for the addresses of the users but as those are empty it will use a MailAddressResolver ( https://github.com/jenkinsci/mailer-plugin/blob/master/src/main/java/hudson/tasks/MailAddressResolver.java#L100 - there is a specific subclass for Subversion also but didn't sis Mercurial) and it will do some magic but probably fails because Mailer still tries to send to FirstName Lastname _email@address_.

I see couple of options here

  • Mailer plugin(s) to detect the emails better when none is defined
  • Mercurial plugin will do the email address extraction itself, as it knows the format and will then set explicitly the email addresses for the users it creates
  • Mercurial plugin will create the user with the email address instead of the FirstName LastName <email@address> format. In this case any dark magic that does email address extraction from user id might succeed.

Any holes in my logic? Anyone wants to take crack at it? I'm off to vacation without a laptop

toomasr@java.net (JIRA)

unread,
Feb 19, 2014, 11:01:39 AM2/19/14
to jenkinsc...@googlegroups.com

Experiencing similar problem. Unable to send out the emails to the build failed culprits. I went checked out the relevant code in Jenkins, Mercurial plugin and the Mailer plugin. Here is my understanding based on the read source code:

Mercurial states that the author format is FirstName LastName <email@address> ( see http://www.selenic.com/mercurial/hgrc.5.html )

Now the mercurial plugin sees the author part with that format and asks Jenkins to get a user or create one by indirectly invoking https://github.com/jenkinsci/jenkins/blob/master/core/src/main/java/hudson/model/User.java#L298

During the creation Jenkins will introduce some replacing ( https://github.com/jenkinsci/jenkins/blob/master/core/src/main/java/jenkins/model/DefaultUserCanonicalIdResolver.java#L44 ) and all < and > turn into underscores.

And now we've created a Jenkins user FirstName LastName _email@address_. Not sure why we want to do this but probably a good thing for later to pick up the culprits.

Now a build fails and Mailer plugin asks Jenkins to give him the culprits. Jenkins has recorded those users for the build and provides the list of FirstName Lastname _email@address_ users.

Now Mailer asks for the addresses of the users but as those are empty it will use a MailAddressResolver ( https://github.com/jenkinsci/mailer-plugin/blob/master/src/main/java/hudson/tasks/MailAddressResolver.java#L100 - there is a specific subclass for Subversion also but didn't sis Mercurial) and it will do some magic but probably fails because Mailer still tries to send to FirstName Lastname _email@address_.

I see couple of options here

  • Mailer plugin(s) to detect the emails better when none is defined
  • Mercurial plugin will do the email address extraction itself, as it knows the format and will then set explicitly the email addresses for the users it creates
  • Mercurial plugin will create the user with the email address instead of the FirstName LastName <email@address> format. In this case any dark magic that does email address extraction from user id might succeed.

Any holes in my logic? Anyone wants to take crack at it? I'm off to vacation without a laptop

cowwoc@java.net (JIRA)

unread,
Feb 19, 2014, 5:06:38 PM2/19/14
to jenkinsc...@googlegroups.com
cowwoc commented on Bug JENKINS-16332

Jesse,

I am now 100% I am seeing:

Jan 08, 2014 6:36:06 PM FINE hudson.model.User
hudson.model.User$FullNameIdResolver@934e9b mapped First Last _firs...@gmail.com_ to First Last _firs...@gmail.com_

without:

[JENKINS-16332] Suspicious fullName being stored: First Last _firs...@gmail.com_

ever being logged. It looks like you'll need to add more aggressive logging for us to track this down.

jglick@cloudbees.com (JIRA)

unread,
Feb 19, 2014, 5:22:39 PM2/19/14
to jenkinsc...@googlegroups.com
Jesse Glick commented on Bug JENKINS-16332

If that never gets logged, and you are still unsure how to reproduce the problem, then I am out of ideas for the moment.

slide.o.mix@gmail.com (JIRA)

unread,
Feb 22, 2014, 11:32:39 PM2/22/14
to jenkinsc...@googlegroups.com

slide.o.mix@gmail.com (JIRA)

unread,
Feb 22, 2014, 11:43:38 PM2/22/14
to jenkinsc...@googlegroups.com

cowwoc@java.net (JIRA)

unread,
Feb 23, 2014, 1:06:39 AM2/23/14
to jenkinsc...@googlegroups.com

Guys,

I've managed to produce a minimal testcase for this bug.

  1. Extract testcase.zip into $JENKINS_HOME/jobs
  2. Run the job

You should get this output:

Started by user Gili Tzabari
[EnvInject] - Loading node environment variables.
Building remotely on MacOS X 10.8 in workspace /Users/builds/.jenkins/workspace/Test
[Test] $ /usr/local/bin/hg showconfig paths.default
ERROR: Workspace reports paths.default as https://bbs.darktech.org/code/test/
which looks different than https://cow...@bitbucket.org/cowwoc/test
so falling back to fresh clone rather than incremental update
$ /usr/local/bin/hg clone --rev default --noupdate https://cow...@bitbucket.org/cowwoc/test /Users/builds/.jenkins/workspace/Test

adding changesets
adding manifests
adding file changes
added 19 changesets with 19 changes to 2 files
[Test] $ /usr/local/bin/hg update --rev default
2 files updated, 0 files merged, 0 files removed, 0 files unresolved
[Test] $ /usr/local/bin/hg log --rev . --template {node}
[Test] $ /usr/local/bin/hg log --rev . --template {rev}
[Test] $ /usr/local/bin/hg log --rev 6ddb7626f1d05f3e67a4c92fa255ba32a5406020
changeset:   18:6ddb7626f1d0
tag:         tip
user:        Getcho Getchev <getcho....@gmail.com>
date:        Fri Feb 21 23:40:41 2014 +0200
summary:     added line 10

[Test] $ /usr/local/bin/hg log --template "<changeset node='{node}' author='{author|xmlescape}' rev='{rev}' date='{date}'><msg>{desc|xmlescape}</msg><added>{file_adds|stringify|xmlescape}</added><deleted>{file_dels|stringify|xmlescape}</deleted><files>{files|stringify|xmlescape}</files><parents>{parents}</parents></changeset>\n" --rev default:0 --follow --prune 6ddb7626f1d05f3e67a4c92fa255ba32a5406020 --encoding UTF-8 --encodingmode replace

[Test] $ /bin/sh -xe /var/folders/ht/zq3sdm6s55j4cv6gvjtkc8vm0000gp/T/hudson4438504154854395225.sh
+ ./test.sh
/var/folders/ht/zq3sdm6s55j4cv6gvjtkc8vm0000gp/T/hudson4438504154854395225.sh: line 2: ./test.sh: No such file or directory
Build step 'Execute shell' marked build as failure
Invalid address: Getcho Getchev _getcho...@gmail.com_
Invalid address: Gili Tzabari _gili....@gmail.com_
An attempt to send an e-mail to empty list of recipients, ignored.

Finished: FAILURE
Change By: cowwoc (23/Feb/14 6:05 AM)
Attachment: testcase.zip

slide.o.mix@gmail.com (JIRA)

unread,
Feb 23, 2014, 12:23:41 PM2/23/14
to jenkinsc...@googlegroups.com
Alex Earl commented on Bug JENKINS-16332

I submitted a pull request for "fixing" this.

https://github.com/jenkinsci/mailer-plugin/pull/11

I'm also planning on making a pull request for the Mercurial plugin that would create user accounts a little differently.

jglick@cloudbees.com (JIRA)

unread,
Feb 23, 2014, 12:51:38 PM2/23/14
to jenkinsc...@googlegroups.com
Jesse Glick commented on Bug JENKINS-16332

Your test case is reproducible but it does not really tell us anything, because the malformed culprits are simply being copied from earlier builds (#2 & #5). What is needed is a test case which demonstrates fresh additions to the culprits list with the malformed names; specifically the call stack of User.<init> with an incorrect fullName. Note that the Mercurial changelog.xml in these builds show the correct text.

slide.o.mix@gmail.com (JIRA)

unread,
Feb 23, 2014, 1:00:38 PM2/23/14
to jenkinsc...@googlegroups.com
Alex Earl commented on Bug JENKINS-16332

@Jesse, I agree it should be calling it with the <>'s, but I think because of this code in AbstractBuild.java, it will call it with the _'s

https://github.com/jenkinsci/jenkins/blob/master/core/src/main/java/hudson/model/AbstractBuild.java#L729

jglick@cloudbees.com (JIRA)

unread,
Feb 23, 2014, 1:02:38 PM2/23/14
to jenkinsc...@googlegroups.com
Jesse Glick commented on Bug JENKINS-16332

Still working on reproducing from scratch. I think I may see what the issue is. If I am right, it is a bug in core as I suspected on Dec 19.

jglick@cloudbees.com (JIRA)

unread,
Feb 23, 2014, 1:23:40 PM2/23/14
to jenkinsc...@googlegroups.com

OK, finally reproduced. The mentioned line 729 is innocent, and really AbstractBuild as a whole is doing nothing wrong; nor, as far as I can tell, are the Mailer or Mercurial plugins.

The problem (as I surmised on Sep 16) is in User itself. When you run a build that fails, and it has a changelog mentioning at least one user with full name & email address who does not yet have any permanent record in $JENKINS_HOME/users/$id/config.xml, the build stores a culprits field listing the user’s ID, which correctly includes underscores. So long as Jenkins remains running, the loaded User object is fine, and mailing would work. However if you restart Jenkins, and then run a new build that again fails, but with no changelog this time, getCulprits inherits the culprits list from the previous build. This time User.get(id) is called and since there is no persistent record for that user, there is no way of reconstructing the proper fullName—we only have the sanitized ID. Therefore the User is constructed with a bogus fullName and mailing fails.

Looking into a fix.

jglick@cloudbees.com (JIRA)

unread,
Feb 23, 2014, 1:23:40 PM2/23/14
to jenkinsc...@googlegroups.com
Change By: Jesse Glick (23/Feb/14 6:23 PM)
Labels: user
Assignee: Jesse Glick
Component/s: core
Component/s: mailer

jglick@cloudbees.com (JIRA)

unread,
Feb 23, 2014, 1:23:41 PM2/23/14
to jenkinsc...@googlegroups.com

jglick@cloudbees.com (JIRA)

unread,
Feb 23, 2014, 1:23:41 PM2/23/14
to jenkinsc...@googlegroups.com

slide.o.mix@gmail.com (JIRA)

unread,
Feb 23, 2014, 2:01:40 PM2/23/14
to jenkinsc...@googlegroups.com
Alex Earl commented on Bug JENKINS-16332

Jesse, I just like to poke at these until you come up with the correct solution

jglick@cloudbees.com (JIRA)

unread,
Feb 23, 2014, 5:45:38 PM2/23/14
to jenkinsc...@googlegroups.com

scm_issue_link@java.net (JIRA)

unread,
Feb 23, 2014, 7:10:39 PM2/23/14
to jenkinsc...@googlegroups.com

Code changed in jenkins
User: Jesse Glick
Path:
changelog.html
core/src/main/java/hudson/model/User.java
test/src/test/java/hudson/model/UserTest.java
http://jenkins-ci.org/commit/jenkins/fdda9ca65689423794a8378c1f28faca7dffddf0
Log:
[FIXED JENKINS-16332] Ensure that User records are saved when the fullName is not recoverable from the id.
Otherwise User.get(id).getFullName() after restarting Jenkins will produce the wrong result.

scm_issue_link@java.net (JIRA)

unread,
Feb 23, 2014, 7:10:40 PM2/23/14
to jenkinsc...@googlegroups.com
Change By: SCM/JIRA link daemon (24/Feb/14 12:10 AM)
Status: In Progress Resolved
Resolution: Fixed

dogfood@java.net (JIRA)

unread,
Feb 24, 2014, 6:55:01 PM2/24/14
to jenkinsc...@googlegroups.com
dogfood commented on Bug JENKINS-16332

Integrated in jenkins_main_trunk #3192
[FIXED JENKINS-16332] Ensure that User records are saved when the fullName is not recoverable from the id. (Revision fdda9ca65689423794a8378c1f28faca7dffddf0)

Result = SUCCESS
Jesse Glick : fdda9ca65689423794a8378c1f28faca7dffddf0
Files :

  • test/src/test/java/hudson/model/UserTest.java
  • changelog.html
  • core/src/main/java/hudson/model/User.java

cowwoc@java.net (JIRA)

unread,
Feb 25, 2014, 10:22:59 AM2/25/14
to jenkinsc...@googlegroups.com
cowwoc commented on Bug JENKINS-16332

Jesse,

Will this fix jobs where malformed culprits were being copied from earlier builds, or do we need to manually "flush" the job history somehow?

jglick@cloudbees.com (JIRA)

unread,
Feb 25, 2014, 10:58:59 AM2/25/14
to jenkinsc...@googlegroups.com
Jesse Glick commented on Bug JENKINS-16332

This fix will not handle all cases involving historical records. If a new build is run after upgrade whose changelog mentions the given committer’s full name, that name will be properly registered and you should not see the problem for that user again. The main problem I can foresee is a build which was failing at the time of upgrade, and continues to fail without new changes being committed (to that or other jobs developed by the same people), and is using an email trigger configured to repeatedly send mail for every unstable build.

Again there are no “malformed” culprits fields here. The culprits list is correct; the problem only arises when the culprits list contains the only record of a given user in the system. You ought to be able to work around the problem for a given user by visiting that user’s page as hyperlinked from a changelog (logged in as an administrator), and explicitly setting a full name (and/or email address).

cowwoc@java.net (JIRA)

unread,
Feb 25, 2014, 11:28:59 AM2/25/14
to jenkinsc...@googlegroups.com
cowwoc commented on Bug JENKINS-16332

I see. So just to make sure I understand correctly:

Until a user makes a new commit, any existing jobs will keep on using the incorrect email address. Once a user makes a new commit, his email address will get corrected system-wide across all jobs. Alternatively, deleting the contents of the "builds" directory will remove all changelogs and force re-evaluation of the email address.

Is that correct?

jglick@cloudbees.com (JIRA)

unread,
Feb 25, 2014, 11:40:00 AM2/25/14
to jenkinsc...@googlegroups.com
Jesse Glick commented on Bug JENKINS-16332

Until a user makes a new commit, any existing jobs will keep on using the incorrect email address. Once a user makes a new commit, his email address will get corrected system-wide across all jobs.

Right. You can simply look in $JENKINS_HOME/users/ to see whether the user has been defined or not.

deleting the contents of the "builds" directory will remove all changelogs and force re-evaluation of the email address.

No. If you deleted all historical builds, then either the next build has commits from the relevant user(s), in which case their email addresses will be recorded; or it does not, in which case the culprits list for that build will simply be empty and no email will be sent (unless you have an unconditional recipient configured in the job). In the former case, deleting the old build records does not improve your situation at all. In the latter case, deleting them could make the new build’s status be “unstable” due to test failures or whatever, rather than “failed” due to an attempt to send mail to bogus addresses, but the email addresses of users mentioned in those old builds would still be missing.

It is loading more messages.
0 new messages