Merge pull request #60 from airbnb/stdout
Making HiveCliHook.run_cli return stdout
This commit is contained in:
Коммит
30ea72ca30
|
@ -57,13 +57,17 @@ class HiveCliHook(BaseHook):
|
|||
cwd=tmp_dir)
|
||||
all_err = ''
|
||||
self.sp = sp
|
||||
stdout = ""
|
||||
for line in iter(sp.stdout.readline, ''):
|
||||
stdout += line
|
||||
logging.info(line.strip())
|
||||
sp.wait()
|
||||
|
||||
if sp.returncode:
|
||||
raise AirflowException(all_err)
|
||||
|
||||
return stdout
|
||||
|
||||
def load_file(
|
||||
self,
|
||||
filepath,
|
||||
|
|
Загрузка…
Ссылка в новой задаче