You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2019/05/22 05:37:12 UTC

[GitHub] [airflow] RosterIn commented on a change in pull request #5211: [AIRFLOW-4442] fix hive_tblproperties in HiveToDruidTransfer

RosterIn commented on a change in pull request #5211: [AIRFLOW-4442] fix hive_tblproperties in HiveToDruidTransfer
URL: https://github.com/apache/airflow/pull/5211#discussion_r286319518
 
 

 ##########
 File path: airflow/operators/hive_to_druid.py
 ##########
 @@ -97,7 +97,7 @@ def __init__(
         self.hadoop_dependency_coordinates = hadoop_dependency_coordinates
         self.druid_ingest_conn_id = druid_ingest_conn_id
         self.metastore_conn_id = metastore_conn_id
-        self.hive_tblproperties = hive_tblproperties
+        self.hive_tblproperties = hive_tblproperties or dict()
 
 Review comment:
   @feluelle apparently it's not just a matter or preference it's also a matter of performance. `{}` is much better:
   https://stackoverflow.com/questions/17097985/dict-vs-in-python-which-is-better/17098017
   https://stackoverflow.com/questions/5790860/and-vs-list-and-dict-which-is-better

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services