EOSIO / eosjs

General purpose library for the EOSIO blockchain.
http://eosio.github.io/eosjs
MIT License
1.43k stars 463 forks source link

EOSJS - any error for a transaction returns same error msg/exception #329

Closed amolmaid closed 6 years ago

amolmaid commented 6 years ago

I am using eosjs in my dAPP, where I am executing few transactions like issue and transfer. While doing so lets say I/user does something wrong while doing transfer

While at the same time, nodeos returns me the precise error message like, exception msg-04 19-54-48

SO do we have anything which will give me this kind more accurate error message like nodeos, so I can render it on page by which user could correct his mistake ?

jcalfee commented 6 years ago

I suspect it might be in here "details":[] if the API endpoint had started nodeosd with --verbose-http-errors .. I'm not sure what the trade-off is for enabling it and why it is off by default.

There is some example code parsing details in another issue, we can find it if you need it.

amolmaid commented 6 years ago

Ohh great, Thank you for your response, this suffice my need here, I am able to get the precise error msg now. So thank you :)

clockknock commented 5 years ago

I suspect it might be in here "details":[] if the API endpoint had started nodeosd with --verbose-http-errors .. I'm not sure what the trade-off is for enabling it and why it is off by default.

There is some example code parsing details in another issue, we can find it if you need it.

wow~ thank you again~