Search results that have a special character in them are causing internal server errors. The database is a MySQL database. Here’s the error with Debug set to true. The search was for “water & fire” in this instance. Any thoughts on why this is happening?
ProgrammingError at /search/
(1064, “syntax error, unexpected ‘)’”)
Request Method: | GET |
---|---|
Request URL: | https://domainremoved.com/search/?q=water+%26+fire |
Django Version: | 3.2.9 |
Exception Type: | ProgrammingError |
Exception Value: | (1064, “syntax error, unexpected ‘)’”) |
Exception Location: | /var/www/sites/library-test2/.venv/lib64/python3.8/site-packages/MySQLdb/connections.py, line 259, in query |
Python Executable: | /var/www/sites/library-test2/.venv//bin/python |
Python Version: | 3.8.8 |
Python Path: | [’/var/www/sites/library-test2’, ‘/usr/lib64/python38.zip’, ‘/usr/lib64/python3.8’, ‘/usr/lib64/python3.8/lib-dynload’, ‘/var/www/sites/library-test2/.venv/lib64/python3.8/site-packages’, ‘/var/www/sites/library-test2/.venv/lib/python3.8/site-packages’] |