Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Returned error: The execution failed due to an exception. #8

Open
alvin854 opened this issue Apr 14, 2020 · 1 comment
Open

Returned error: The execution failed due to an exception. #8

alvin854 opened this issue Apr 14, 2020 · 1 comment

Comments

@alvin854
Copy link

Code:

const CryptoAccount = require("send-crypto");
const keys = require("../../config/keys");

const account = new CryptoAccount(keys.privateKey, {
  network: "kovan"
});

account
  .send("0x868c75dFB5460797EB4cc12e60B1ab468439c337", 10, {
    type: "ERC20",
    address: keys.contractAddress
  })
  .catch(console.error);

Response:

Error: Returned error: The execution failed due to an exception.
    at Object.ErrorResponse (/Users/me/Desktop/myproject/node_modules/web3-core-helpers/src/errors.js:29:16)
    at /Users/me/Desktop/myproject/node_modules/web3-core-requestmanager/src/index.js:140:36
    at XMLHttpRequest.request.onreadystatechange (/Users/me/Desktop/myproject/node_modules/web3-providers-http/src/index.js:110:13)
    at XMLHttpRequestEventTarget.dispatchEvent (/Users/me/Desktop/myproject/node_modules/xhr2-cookies/dist/xml-http-request-event-target.js:34:22)
    at XMLHttpRequest._setReadyState (/Users/me/Desktop/myproject/node_modules/xhr2-cookies/dist/xml-http-request.js:208:14)
    at XMLHttpRequest._onHttpResponseEnd (/Users/me/Desktop/myproject/node_modules/xhr2-cookies/dist/xml-http-request.js:318:14)
    at IncomingMessage.<anonymous> (/Users/me/Desktop/myproject/node_modules/xhr2-cookies/dist/xml-http-request.js:289:61)
    at IncomingMessage.emit (events.js:323:22)
    at endReadableNT (_stream_readable.js:1204:12)
    at processTicksAndRejections (internal/process/task_queues.js:84:21)

Error object from /node_modules/web3-core-helpers/src/errors.js:29:16

{
  jsonrpc: '2.0',
  id: 2,
  error: {
    code: -32016,
    data: 'Reverted',
    message: 'The execution failed due to an exception.'
  }
}
@ccoop1
Copy link

ccoop1 commented Sep 24, 2021

You ever get this figured out?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants
@alvin854 @ccoop1 and others