10
votes
Accepted
does using external over public in a library reduce any gas costs?
Declaring a function as external rather than public does not affect gas usage at all, neither in contracts nor in libraries.
In earlier versions of Solidity, only external functions could take ...
7
votes
Accepted
Is there a way to sign message by the Smart Contract?
Yes. It is EIP-1271: Standard Signature Validation Method for Contracts. You can find details here.
EIP-1271 is supported e.g. by Gnosis Multisig.
7
votes
Accepted
What prevents miners from cooperating and causing intentional chain reorgs?
Nothing prevents collusion
From former Bitcoin Core developer Greg Maxwell https://old.reddit.com/r/Bitcoin/comments/ddddfl/question_on_the_vulnerability_of_bitcoin/f2g9e7b
The attack would work just ...
eth♦
- 77.8k
5
votes
How to delete geth? How to update geth?
You can run the following Commands to Completely Remove geth and related stuff. Run These With Caution, They have sensitive data in them.
$ sudo apt remove ethererum --purge # Remove All Apps ...
4
votes
How to get private through UTC files in keystore
2021-12
FYI for Googlers, you can inspect the UTC keystore file with the ethkey cli tool that comes with geth with the --private flag to show the private key
ethkey inspect --private test_chain/...
4
votes
Accepted
Geth not updating blocks after restart
The block 12964999 is the last block you can download without upgrading to EIP 1559. After block 12_965_000 we have forked to a new feature list which you can find out on the internet for more details....
4
votes
how does optimistic rollup work?
Since L1 contract doesn't verify anything about submitted blocks apart from some basic stuff, a malicious sequencer can do all kinds of nasty stuff, like for example adding an invalid transaction that ...
4
votes
how does optimistic rollup work?
There are many details to optimistic rollups. Nika's example can be used to explain some of the main ideas.
10 ETH is locked on L1
Note that the L1 rollup contract does not know that the 10 ETH ...
eth♦
- 77.8k
3
votes
How to fix checksum mismatch in downloaded node for Ethereum Wallet?
Mist and Eth wallet have been decommissioned in 2019. https://avsa.medium.com/sunsetting-mist-da21c8e943d2 Use something else.
3
votes
Given a RAW Transaction - how to get senders address
Just to update this answer, there is a requirement parameter on the AsMessage call. you need to pass a base fee, though the transaction is a free on, place a big int 0 into the call as shown below:
...
3
votes
Accepted
getTransaction returns null for old transactions
Starting from geth 1.10, node will not index old transactions and unindex existing old ones as new blocks pile on.
That's configured in the --txlookuplimit value option, as explained in docs:
Number ...
3
votes
What prevents miners from cooperating and causing intentional chain reorgs?
As Mikko mentioned, it would be super difficult for them to start cooperating in such a way. If their miners find out, they can just easily switch to an "honest" pool.
But assuming that ...
3
votes
Is there a way to control METAMASK via some type of api feature? I want to use it as my backend to send / receive eth and tokens
Metamask is a browser extension, thus its scope is only within a browser. You can write automation scripts but that's going to be too cumbersome and unstable.
A better alternative would be to use ...
3
votes
Is there a way to control METAMASK via some type of api feature? I want to use it as my backend to send / receive eth and tokens
Metamask is simply a signer(provider + wallet) that interacts with other nodes. You can simply use the ethers.js library using a third party API providers like Alchemy/Infura and write automated ...
3
votes
Accepted
what does ERC721 _checkOnERC721Received do?
If is usually called after a token has been transferred (in same tx).
If the receiver of the token is a contract, it checks if the contract implements the onERC721Received interface.
If no, it reverts ...
2
votes
How to select a network id or is there a list of network ids?
NETWORK
CHAIN ID
RPC
EXPLORER
ARBITRUM (mainnet)
42161
https://arb1.arbitrum.io/rpc
https://arbiscan.io/|
ARBITRUM (testnet)
421611
https://rinkeby.arbitrum.io/rpc
https://rinkeby-explorer.arbitrum....
2
votes
what is the use of the payload field in the ethereum transaction reciept?
Transaction is a message that is sent from one account to another account (which might be the same or empty, see below). It can include binary data (which is called “payload”) and Ether.
If the target ...
2
votes
geth "Smartcard socket not found, disabling" warning message
remove [Node.LogConfig] section from config.toml
2
votes
Subscribe to new txpool transactions on geth node
Supplement to Eugene's answer, I have this fiddle testing the speed of two nodes catching pending transactions. It was built with web3.subscription. Hope it helps.
Explanation of the code is also here....
2
votes
Updating ERC-721 Token's Metadata after it was Minted
I created an NFT, listed it on OpenSea testnet. TestNFT
The NFT had a link to a json metadata file. After a few minutes, I edited the json metadata file, and then hit the refresh metadata button on ...
2
votes
How to remove/increase execution timeout of the geth's evm?
You can run geth with the --rpc.evmtimeout flag to change the 5s timeout. If you set it to 0 , then timeout will be infinite. Check geth --help for more info.
2
votes
difference between metamask and ethereum provider
As you probably know, the ethereum network comprises nodes and each of these nodes has a copy of the blockchain. When we want to interact with the blockchain, we need to interact with one of these ...
2
votes
Running BSC node in light mode?
You can't. BSC does not "officially" support light mode.
However, BSC 1.1.3 implemented something called diffsync, which has security characteristics of light mode.
Diffsync, when activated ...
2
votes
How long does it take to fast sync a geth node in 2021?
can't use an HDD, need to use an SSD.
"Q: Wait, so I can’t run a full node on an HDD?
A: Unfortunately not. Doing a fast sync on an HDD will take more time than you’re willing to wait with the ...
2
votes
How to bypass mempool
What is happening there and how does it work?
One of two things is happening:
The miner is mining their own transactions;
A user/bot is sending their transaction to a private/permissioned mempool ...
2
votes
eth.syncing is falling behind
I believe something got corrupted when I lost connection. I resynced from scratch and everything has been working fine. I have even cleanly exited and restarted my node and it catches back up fast now....
2
votes
How to get all ERC721 tokens deployed on the smart contract
Check the MakerDao Multicall.js a library that allows multiple calls to smart contracts with a single JSON-RPC request.
2
votes
(web3) Get 'Token Transferred ' log just like etherscan
I had found it, receipt.logs are basically the etherscan's 'token transffered'. In this case I have a txHash="0x12caf26ee210ebcdaf83a467078eb96be03fc68f8178a1096bea42f047ed44e3"
To get ...
2
votes
Accepted
Geth ran fine, but suddenly it's stuck and don't know the reason why
I found what was the reason for this issue for my case. I was using Geth version 1.10.3-stable. So I looked for the new releases at go-ethereum github page that if new versions solving the issue like ...
2
votes
Unable to sync Ropsten testnet with Geth 1.10.5
OK, I got it. It's a geth bug. A new release is published to fix it.
https://github.com/ethereum/go-ethereum/releases/tag/v1.10.6
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
go-ethereum × 5940solidity × 856
web3js × 730
blockchain × 577
private-blockchain × 497
contract-development × 357
synchronization × 297
transactions × 292
mining × 243
ether × 229
json-rpc × 225
truffle × 208
mist × 197
remix × 188
geth-debugging × 180
openethereum × 172
ethereum-wallet-dapp × 166
golang × 163
wallets × 162
contract-deployment × 144
nodes × 141
testnets × 133
tokens × 127
accounts × 123
contract-design × 111