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

SQLAlchemy version 1.0.11 warning and 1.3.3 error #6

Open
KerstenDoering opened this issue Jun 25, 2016 · 1 comment
Open

SQLAlchemy version 1.0.11 warning and 1.3.3 error #6

KerstenDoering opened this issue Jun 25, 2016 · 1 comment

Comments

@KerstenDoering
Copy link
Owner

python RunXapian.py -x
/usr/lib/python2.7/dist-packages/sqlalchemy/sql/elements.py:3779: SAWarning: Textual SQL expression '\n SELECT \n ...' should be explicitly declared as text('\n SELECT \n ...') (this warning may be suppressed after 10 occurrences)
{"expr": util.ellipses_string(element)})

@KerstenDoering
Copy link
Owner Author

In the current SQLAlchemy version of 1.3.3, this turned out to be no longer a warning, but an error:
sqlalchemy.exc.ArgumentError: Textual SQL expression '\n SELECT \n ...' should be explicitly declared as text('\n SELECT \n ...')

The current workaround is to set the SQLAlchemy version to 1.0.11 as follows:

Did you install "pip" for managing the SQLAlchemy version? If not, you can do so by using this command:
sudo apt install python-pip

The following command will show the current version of SQLAlchemy:
pip list | grep "SQLAlchemy"
In my case, this is 1.3.3.

Now, we need to be sure that SQLAlchemy gets completely uninstalled:
pip uninstall SQLAlchemy

The next command will install SQLAlchemy in version 1.0.11:
pip install SQLAlchemy==1.0.11

If you have a look at the installed version, again, you should see that version 1.0.11 is installed:
pip list | grep "SQLAlchemy"
SQLAlchemy (1.0.11)

@KerstenDoering KerstenDoering changed the title SQLAlchemy version 1.0.11 warning SQLAlchemy version 1.0.11 warning and 1.3.3 error Jun 17, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant