[ https://issues.apache.org/jira/browse/AIRFLOW-4824?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jarek Potiuk resolved AIRFLOW-4824. ----------------------------------- Fix Version/s: 1.10.7 Resolution: Fixed > MySqlHook needs to override DbApiHook.get_uri to pull in extra for > charset=utf-8 during create_engine > ----------------------------------------------------------------------------------------------------- > > Key: AIRFLOW-4824 > URL: https://issues.apache.org/jira/browse/AIRFLOW-4824 > Project: Apache Airflow > Issue Type: Bug > Components: hooks > Affects Versions: 1.10.3 > Reporter: lolcode > Assignee: Tomasz Żukowski > Priority: Minor > Fix For: 1.10.7 > > > When using the engine from a MySQLHook in other code (such as Pandas) the > engine returned from the create_engine function is missing the charset=utf-8 > This issue was reported here: > [https://stackoverflow.com/questions/46084744/how-to-explicitly-declare-charset-utf8-for-airflow-connections] > {{{{conn = MySqlHook(mysql_conn_id='conn_id') > }}}}{{{{engine = conn.get_sqlalchemy_engine()}}}} > I can see that the code in function *get_uri* in dbapi_hook.py does not use > the charset = utf8 information from the extra section and that mysql_hook.py > does not override the function. -- This message was sent by Atlassian Jira (v8.3.4#803005)