Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Document the notif_from config parameter #2326

Closed
tanius opened this issue Jul 2, 2017 · 3 comments
Closed

Document the notif_from config parameter #2326

tanius opened this issue Jul 2, 2017 · 3 comments

Comments

@tanius
Copy link

tanius commented Jul 2, 2017

Currently, the default value for the notif_from config parameter looks like this (see emailconfig.py line 114):

   notif_from: "Your Friendly %(app)s Home Server <[email protected]>"

I propose to add a comment right above it:

# %(app)s is replaced with the application's name. To avoid parsing errors, either keep it 
# in place, or delete it completely. Docs: https://pyformat.info/#named_placeholders

This would prevent people not familiar with such a Python string formatter (like me …) from mistakes that result in failing e-mail notifications and long debugging :-) For example, setting the option to "Company Name %(app) <[email protected]>" caused this in the log, not precisely helpful to find the error:

2017-06-29 22:36:51,110 - synapse.push.emailpusher - 291 - INFO - - Sending notif email for user u'@user:example.com'
2017-06-29 22:36:51,111 - synapse.push.emailpusher - 134 - ERROR - - Exception processing notifs
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/synapse/push/emailpusher.py", line 132, in _process
    yield self._unsafe_process()
ValueError: unsupported format character '<' (0x3c) at index 18
@mt7479
Copy link

mt7479 commented Jan 19, 2018

Sorry for hijacking this issue, would you be willing to share whatever needs to be configured to get registration email notifications working ?

I'm having a hard time setting this up.

@aaronraimist
Copy link
Contributor

The current documentation for it seems to explain it

# # notif_from defines the "From" address to use when sending emails.

@richvdh
Copy link
Member

richvdh commented Jan 13, 2020

also updated by #6685

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants