mailer
mailer copied to clipboard
Unable to determine manager from specification: 'immediate'
do not known why?
code as,
import sys
import logging
from marrow.mailer import Message, Delivery
sys.path.append(__file__)
logging.basicConfig(level=logging.INFO)
configuration = {
'manager': 'immediate', #'futures'
'manager.workers': 5,
'transport': 'smtp',
'transport.host': 'smtp.gmail.com',
'transport.tls': 'ssl', # None=='', required, optional
'transport.port': 465, # 25, 465 = SSL
'transport.username': '',
'transport.password': '',
'transport.max_messages_per_connection': 5,
'transport.debug': False
}
if __name__ == '__main__':
mail = Delivery(configuration)
mail.start()
message = Message()
message.author = [('Alice Bevan-McGregor', '[email protected]')]
message.to = [('Your Name Here', '[email protected]')]
message.subject = "This is a test message."
message.plain = "Testing!"
mail.send(message)
mail.stop()
Could you re-run "python setup.py develop"?
Without feedback, and upon retrospective review, the configuration is incorrectly structured.
{
'manager.use': 'immediate', #'futures'
'manager.workers': 5,
}
Note the distinction of appending .use
to the key name identifying which plugin to instantiate.