12
votes
How to retrieve revert() reason for past transactions?
In solidity 0.4.22 the require and revert reason were added. As can be seen here, they are abi-encoded as if it were a call to a function "Error(string)".
This blog post gives an example: an eth_call ...
8
votes
How to retrieve revert() reason for past transactions?
I created an NPM package to handle this: eth-revert-reason
It is difficult to decode the revert reason in a general manner. Many different factors, such as Geth vs. Parity, web3.js vs ethers, etc. ...
7
votes
How to retrieve revert() reason for past transactions?
Using eth_Call to execute function:
Example.test(0x0000000000000000000000000000000000000000000000000000000000000002)
of Example contract we will receive
following reply from geth node:
...
6
votes
How to retrieve revert() reason for past transactions?
After being really annoyed for a long time I wrote a bash script to fetch the revert reason from geth by a tx hash:
https://gist.github.com/gluk64/fdea559472d957f1138ed93bcbc6f78a
4
votes
Accepted
Does --no-ancient-blocks affect on trace_call for the pending block?
Per the Solidity docs: https://docs.soliditylang.org/en/v0.5.3/units-and-global-variables.html#block-and-transaction-properties
Transactions can only access at most state that is 256 blocks old. That ...
3
votes
Accepted
Is it possible for an address to be both controlled by a smart contract and a key?
I had the same question not that long ago and the answer is in EIP-3607.
Ethereum addresses are currently only 160 bits long. This means it is
possible to create a collision between a contract ...
2
votes
Accepted
Getting accounts involved in internal transactions
You'll need to actually go through and parse the JSON to get that. Specifically the action block.
See the JSONRPC call trace_replayTransaction here: https://openethereum.github.io/JSONRPC-trace-module
...
2
votes
How to retrieve revert() reason for past transactions?
It is also possible with go-ethereum. Tested with a simulated blockchain backend.
import (
"bytes"
"context"
"math/big"
"github.com/ethereum/go-ethereum"
"github.com/ethereum/go-...
2
votes
multiple debug_traceCall
No, multiple traces are not available in Geth.
You can trace transaction, trace blocks, but not multiple calls
Sources for your reference:
https://github.com/ethereum/go-ethereum/blob/master/eth/...
2
votes
Accepted
How can I tell if the node I am using is exposing the Parity trace methods?
You can try running a trace cURL in your terminal to the node, like:
curl --data '{"method":"trace_transaction","params":["0x99ac150336f74125702bb87598677c97474c5783a9258049d98377ab0773f73d"],"id":1,"...
2
votes
How to retrieve revert() reason for past transactions?
This is not a direct answer to the ops question, but for all others that stumble over this question while searching for how to get the error reason generated by a failed solidity require in javascript:...
2
votes
Accepted
how to generate recovery ID used in v of the signature
Thank to @ismael I developed the code in a rookie clean way you can find it in git repo: here
and I'm also going to describe a bit of code here too.
var maxValueForS = BigInt.parse('...
2
votes
Accepted
What do I need to consider to choose Ethereum Client?
Hi dev advocate at Chainstack here!
Answer to question 1)
Geth is definitely the most used for now. There are a few reasons why. Still, the main one is that Go Ethereum (Geth) is the official Go land ...
2
votes
Accepted
What is DTOs in Ethereum?
The answer is to be found in the link you provided:
There are various RPC Data transfer objects for Block, Transaction, FilterInput, and BlockParameter, to name a few.
I agree that they could have ...
1
vote
Accepted
What is the name of a Smart Contract?
The name of a smart contract is not actually a required field, but it is often included as a way to give the contract a human-readable identity.
The name of a contract can be any string value that you ...
1
vote
Accepted
Ethereum block time assessment
Let's quickly discuss Ethereum's proof of work. Block time is so
small(3sec).In such case, multiple blocks can be solved at the same
time, if so, one of the blocks will be discarded and another one ...
1
vote
How to recover private key from 2017 Parity wallet (non-standard BIP-39) recovery phrase?
MEW stopped supporting parity seed words, you need to boot an older index up of MEW.
1
vote
Accepted
Is there a way to analyze the contract trancsaction trace result like Etherscan?
What you have is part of the solution.
You also have to look at events from that transaction.
So eth_getTransactionReceipt will return the logs (and other data that will be useful for you.).
also look ...
1
vote
Is there a way to analyze the contract trancsaction trace result like Etherscan?
Truffle Plugin Debugger (formerly Truffle Teams) can help: https://github.com/trufflesuite/truffle-plugin-debugger
1
vote
Getting accounts involved in internal transactions
Usually Events are used to achieve this (since decoding the transaction data is rather cumbersome). The smart contract you linked to as an example unfortunately has no events, but since it seems to be ...
1
vote
Accepted
Recovering of Parity 1.7.8 wallet - integrating to Open Ethereum
I was in pretty much the same situation, except that I used an even older version of Parity (circa 2017) originally.
Easiest, not very secure
The easiest solution for me was to use MEW (myEtherWallet) ...
1
vote
Is geth / parity an on-chain or off-chain node?
geth/parity implement the functionality of the nodes of the blockchain network and actually constitute the blockchain network
1
vote
How much mining before I achieve a coin?
This is dependent on mostly two factors:
The amount of hashes your hardware can solve per time unit
The current network difficulty
The first factor is fully up to your hardware, so I can't comment ...
1
vote
Accepted
Eth 2 staking - Required mainet recent blocks
From what I gathered I can say:
Warp syncing became to complex so it is no longer made after ~1,000,000 blocks I think
Warp syncing takes the same amount of storage as normal syncing, only warp ...
1
vote
Accepted
Extracting blockchain state at a specific block number to interact with deployed contracts
Here is how you can do it using Truffle & Ganache.
In truffle-config.js, extend the configuration of your network to something like this:
networks: {
myNetwork: {
host: ...,
...
1
vote
Gas cost of multiple small transactions vs one large one
Each transaction has itself gas consumption. Calculation of this consumption depends to codes that a transaction triggers them to perform and data size of the same transaction, so called arguments. ...
1
vote
Accepted
Is there any way to do dry run a smart contract on Ethereum Mainnet?
Yes.
You can run your own node and synchronize it fully. After that you can import the blockchain data to a local blockchain (Ganache) and use that. Then you can simulate transactions against the ...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
openethereum × 813go-ethereum × 175
private-blockchain × 62
web3js × 61
parity-wallet × 50
synchronization × 48
nodes × 41
json-rpc × 39
transactions × 32
blockchain × 28
solidity × 27
genesis × 22
wallets × 21
warp-sync × 21
contract-development × 20
poa × 20
proof-of-authority × 20
pending-transactions × 19
kovan × 19
ether × 18
contract-deployment × 18
mist × 18
testnets × 16
mining × 15
truffle × 14