1

I am trying to calculate the balances of addresses on the Ethereum blockchain and I noticed that some of them came up negative when I was testing my code. This led me to realize that, of course, some addresses very early in the blockchain start off by sending Eth, despite not having any explicitly transferred to them in the downloaded blockchain data.

I used Geth and ran a Geth node to sync the Ethereum blockchain

https://geth.ethereum.org/

https://ethereum-etl.readthedocs.io/en/latest/exporting-the-blockchain/

Then I used Ethereum-ETL to extract and download the synced blockchain from Geth into csv files using a variation of this command: ethereumetl export_token_transfers --start-block 0 --end-block 500000 --provider-uri file://$HOME/Library/Ethereum/geth.ipc --batch-size 100 --output token_transfers.csv

This is what the first few lines of the output look like:

hash,nonce,block_hash,block_number,transaction_index,from_address,to_address,value,gas,gas_price,input,block_timestamp,max_fee_per_gas,max_priority_fee_per_gas,transaction_type
0x5c504ed432cb51138bcf09aa5e8a410dd4a1e204ef84bfed1be16dfba1b22060,0,0x4e3a3754410177e6937ef1f84bba68ea139e8d1a2258c5f85db9f1cd715a1bdd,46147,0,0xa1e4380a3b1f749673e270229993ee55f35663b4,0x5df9b87991262f6ba471f09758cde1c0fc1de734,31337,21000,50000000000000,0x,1438918233,,,0
0x19f1df2c7ee6b464720ad28e903aeda1a5ad8780afc22f0b960827bd4fcf656d,0,0x5793f91c9fa8f824d8ed77fc1687dddcf334da81c68be65a782a36463b6f7998,46169,0,0xbd08e0cddec097db7901ea819a3d1fd9de8951a2,0x5c12a8e43faf884521c2454f39560e6c265a68c8,19900000000000000000,21000,909808707606,0x,1438918613,,,0
0x9e6e19637bb625a8ff3d052b7c2fe57dc78c55a15d258d77c43d5a9c160b0384,0,0xf4a537e8e2233149929a9b6964c9aced6ee95f42131aa6b648d2c7946dfc6fe2,46170,0,0x63ac545c991243fa18aec41d4f6f598e555015dc,0xc93f2250589a6563f5359051c1ea25746549f0d8,599989500000000000000,21000,500000000000,0x,1438918630,,,0
0xcb9378977089c773c074045b20ede2cdcc3a6ff562f4e64b51b20c5205234525,0,0x47ec6a0c3467850cf88112c212c262819de6f1d084d396981d18d8f949cb3017,46194,0,0x037dd056e7fdbd641db5b6bea2a8780a83fae180,0x7e7ec15a5944e978257ddae0008c2f2ece0a6090,100000000000000000000,21000,1000000000000,0x,1438918983,,,0
0xd23ae9b2e5c68caf2c5663af5ba27679dc3b3cb781c4dc698abbd17d63e32e9f,4,0x9ae8151519c1bef1b480a162c96904142c1cdc22a81c44f624f2a73691430f8c,46300,0,0xfd2605a2bf58fdbb90db1da55df61628b47f9e8c,0x88b3672d21fecaa5313c37c59de4ed53fd8c76fd,10000000000000000,21000,297006036751,0x,1438920830,,,0

For a more readable version with only the info that I care about:

from_address,to_address,value,block_timestamp
0xa1e4380a3b1f749673e270229993ee55f35663b4,0x5df9b87991262f6ba471f09758cde1c0fc1de734,31337,1438918233
0xbd08e0cddec097db7901ea819a3d1fd9de8951a2,0x5c12a8e43faf884521c2454f39560e6c265a68c8,19900000000000000000,1438918613
0x63ac545c991243fa18aec41d4f6f598e555015dc,0xc93f2250589a6563f5359051c1ea25746549f0d8,599989500000000000000,1438918630
0x037dd056e7fdbd641db5b6bea2a8780a83fae180,0x7e7ec15a5944e978257ddae0008c2f2ece0a6090,100000000000000000000,1438918983
0xfd2605a2bf58fdbb90db1da55df61628b47f9e8c,0x88b3672d21fecaa5313c37c59de4ed53fd8c76fd,10000000000000000,1438920830

How did the first from_address (0xa1e4...) get Eth to be able to transfer 31337 Wei to the first to_address (0x5df9...)?

I went on Etherscan and found this: https://etherscan.io/tx/0x465f5114097aa59bd50da7e46b69e8f8f61af47f5a4c5e450dd00739d33fb0cd

The address 0xa1e4... got Eth from another address to be able to send that 31337 Wei in the first transaction

However, this transaction did not get recorded either in the geth sync node or the Ethereum-ETL extraction of data.

Why is this transaction "hidden" in the downloaded data but found on Etherscan?

Furthermore, I found a 'miner' indicator in the state records of that 'hidden' transaction: The state records from the link I provided above.

It is my understanding that internal transactions are not supposed to explicitly be stored in blockchain data and you need extra tools like the ones Etherscan uses to access those internal transactions, but I do not know what to make of this information or why so many of these important Eth loading transactions are not listed in the blockchain data that I downloaded.

Even furthermore, why do the transactions that send Eth to the address in the original 'hidden' transaction also have their own 'hidden' transactions where value is transferred to their accounts from sources such as the 'ShapeShift 1' exchange market?

Any resource suggestions or insight into my Etherscan findings/hypotheses would be much appreciated. Thank you

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy