Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ERROR Unexpected exception in view: Working outside of application context #215

Open
malinco opened this issue Feb 17, 2023 · 0 comments
Open
Labels
Bug Something isn't working

Comments

@malinco
Copy link

malinco commented Feb 17, 2023

Describe the bug
2023-02-17T15:44:21 ERROR Unexpected exception in view: Working outside of application context.

This typically means that you attempted to use functionality that needed
the current application. To solve this, set up an application context
with app.app_context(). See the documentation for more information.: Traceback (most recent call last):
File "flask\app.py", line 1820, in full_dispatch_request
File "flask\app.py", line 1796, in dispatch_request
File "kanmail\server\app.py", line 108, in inner
File "kanmail\server\views\email_api.py", line 48, in decorated
File "kanmail\server\views\email_api.py", line 115, in api_get_account_email_texts
File "kanmail\server\mail_init_.py", line 222, in get_folder_email_texts
File "kanmail\server\mail_init_.py", line 155, in get_folder_email_parts
File "kanmail\server\util.py", line 98, in execute_threaded
File "kanmail\server\util.py", line 76, in wrapper
File "kanmail\server\mail_init
.py", line 152, in get_email_parts
File "kanmail\server\mail\folder.py", line 141, in get_email_parts
File "kanmail\server\mail\folder.py", line 193, in get_email_headers
File "kanmail\server\mail\folder_cache.py", line 321, in batch_get_headers
File "kanmail\server\mail\folder_cache.py", line 302, in batch_get_header_items
File "kanmail\server\util.py", line 33, in wrapper
File "kanmail\server\mail\folder_cache.py", line 194, in get_folder_cache_item
File "flask_sqlalchemy\model.py", line 31, in get
File "sqlalchemy\orm\scoping.py", line 211, in call
File "sqlalchemy\util_collections.py", line 639, in call
File "flask_sqlalchemy\session.py", line 102, in _app_ctx_id
File "werkzeug\local.py", line 513, in _get_current_object
RuntimeError: Working outside of application context.

Screenshots
If applicable, add screenshots to help explain your problem.

Additional context
Add any other context about the problem here.

@malinco malinco added the Bug Something isn't working label Feb 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant