potix2 commented on a change in pull request #11434:
URL: https://github.com/apache/airflow/pull/11434#discussion_r502992056



##########
File path: airflow/providers/amazon/aws/transfers/google_api_to_s3.py
##########
@@ -167,21 +167,21 @@ def _retrieve_data_from_google_api(self):
         )
         return google_api_response
 
-    def _load_data_to_s3(self, data):
+    def _load_data_to_s3(self, data: dict) -> None:
         s3_hook = S3Hook(aws_conn_id=self.aws_conn_id)
         s3_hook.load_string(
             string_data=json.dumps(data), key=self.s3_destination_key, 
replace=self.s3_overwrite
         )
 
-    def _update_google_api_endpoint_params_via_xcom(self, task_instance):
+    def _update_google_api_endpoint_params_via_xcom(self, task_instance: 
TaskInstance) -> None:
         google_api_endpoint_params = task_instance.xcom_pull(
             task_ids=self.google_api_endpoint_params_via_xcom_task_ids,
             key=self.google_api_endpoint_params_via_xcom,
         )
         self.google_api_endpoint_params.update(google_api_endpoint_params)
 
-    def _expose_google_api_response_via_xcom(self, task_instance, data):
+    def _expose_google_api_response_via_xcom(self, task_instance: 
TaskInstance, key: str, data: dict) -> None:
         if sys.getsizeof(data) < MAX_XCOM_SIZE:
-            task_instance.xcom_push(key=self.google_api_response_via_xcom, 
value=data)
+            task_instance.xcom_push(key=key, value=data)

Review comment:
       Thank you. Using XCOM_RETURN_KEY is simpler than changing the signature. 
I'll fix it.




----------------------------------------------------------------
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:
[email protected]


Reply via email to