Opened 7 years ago

Closed 4 weeks ago

#7824 closed defect (wontfix)

To: field gets set to "email_to value"@trac.server.domain

Reported by: anonymous Owned by:
Priority: normal Component: AnnouncerPlugin
Severity: normal Keywords: email notification
Cc: Jan Beilicke, Jochen Ulrich Trac Release: 0.12


In distributors/, the value of the 'To' header is inexplicably placed inside quotation marks. This causes it to end up being appended by the Trac server’s domain.

Attachments (1)

announcerplugin-to-header.diff (732 bytes) - added by Chris Shelton 6 years ago.
diff to allow To header to be undisclosed-recipients: ;

Download all attachments as: .zip

Change History (18)

comment:1 Changed 7 years ago by anonymous

I suspect that this has something to do with the DefaultDomainResolver. If you don't need it, disable it. I'll try to get this fixed. Can you paste your settings and explain exactly where email_to value is entered?

Last edited 4 years ago by Ryan J Ollos (previous) (diff)

comment:2 Changed 7 years ago by anonymous

DefaultDomainResolver is already disabled on our installation. The email_to value was entered in trac.ini as:

email_address_resolvers = SpecifiedEmailResolver,SessionEmailResolver
email_enabled = true
email_sender = SendmailEmailSender
email_to =
mime_encoding = qp
never_notify_updater = true
subscription_resolvers = SubscriptionResolver
use_threaded_delivery = true

Currently, I’ve modified the our code to stop adding quotation marks and modified the part that checked for a match against a quoted version of undisclosed-recipients: ; and it is working fine.

comment:3 Changed 6 years ago by Chris Shelton

I have noticed the exact same behavior on a new install of trac 0.12, using the svn version of the announcerplugin (as of r9404). After a little bit of digging in the code, I implemented a similar patch as described in comment:2.

Last edited 4 years ago by Ryan J Ollos (previous) (diff)

Changed 6 years ago by Chris Shelton

diff to allow To header to be undisclosed-recipients: ;

comment:4 Changed 6 years ago by Jan Beilicke

Cc: Jan Beilicke added; anonymous removed

comment:5 Changed 5 years ago by Ryan J Ollos

#8462 might be a duplicate.

comment:6 Changed 5 years ago by Jochen Ulrich

Cc: Jochen Ulrich added

comment:7 Changed 4 years ago by Steffen Hoffmann

Keywords: email notification added
Owner: changed from Robert Corsaro to Steffen Hoffmann

I think the following change should have resolved the issue, that has been reported and discussed here:

(In [12326]) TracAnnouncer: Don't attempt email distribution without recipients, refs #7834.

Felt like a re-arranged and slightly simplified code would make it easier to implement the requested check in EmailDistributor._do_send. IMHO it did.

The problematic check, that has a suggested patch here, is done differently now - before setting the headers, so quotation shouldn't cause issues anymore. Test feedback appreciated.

comment:8 Changed 4 years ago by bas.vandervlies@…

I just installed the trunk version and also have this problem. The domain is appended to the to-field. Is there a fix for it?

comment:9 Changed 4 years ago by Ryan J Ollos

Please post your sanitized [announcer] configuration and I will try to reproduce with the latest version of the AnnouncerPlugin code.

comment:10 Changed 4 years ago by bas.vandervlies@…

just back from holidays:

announcer.* = enabled
announcer.resolvers.defaultdomainemailresolver = disabled
announcer.resolvers.specifiedemailresolver = disabled

always_notify_cc = true
always_notify_component_owner = true
default_email_format = text/plain
email_address_resolvers = SessionEmailResolver
email_always_cc = bas.van.der.vlies@...
email_enabled = true
email_from =
email_from_name = Email2Trac Test
email_replyto = bvlies@...
email_sender = SmtpEmailSender
email_to = linux-tg@...
use_threaded_delivery = true

debuglevel = 100
port = 25
server = localhost
timeout = 10

comment:11 Changed 4 years ago by bas.vandervlies@…

Still have the problem that the to addres is wrong:

  • linux-tg@…"

Has somebody a patch for it?

comment:12 Changed 4 years ago by anonymous

I found out the problem. I have installed postfix as MTA and the announcer puts quotes around the to field. So it is considered as string. The patch below fixes the problem

  • announcer/distributors/

    416416            if == self.to_default:
    417417                headers['To'] = _('undisclosed-recipients: ;')
    418418            else:
    419                 headers['To'] = '"%s"' %
     419                headers['To'] = '%s' %
    420420                if
    421421                    recip_adds += []
    422422        if not recip_adds:
Last edited 3 years ago by Ryan J Ollos (previous) (diff)

comment:13 Changed 3 years ago by Tiago Teresa Teodósio

This patch worked for me, thanks!

comment:14 Changed 3 years ago by bas.vandervlies@…

I'll hope that they release a new version or is the development stopped?

comment:15 Changed 3 years ago by Ryan J Ollos

At the very least, development has been paused for far too long.

hasienda: do you have an opinion on the patch in comment:12? I'd be happy to do some additional testing and push it.

comment:16 Changed 5 months ago by Ryan J Ollos

Owner: Steffen Hoffmann deleted

comment:17 Changed 4 weeks ago by Ryan J Ollos

Resolution: wontfix
Status: newclosed

Please upgrade to Trac 1.2, which has integrated the core of AnnouncerPlugin. Please raise the issue on the trac:MailingList if you encounter the issue with Trac 1.2.

Modify Ticket

Change Properties
Set your email in Preferences
as closed The ticket will remain with no owner.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment

E-mail address and name can be saved in the Preferences.

Note: See TracTickets for help on using tickets.