invalid sender #263
Unanswered
wmahmood1984
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi
i am getting below error while signing transaction.
errors.js:28 Uncaught (in promise) Error: Returned error: invalid sender
at Object.ErrorResponse (errors.js:28)
at index.js:302
at XMLHttpRequest.request.onreadystatechange (index.js:98)
My code is as follows:
var web3 = new Web3(new Web3.providers.HttpProvider(
https://matic-mainnet.chainstacklabs.com
));var method_call_abi = contract_AdWorld.methods.deposit(20,0).encodeABI(); // TODO edit me
web3.eth.getTransactionCount(from_addr).then(txCount => { // get tx count of my wallet...
// // build transaction dict
const txData = {
nonce: web3.utils.toHex(txCount),
gasLimit: web3.utils.toHex(250000), // TODO edit me (use gas estimation maybe?)
gasPrice: web3.utils.toHex(12e8), // 1 Gwei // TODO edit me (use gas price estimation maybe?)
to: adWorld_Address,
from: from_addr,
data: method_call_abi,
};
Please if someone can help me
Beta Was this translation helpful? Give feedback.
All reactions