Hieu Nguyen added the comment:

I've changed the From address in rietveld to match the solution in roundup, so 
basically it will send from the same address as roundup.

----------
nosy: +hieu.nguyen

_______________________________________________________
PSF Meta Tracker <metatrac...@psf.upfronthosting.co.za>
<http://psf.upfronthosting.co.za/roundup/meta/issue554>
_______________________________________________________
diff -r 894c83f36cb7 codereview/views.py
--- a/codereview/views.py       Tue Jun 24 06:11:43 2014 +0300
+++ b/codereview/views.py       Tue Oct 28 17:04:45 2014 +0200
@@ -3253,7 +3253,11 @@
     body = django.template.loader.render_to_string(
       template, context, context_instance=RequestContext(request))
     logging.warn('Mail: to=%s; cc=%s', ', '.join(to), ', '.join(cc))
-    send_args = {'sender': my_email,
+    from_email = '{} <{}>'.format(
+      request.user.get_full_name(),
+      django_settings.TRACKER_EMAIL
+    )
+    send_args = {'sender': _encode_safely(from_email),
                  'to': [_encode_safely(address) for address in to],
                  'subject': _encode_safely(subject),
                  'body': _encode_safely(body),
diff -r 894c83f36cb7 settings.py
--- a/settings.py       Tue Jun 24 06:11:43 2014 +0300
+++ b/settings.py       Tue Oct 28 17:04:45 2014 +0200
@@ -126,3 +126,6 @@
 
 # This won't work with gae2django.
 RIETVELD_INCOMING_MAIL_ADDRESS = None
+
+# default From: address
+TRACKER_EMAIL = _c.get('tracker', 'email')
_______________________________________________
Tracker-discuss mailing list
Tracker-discuss@python.org
https://mail.python.org/mailman/listinfo/tracker-discuss

Reply via email to