Skip to content

Commit

Permalink
Force UTF-8 for database access
Browse files Browse the repository at this point in the history
  • Loading branch information
benmwebb committed Sep 27, 2022
1 parent 113bcfc commit 3ae0e59
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions python/saliweb/frontend/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -451,6 +451,7 @@ def render_queue_page():
if _request_wants_xml():
return flask.render_template('saliweb/help.xml')
conn = get_db()
conn.set_character_set('utf8')
c = MySQLdb.cursors.DictCursor(conn)
c.execute("SELECT * FROM jobs WHERE state != 'ARCHIVED' "
"AND state != 'EXPIRED' AND state != 'COMPLETED' "
Expand Down

0 comments on commit 3ae0e59

Please sign in to comment.