Edgewall Software
Modify

Opened 16 years ago

Closed 16 years ago

Last modified 8 years ago

#7107 closed defect (worksforme)

Gmail does not work

Reported by: jayunit100@… Owned by: Jonas Borgström
Priority: normal Milestone:
Component: general Version:
Severity: normal Keywords: needinfo
Cc: Branch:
Release Notes:
API Changes:
Internal Changes:

Description (last modified by Emmanuel Blot)

Hi Guys : Ive searched many forums and have not found a way to get gmail to work.

Ive posted my config code at the bottom, and am reporting this as a trac bug because trac hangs for SMTP failures of certain types…

Could somebody in the process of looking at this ticket suggest a fix to my specific problem as well ? Im desperate

This IS a bug in trac, because the ticketing system actually freezes and does not respond if notification fails.

Even if gmail servers are not configured for SMTP correctly, I still believe this is a serious trac flaw, since no immediate response is recieved from the trac server, and since there is also the possibility that no logging is done regarding SMTP connections.

I know that for some SMTP errors, trac does issue a proper log… But for this one it doesnt…

ERROR: Failure sending notification on creation of ticket #90: (10054, 'Connection reset by peer')

[notification]
admit_domains =
always_notify_owner = true
always_notify_reporter = true
always_notify_updater = true
ignore_domains =
mime_encoding = base64
smtp_always_bcc =
smtp_always_cc =
smtp_default_domain =
smtp_enabled = true
smtp_from =name@gmail.com
smtp_from_name =name@gmail.com
smtp_password =p1as1
smtp_port =465
smtp_replyto = name@gmail.com
smtp_server = smtp.gmail.com
smtp_subject_prefix = __default__
smtp_user = name@gmail.com
ticket_subject_template = $prefix #$ticket.id: $summary
use_public_cc = false
use_short_addr = false
use_tls = true

Attachments (0)

Change History (3)

in reply to:  description comment:1 by Emmanuel Blot, 16 years ago

Description: modified (diff)
Keywords: needinfo added
Resolution: worksforme
Status: newclosed

Replying to jayunit100@gmail.com:

Hi Guys : Ive searched many forums and have not found a way to get gmail to work.

Probably not the MailingList archive, as this topic has already been answered a couple of time.
Also, please re-read the instruction about how to report a "bug": you did not fill the version field, you did not fill the compoment field.
Please also use verbatim blocks ({{{ ... }}})) for pasting your config file and preview your ticket before submitting it.

Ive posted my config code at the bottom, and am reporting this as a trac bug because trac hangs for SMTP failures of certain types…

Did you use a real GMail account (i.e. have you obfuscated the smtp_user parameter with name@…)?

This IS a bug in trac, because the ticketing system actually freezes and does not respond if notification fails.

No, this works as expected: SMTP transmission is synchronous with the web request.

Even if gmail servers are not configured for SMTP correctly, I still believe this is a serious trac flaw, since no immediate response is recieved from the trac server, and since there is also the possibility that no logging is done regarding SMTP connections.

Agreed, the SMTP connection errors are hard to debug (I believe this enhancement has already been requested)

Feel free to re-open the ticket if you can provide the required info (Trac version, user name information, …)

comment:2 by Emmanuel Blot, 16 years ago

I've double-checked with the current trunk, it works fine with GMail SMTP server, as long as smtp_port is set to either:

  • 25: SMTP, accepting TLS
  • 587: SMTP, accepting TLS, used for submitting message - not routing.

It does not work with port 465, which is dedicated to SMTPS.
SMTPS is not supported by Trac.

Google mail documentation is quite confusing on this point at best.

Port 25

$> telnet smtp.gmail.com 25
Trying 64.233.183.109...
Connected to gmail-smtp.l.google.com.
Escape character is '^]'.
220 mx.google.com ESMTP 31sm22614433nfu.24
EHLO example.com
250-mx.google.com at your service, [88.178.161.22]
250-SIZE 28311552
250-8BITMIME
250-STARTTLS
250 ENHANCEDSTATUSCODES

Port 587

$> telnet smtp.gmail.com 587
Trying 64.233.183.109...
Connected to gmail-smtp.l.google.com.
Escape character is '^]'.
220 mx.google.com ESMTP d23sm22654717nfh.12
EHLO example.com
250-mx.google.com at your service, [88.178.161.22]
250-SIZE 28311552
250-8BITMIME
250-STARTTLS
250 ENHANCEDSTATUSCODES
QUIT
221 2.0.0 mx.google.com closing connection d23sm22654717nfh.12
Connection closed by foreign host.

Port 465

> telnet smtp.gmail.com 465
Trying 64.233.183.109...
Connected to gmail-smtp.l.google.com.
Escape character is '^]'.
EHLO example.com
Connection closed by foreign host.

Observe the response for port 465: connection is aborted immediately. Port 465 is not for STARTTLS, it is likely for SMTPS.

comment:3 by Emmanuel Blot, 16 years ago

I've added a small section for GMail-based notification here: TracNotification#UsingGMailastheSMTPrelayhost

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Jonas Borgström.
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from Jonas Borgström to the specified user.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.