kvesteri / sqlalchemy-continuum

Versioning extension for SQLAlchemy.
BSD 3-Clause "New" or "Revised" License
568 stars 128 forks source link

DeprecationWarning: '_app_ctx_stack' is deprecated and will be removed in Flask 2.3. #322

Closed JesseDeLoore closed 1 year ago

JesseDeLoore commented 1 year ago

I hope this is not a duplicate issue. I tried looking in the backlog but could not find a relevant issue

We recently upgraded to the latest version of flask and have since been seeing deprecation warnings on the use of app_ctx_stack and request_ctx_stack

site-packages\sqlalchemy_continuum\plugins\flask.py:25: DeprecationWarning: '_app_ctx_stack' is deprecated and will be remoevd in Flask 2.3.
    from flask.globals import _app_ctx_stack, _request_ctx_stack
\site-packages\flask_sqlalchemy\__init__.py:14: DeprecationWarning: '_app_ctx_stack' is deprecated and will be removed in Flask 2.3.
    from flask import _app_ctx_stack, abort, current_app, request

this is due to the change described here: https://flask.palletsprojects.com/en/latest/changes/#version-2-2-0

marksteward commented 1 year ago

Hi, it's a known issue and there's a potential PR but I've been swamped lately. Hopefully should have time to do a release at the weekend.

TomGoBravo commented 1 year ago

What's the word on getting https://github.com/kvesteri/sqlalchemy-continuum/pull/319 merged and released? 🙏

marksteward commented 1 year ago

Fixed by #307