Closed galbraithd closed 5 years ago
I've launched own node, tried again and got same result:
> web3.eth.getBalance("0xf55a3614609d0197ded83378ed5ccc6a181bb8af")
60000000000000000
> web3.personal.unlockAccount("0xf55a3614609d0197ded83378ed5ccc6a181bb8af")
Unlock account 0xf55a3614609d0197ded83378ed5ccc6a181bb8af
Passphrase:
true
> web3.eth.sendTransaction({nonce: '0x68', gasPrice: web3.toWei(5, "gwei"), gas: '0x61A8', from: '0xf55a3614609d0197ded83378ed5ccc6a181bb8af', to: '0xe90ec675dad07929232740b74391e3021562910c', value: web3.toWei(0.001, "ether"), data: '0x', chainId: 'pchain'})
"0xe6e2fb55a94081f960741bf244f627d578d4e6e4180a2d96d1ccbf05fea1113e"
> web3.eth.getTransaction("0xe6e2fb55a94081f960741bf244f627d578d4e6e4180a2d96d1ccbf05fea1113e")
{
blockHash: "0x0000000000000000000000000000000000000000000000000000000000000000",
blockNumber: null,
from: "0xf55a3614609d0197ded83378ed5ccc6a181bb8af",
gas: 25000,
gasPrice: 5000000000,
hash: "0xe6e2fb55a94081f960741bf244f627d578d4e6e4180a2d96d1ccbf05fea1113e",
input: "0x",
nonce: 104,
r: "0xe85b3cd19871754746f39d80234b0b528bde15fcf9ed7eafac2d3a8b664e6e17",
s: "0x214e742563ff7e27646ff42898263fd5b31aafb1f15f9f2cfa9598d9eddef308",
to: "0xe90ec675dad07929232740b74391e3021562910c",
transactionIndex: 0,
v: "0x6ad51b06ee7e3e3cd86ef37774b179dbd37ceecd6e38400fa884d8260c5d9c46",
value: 1000000000000000
}
you should check your latest nonce in the transaction. use the API as below: https://github.com/pchain-org/pweb3/wiki/JavaScript-API#web3ethgettransactioncount. The transaction was executed in the nonce's sequence.
Thanks a lot. Solved.
I had to use getNonce or import private key to web wallet and get nonce from there. In my case address was new, so i've used nonce: 0
Code:
Get hash, as a result: https://testnet.pchain.org/index.html?key=0x03bc400085c49e068e1226def1e183c01d5c447ee0363f82b5f4fd478ac2a3ba&chain=0
But tx status Pending. permanently
Similar tx with the same inputs made through the website https://testnet.pchain.org/index.html?key=0x5401309730dfc7aba3450e297adca8c11dee4851d60bc2522eee10a694ed8750&chain=0