3
我試圖建立TurboMail 3塔1.0TurboMail 3塔1.0 - MailNotEnabledException
我已經加入這個在development.ini
[DEFAULT]
...
mail.on = true
mail.manager = immediate
mail.transport = smtp
mail.smtp.server = localhost
和我app_globals的.py的樣子:
"""The application's Globals object"""
from beaker.cache import CacheManager
from beaker.util import parse_cache_config_options
class Globals(object):
def __init__(self, config):
self.cache = CacheManager(**parse_cache_config_options(config))
from turbomail.adapters import tm_pylons
tm_pylons.start_extension()
我的控制器具有這個方法:
def submit(self):
message = Message("[email protected]", "[email protected]", "Hello World")
message.plain = "TurboMail is really easy to use."
message.send()
的問題是,我得到這個錯誤時message.send()是被稱爲:
MailNotEnabledException: An attempt was made to use a facility of the TurboMail framework but outbound mail hasn't been enabled in the config file [via mail.on]
我不知道我缺少什麼嗎? 這一切似乎根據文檔!
由於