Bhavika created AIRFLOW-4907:
--------------------------------
Summary: AWSAthenaHook - using None connection in a method
Key: AIRFLOW-4907
URL: https://issues.apache.org/jira/browse/AIRFLOW-4907
Project: Apache Airflow
Issue Type: Bug
Components: aws
Affects Versions: 1.10.3
Reporter: Bhavika
Assignee: Bhavika
Fix For: 1.10.4
In the AWSAthenaHook
[https://github.com/apache/airflow/blob/master/airflow/contrib/hooks/aws_athena_hook.py],
the get_conn() method initializes `conn` if it's None. But the
`get_state_change_reason()` method uses `conn` which is initialized to None -
[https://github.com/apache/airflow/blob/master/airflow/contrib/hooks/aws_athena_hook.py#L98]
Solution:
Replace the call to `self.conn` with `self.get_conn()` in order to ensure
initialization.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)