Skip to content

Commit 4b5b977

Browse files
EWT-370: Use python3 to launch the dataflow job. (twitter-forks#53)
1 parent b210dbf commit 4b5b977

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

airflow/contrib/hooks/gcp_dataflow_hook.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -242,7 +242,7 @@ def start_python_dataflow(self, job_name, variables, dataflow, py_options,
242242
def label_formatter(labels_dict):
243243
return ['--labels={}={}'.format(key, value)
244244
for key, value in labels_dict.items()]
245-
self._start_dataflow(variables, name, ["python2"] + py_options + [dataflow],
245+
self._start_dataflow(variables, name, ["python3"] + py_options + [dataflow],
246246
label_formatter)
247247

248248
@staticmethod

airflow/version.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,5 +18,5 @@
1818
# under the License.
1919
#
2020

21-
version = '1.10.4+twtr12'
21+
version = '1.10.4+twtr13'
2222

tests/contrib/hooks/test_gcp_dataflow_hook.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ def test_start_python_dataflow(self, mock_conn,
102102
self.dataflow_hook.start_python_dataflow(
103103
job_name=JOB_NAME, variables=DATAFLOW_OPTIONS_PY,
104104
dataflow=PY_FILE, py_options=PY_OPTIONS)
105-
EXPECTED_CMD = ['python2', '-m', PY_FILE,
105+
EXPECTED_CMD = ['python3', '-m', PY_FILE,
106106
'--region=us-central1',
107107
'--runner=DataflowRunner', '--project=test',
108108
'--labels=foo=bar',

0 commit comments

Comments
 (0)