Hot answers tagged

2

Ether is not an ERC20 token - however, the WETH contract creates Wrapped Ether, which is an ERC20 token backed 1:1 by Ether.


2

If a transaction receipt shows the to field empty and an address in the contractAddress field, does it mean that the specified contract was created? Yes, it implies that a contract was deployed at the address specified in the contractAddress field. And the exact opposite implies that the transaction was sent to a contract which has already been deployed at ...


2

If the to field is empty it is most likely a transaction that deployed the smart contract, found in the contractAddress. logs contain emitted events from Solidity. You can match them to actual ABI events using web3.py Contract API. logs are optional. Smart contracts may not emit them and they are not present in account to account transfers. Hope this ...


1

That error is saying that your account does not have enough ETH to pay the transaction fee. At this time, all transactions on Ethereum incur a fee paid for in ETH. There are, however, ways too offload the fee payment to someone else with meta-transactions. Wallets like Autheruem actually pay the transaction fees for you, so your users would not have to have ...


1

Each token has exactly one token contract which acts as the token ledger. A token contract is typically for just keeping track of that one token - who owns and how many of said token. A token contract typically cannot manage other tokens. In theory you can add such functionality into one but it would not be a very good idea. If you want to have some way to ...


1

You can do something like this: const fs = require("fs"); const Web3 = require("web3"); const NODE_ADDRESS = process.argv[2]; const PRIVATE_KEY = process.argv[3]; const CONTRACT_NAME = process.argv[4]; const ARTIFACTS_DIR = __dirname + "<path to your bin/abi folder relative to this script>"; const MIN_GAS_LIMIT = 100000; // increase this if ...


1

The gas required exceeds allowance (8000029) or always failing transaction error consists of two parts, either one of which may have taken place: The gas required for executing the transaction exceeds the gas-limit for the given block The transaction has reverted due to require(cond) with cond evaluating to false From my experience, this error is issued ...


1

Please check this tool. You need to make your javascript browser compatible to use require() features.


1

Actually point made by Jaime is right. You cannot really stop your contract from receiving tokens, however, you can use approveAndCall to receive tokens on the front end of your dapp. And yes there is a way to verify if the sending address is a contract address and also if it is your own contract, hence revert. Check out ERC223 standard, lots were discussed ...


Only top voted, non community-wiki answers of a minimum length are eligible