Project

General

Profile

Actions

Bug #7619

open

Flask Deprecation warnings

Added by Jakub Maloštik over 1 year ago. Updated 12 months ago.

Status:
In Progress
Priority:
Normal
Assignee:
-
Category:
Testing
Target version:
-
Start date:
12/14/2022
Due date:
% Done:

0%

Estimated time:
To be discussed:

Description

The warnings are:

./vagrant/lib/hawat/base.py:770: DeprecationWarning: 'app.json_encoder' is deprecated and will be removed in Flask 2.3. Customize 'app.json_provider_class' or 'app.json' instead.
  self.json_encoder = HawatJSONEncoder

/var/mentat/venv/lib/python3.7/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

/var/mentat/venv/lib/python3.7/site-packages/flask_sqlalchemy/__init__.py:302: DeprecationWarning: '_app_ctx_stack' is deprecated and will be removed in Flask 2.3. Use 'g' to store data, or 'app_ctx' to access the current context.
  queries = _app_ctx_stack.top.sqlalchemy_queries

/var/mentat/venv/lib/python3.7/site-packages/flask_sqlalchemy/__init__.py:304: DeprecationWarning: '_app_ctx_stack' is deprecated and will be removed in Flask 2.3. Use 'g' to store data, or 'app_ctx' to access the current context.
  queries = _app_ctx_stack.top.sqlalchemy_queries = []

/var/mentat/venv/lib/python3.7/site-packages/flask/json/provider.py:192: DeprecationWarning: Setting 'json_encoder' on the app or a blueprint is deprecated and will be removed in Flask 2.3. Customize 'app.json' instead.
  DeprecationWarning,

/var/mentat/venv/lib/python3.7/site-packages/flask/json/provider.py:230: DeprecationWarning: 'JSONEncoder' is deprecated and will be removed in Flask 2.3. Use 'Flask.json' to provide an alternate JSON implementation instead.
  return json.dumps(obj, **kwargs)

/var/mentat/venv/lib/python3.7/site-packages/flask_debugtoolbar/__init__.py:5: DeprecationWarning: '_request_ctx_stack' is deprecated and will be remoevd in Flask 2.3.
  from flask.globals import _request_ctx_stack

Related issues

Related to Mentat - Support #7632: Mentat dependencies upgradeClosedJakub Judiny02/28/2023

Actions
Related to Mentat - Task #6205: Review encapsulation of SQLAlchemy and Psycopg2 DBALsClosedRajmund Hruška01/24/2020

Actions
Is duplicate of Mentat - Task #7615: Update flask-sqlalchemyClosed11/10/2022

Actions
Actions #1

Updated by Rajmund Hruška over 1 year ago

  • Is duplicate of Task #7615: Update flask-sqlalchemy added
Actions #2

Updated by Rajmund Hruška over 1 year ago

  • Status changed from New to Closed

Will be solved in #7619.

Actions #3

Updated by Rajmund Hruška over 1 year ago

  • Status changed from Closed to New
Actions #4

Updated by Pavel Kácha about 1 year ago

Actions #5

Updated by Jakub Judiny about 1 year ago

  • Related to Task #6205: Review encapsulation of SQLAlchemy and Psycopg2 DBALs added
Actions #6

Updated by Jakub Judiny about 1 year ago

  • Status changed from New to Resolved
  • Assignee set to Jakub Judiny

All warnings except the first one are caused by dependencies (flask_sqlalchemy, flask_debugtoolbar and flask itself), so we cannot do anything but wait for the updates of these libraries.

I fixed the first warning in #7632 (revision 86325b40).

Actions #7

Updated by Jakub Judiny about 1 year ago

  • Status changed from Resolved to In Progress
Actions #8

Updated by Jakub Judiny 12 months ago

  • Assignee deleted (Jakub Judiny)
Actions

Also available in: Atom PDF