mirror of
https://github.com/frappe/bench.git
synced 2024-11-12 00:06:36 +00:00
feat(error): Show SyntaxError found in frappe (#759)
This commit is contained in:
parent
518b8f32da
commit
1497f9b14b
@ -98,7 +98,9 @@ def get_frappe_commands(bench_path='.'):
|
||||
output = get_cmd_output("{python} -m frappe.utils.bench_helper get-frappe-commands".format(python=python), cwd=sites_path)
|
||||
# output = output.decode('utf-8')
|
||||
return json.loads(output)
|
||||
except subprocess.CalledProcessError:
|
||||
except subprocess.CalledProcessError as e:
|
||||
if e.stderr:
|
||||
print(e.stderr.decode('utf-8'))
|
||||
return []
|
||||
|
||||
def get_frappe_help(bench_path='.'):
|
||||
|
@ -359,7 +359,7 @@ def check_git_for_shallow_clone():
|
||||
|
||||
def get_cmd_output(cmd, cwd='.'):
|
||||
try:
|
||||
output = subprocess.check_output(cmd, cwd=cwd, shell=True, stderr=open(os.devnull, 'wb')).strip()
|
||||
output = subprocess.check_output(cmd, cwd=cwd, shell=True, stderr=subprocess.PIPE).strip()
|
||||
output = output.decode('utf-8')
|
||||
return output
|
||||
except subprocess.CalledProcessError as e:
|
||||
|
Loading…
Reference in New Issue
Block a user