From dedb0ee6f2dd58c0040bbd2d9afd000c58f508c6 Mon Sep 17 00:00:00 2001 From: Bo-Chun Louis Chen <louistw@uab.edu> Date: Fri, 25 May 2018 12:46:21 -0500 Subject: [PATCH] Added FSADeprecationWarning problem and solution in README --- README.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/README.md b/README.md index 1125d53..5993ea1 100644 --- a/README.md +++ b/README.md @@ -87,3 +87,20 @@ This is a project implementing the blog post by Mbithe Nzomo. ```shell $ mv app.db app/ ``` + +4. **FSADeprecationWarning** while accessing database using SQLAlchemy + + ```shell + APP_ROOT/venv/lib/python2.7/site-packages/flask_sqlalchemy/__init__.py:794: FSADeprecationWarning: SQLALCHEMY_TRACK_MODIFICATIONS + adds significant overhead and will be disabled by default in the future. + Set it to True or False to suppress this warning. + ``` + + **Solution:** + Set SQLALCHEMY_TRACK_MODIFICATIONS to **False/True** at line 789 in flask_sqlalchemy/\_\_init\_\_.py + + ```python + 788 track_modifications = app.config.setdefault( + 789 'SQLALCHEMY_TRACK_MODIFICATIONS', False + 790 ) + ``` -- GitLab