除了send_email()之外,所有的东西都可以工作。无论我使用localhost还是远程主机,我都会得到相同的异常。我的猜测是我没有在正确的地方推动上下文,但我已经关注了很长一段时间,显然我看不到错误。任何帮助都将不胜感激!\app\templates\auth\email.py", line 7, in send_async_email127.0.0.1 - -\venv\lib\site-packages\fla
然而,尽管我在应用程序上下文中运行该工作人员,但我仍然通过以下任务获得了Runtime Error: working outside of application context。我怎样才能让瓶子-邮件在芹菜里工作?('working outside of application context')我试过:试图将应用程序<em
我猜想patch不再在flask.g上工作了,但我还没有找到解决办法。lookup_app_object(name): if top is None:E RuntimeError: Working outside of application context.venv/lib/python3.6/site-
g.my_db.fetch_all() <<< ERRORAttributeError: '_AppCtxGlobals' object has no attribute 'my_db'RuntimeError: Working outside of application context.那么如何在Flask中设置和访问