aeternity / AEXs

Aeternity expansions repository — application layer standards
10 stars 25 forks source link

AEX-2: Consider to use predefined "Invalid params" exception instead of "Invalid Transaction", "Invalid Address" #71

Closed davidyuk closed 4 years ago

davidyuk commented 5 years ago

"Invalid Transaction" and "Invalid Address" exceptions is a special case of "Invalid params", do we need to handle them separately?

That should aepp sent in response if addresses are correct but they sent in an array instead of object?

noandrea commented 4 years ago

please provide a pr with the changes you want and close the issue

davidyuk commented 4 years ago

"Invalid address" got removed recently. "Invalid transaction" error should be used in obvious use cases, like when the number of arguments or their JSON type doesn't match. "Invalid transaction" may be useful if it would indicate that the internal structure of the transaction is broken, to distinguish it with a case when transaction.sign received a number instead of a string.