This repository was archived by the owner on Mar 5, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 5.1k
Incorrect error from invalid private key for signTransaction #1998
Labels
Bug
Addressing a bug
Comments
@little-shippy i've been struggling this for weeks and couldn't find a solution anywhere - thank you!!! |
sadly, i've finally had a chance to try this and i'm still getting a nonsensical insufficient funds error (the exact same unsigned transaction works just fine with sendTransaction). using the develop branch and ethereumjs-tx-1.3.3.min.js:
|
13 tasks
This was referenced Mar 31, 2020
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Hey guys,
I was running into an issue where I was getting an insufficient funds error when trying to sign a transaction. I found that this is a fairly common issue on the forums and it can be caused by having a private key that doesn't start with a 0x.
There is a simple solution to this in the packages/web3-eth-accounts/src/index.js file on line 145:
https://github.com/ethereum/web3.js/blob/v1.0.0-beta.36/packages/web3-eth-accounts/src/index.js#L145
I tested this from the v1.0.0-beta.36 tag and all tests passed.
The text was updated successfully, but these errors were encountered: