marrow / mailer

A light-weight, modular, message representation and mail delivery framework for Python.
MIT License
279 stars 62 forks source link

Unable to determine manager from specification: 'immediate' #10

Closed ghiewa closed 9 months ago

ghiewa commented 12 years ago

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', 'ghiewa@gmail.com')]
    message.to = [('Your Name Here', 'ghiewa@126.com')]
    message.subject = "This is a test message."
    message.plain = "Testing!"

    mail.send(message)
    mail.stop()
amcgregor commented 12 years ago

Could you re-run "python setup.py develop"?

amcgregor commented 9 months ago

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.