Skip to content

Commit

Permalink
Improve vmware vmrun error error message
Browse files Browse the repository at this point in the history
  • Loading branch information
julien-duponchelle committed Nov 28, 2016
1 parent 40263e1 commit a776b36
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions gns3server/compute/vmware/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -389,12 +389,12 @@ def _execute(self, subcommand, args, timeout=120, log_level=logging.INFO):
try:
stdout_data, _ = yield from asyncio.wait_for(process.communicate(), timeout=timeout)
except asyncio.TimeoutError:
raise VMwareError("vmrun has timed out after {} seconds!\nTry to run {} in a terminal to see more informations.".format(timeout, command_string))
raise VMwareError("vmrun has timed out after {} seconds!\nTry to run {} in a terminal to see more informations.\nAnd make sure GNS3 and VMware run under the same user.".format(timeout, command_string))

if process.returncode:
# vmrun print errors on stdout
vmrun_error = stdout_data.decode("utf-8", errors="ignore")
raise VMwareError("vmrun has returned an error: {}\nTry to run {} in a terminal to see more informations.".format(vmrun_error, command_string))
raise VMwareError("vmrun has returned an error: {}\nTry to run {} in a terminal to see more informations.\nAnd make sure GNS3 and VMware run under the same user.".format(vmrun_error, command_string))

return stdout_data.decode("utf-8", errors="ignore").splitlines()

Expand Down

0 comments on commit a776b36

Please sign in to comment.