cli/smartcontract: print proper error message on failed testinvoke
Do not print info about `--force` flag if we don't send or save a transaction. Signed-off-by: Evgeniy Stratonikov <evgeniy@nspcc.ru>
This commit is contained in:
parent
1f62ecd5a3
commit
0dc606f50e
1 changed files with 4 additions and 0 deletions
|
@ -665,6 +665,10 @@ func invokeWithArgs(ctx *cli.Context, acc *wallet.Account, wall *wallet.Wallet,
|
|||
}
|
||||
if resp.State != "HALT" {
|
||||
errText := fmt.Sprintf("Warning: %s VM state returned from the RPC node: %s\n", resp.State, resp.FaultException)
|
||||
if out == "" && !signAndPush {
|
||||
return sender, cli.NewExitError(errText, 1)
|
||||
}
|
||||
|
||||
action := "save"
|
||||
process := "Saving"
|
||||
if signAndPush {
|
||||
|
|
Loading…
Reference in a new issue