Skip to content

Commit

Permalink
EWT-370: Use python3 to launch the dataflow job. (apache#53)
Browse files Browse the repository at this point in the history
  • Loading branch information
abhishekbafna authored Jul 6, 2020
1 parent b210dbf commit 4b5b977
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion airflow/contrib/hooks/gcp_dataflow_hook.py
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ def start_python_dataflow(self, job_name, variables, dataflow, py_options,
def label_formatter(labels_dict):
return ['--labels={}={}'.format(key, value)
for key, value in labels_dict.items()]
self._start_dataflow(variables, name, ["python2"] + py_options + [dataflow],
self._start_dataflow(variables, name, ["python3"] + py_options + [dataflow],
label_formatter)

@staticmethod
Expand Down
2 changes: 1 addition & 1 deletion airflow/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,5 +18,5 @@
# under the License.
#

version = '1.10.4+twtr12'
version = '1.10.4+twtr13'

2 changes: 1 addition & 1 deletion tests/contrib/hooks/test_gcp_dataflow_hook.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ def test_start_python_dataflow(self, mock_conn,
self.dataflow_hook.start_python_dataflow(
job_name=JOB_NAME, variables=DATAFLOW_OPTIONS_PY,
dataflow=PY_FILE, py_options=PY_OPTIONS)
EXPECTED_CMD = ['python2', '-m', PY_FILE,
EXPECTED_CMD = ['python3', '-m', PY_FILE,
'--region=us-central1',
'--runner=DataflowRunner', '--project=test',
'--labels=foo=bar',
Expand Down

0 comments on commit 4b5b977

Please sign in to comment.