airflow-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <>
Subject [GitHub] ashb closed pull request #2548: [AIRFLOW-1540] Add proxies to Slack Operator
Date Thu, 01 Nov 2018 20:44:00 GMT
ashb closed pull request #2548: [AIRFLOW-1540] Add proxies to Slack Operator

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/airflow/operators/ b/airflow/operators/
index 2e6d4269fa..dd6947d5fb 100644
--- a/airflow/operators/
+++ b/airflow/operators/
@@ -38,11 +38,13 @@ class SlackAPIOperator(BaseOperator):
     def __init__(self,
+                 proxies=None,
                  *args, **kwargs):
         super(SlackAPIOperator, self).__init__(*args, **kwargs)
         self.token = token
         self.method = method
+        self.proxies = proxies
         self.api_params = api_params
     def construct_api_call_params(self):
@@ -63,7 +65,7 @@ def execute(self, **kwargs):
         if not self.api_params:
-        sc = SlackClient(self.token)
+        sc = SlackClient(self.token, self.proxies)
         rc = sc.api_call(self.method, **self.api_params)
         if not rc['ok']:
             logging.error("Slack API call failed ({})".format(rc['error']))


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

With regards,
Apache Git Services

View raw message