New answers tagged contract-development
0
votes
Max possible ERC20 Tokens allowed with 18 decimals?
THE NETWORK FORMULA IS.... <>=E-18 @ SHAR256
HA HA HA...
XY XYO EVERYWHERE I GO.!!!!!
FHR GEOHACKER.
1
vote
Does creating a new NFT collection require a contract for it?
There are also services that allow you to mint NFTs within their platform for free. This is called lazy minting and can be found at Opensea.
However these NFTs don't have much value as they are not ...
1
vote
Accepted
Does creating a new NFT collection require a contract for it?
Yes, in order to create an NFT collection you have to create a smart contract that inherits the ERC721 standard and deploy it.
If your NFT contract is meant to be fairly standard I suggest that you ...
1
vote
how to recover funds to creator account on this particular incomplete mev contract WETH
It's a scam.
You got scammed.
Unfortunately you are not going to get your money back. File a report with a police for the fraud against whoever you got this code from.
For the future, don't try to do ...
1
vote
Contract analysis - owner spawned 1000 billion tokens ($20 bounty)
This is the constructor of the token contract
constructor(address router_, address marketingAddress_)
ERC20("exit(0);", "exit(0);")
payable
{
uniswapV2Router = IRouter(router_);
...
0
votes
How to track scammers through etherscan?
I made the same mistake and tryed it aswell, but somehow I was able to withdraw my initial 0.1eth from the contract which I made for a test so, I hope there could be a way to get the funds back ...
0
votes
ProviderError: Error: Transaction reverted: function selector was not recognized and there's no fallback function
This error usually occurs when the interface you are using is not correctly picking up the functions from the contract address you are passing in it.
Wherever you are doing the following in smart ...
0
votes
Source File requires different compiler version
Just add this :
compilers: {
solc: {
version: "^0.4.20"
}
}
Where "^0.4.20" is the version of the compiler you want to use.
So your truffle config file should look like this ...
0
votes
Array of contracts stays empty
Every time you call function addDog in your Human contract it will always deploy new contract of Dog in blockchain and return its address and push it into dogs array, to understand it better I ...
0
votes
cannot estimate gas; transaction may fail or may require manual gas limit
Same problem.
I solved it in this way.
Create a new directory totally empty: /blabla/createsmartaccount_dir.
Create these 2 files inside it.
/blabla/createsmartaccount_dir/index.js
/blabla/...
0
votes
What public testnets (test networks) and faucets exist?
You can use https://www.buildbear.io/ and create your own Testnet that comes with a built-in faucet.
1
vote
web3.js how to call receive() external payable?
The receive() function does not exist but the fallback function exists, it will be triggered when a contract is sent Ether without any data. To interact with this receive() function in web3.js, you ...
1
vote
Accepted
How to find owner of contract deployer on etherscan website
You can find the deployer address in etherscan
here : https://i.stack.imgur.com/R50sN.png
Deployer : https://etherscan.io/address/0x6cfa7561bbf940ab4b5c0507d4c9e45c68552b1b
1
vote
Accepted
Why doesn't this try/catch block catch the revert in `asset.symbol`?
try..catch doesn't catch the boundary exceptions, just the inner method call. Exactly that, what you have mentioned:
checks if address is not void
checks if extcodesize exists
--checks if method ...
0
votes
Use string type or bytes32?
Your system architecture understands that Bytes32 has a maximum of 32 bytes of memory allocation. 1 byte = 1 ASCII character.
However, the memory allocation of String data type is not fixed. Hence ...
0
votes
Error: Hydration failed because the initial UI does not match what was rendered on the server, Wagmi and Nextjs
It is advisable to create a reusable custom hook to maintain the autoconnect logic and enable its reuse in multiple locations as needed.
Custom Hook
import { useEffect, useLayoutEffect, useState } ...
0
votes
Accepted
Gas estimation failed for marketplace contract
I realized where the problem was coming from.. it is the if...else statement in the buy function that was causing the spike in gas estimates. So i created two functions that were to allow transferring ...
0
votes
How to fetch data from a website to a solidity smart contract?
You can utilize Chainlink Functions (https://docs.chain.link/chainlink-functions) to fetch any API data from Web2 to Smart Contracts in a decentralized manner.
You can refer to some examples at https:/...
0
votes
How to fetch data from a website to a solidity smart contract?
it is not possible for the smart contracts to fetch data from any website. because smart contract can not call the any API on the website Directly.
0
votes
What is Ticks on Uniswap?
in uniswap v3 we have concentrated liquidity. User has to decide in which price range s/he wants to have their liquidity gets traded. for this, uniswap has to find a way to decide the price ranges. ...
3
votes
Accepted
Do immutable variables influence the contract bytecode?
Yes. Bar's bytecode depends on value_, because immutable variables are not part of contract storage.
We can prove this with the following Foundry test:
pragma solidity >=0.8.19 <0.9.0;
import { ...
0
votes
What public testnets (test networks) and faucets exist?
Free Sepolia Testnet Faucet that lets you claim 0.5 Sepolia ETH per day.
https://www.infura.io/faucet/sepolia
0
votes
How to use Role-Based Access Control via Proxy?
On first read, by "Proxy", I assumed you meant a transparent proxy such as Open Zeppelin's TransparentUpgradeableProxy.sol. On second read, your approach seems more like applying modularity. ...
0
votes
Can the EVM execute a function over multiple blocks?
Nope It can't. A block is a compilation of transactions that is sent to the Ethereum network and when the block of particular number is validated by validator, only then a transaction passes through. ...
0
votes
Can the EVM execute a function over multiple blocks?
No, execution must happen within one block - though of course if that is not "enough" the execution will instead run out of gas and revert.
0
votes
How to call a read function within "contract B1" when the function is defined in a higher contract that imports "contract B1" as an extension?
So if I have understood you right, there are some options. I would prefer to use a common interface, and as contract B1 doesn't implement the interface, you should mark it as abstract:
interface ...
0
votes
What public testnets (test networks) and faucets exist?
As for May 2023 there are 2 public test-networks: Goerli (Chain ID: 5) and Sepolia (Chain ID: 11155111).
They both have testnet explorers:
Goerli: https://goerli.etherscan.io/
Sepolia: https://sepolia....
Top 50 recent answers are included
Related Tags
contract-development × 4619solidity × 2547
contract-design × 1081
remix × 487
contract-deployment × 400
tokens × 374
go-ethereum × 362
contract-invocation × 362
web3js × 352
contract-debugging × 282
blockchain × 254
erc-20 × 246
truffle × 235
transactions × 230
gas × 141
ether × 139
dapp-development × 112
dapps × 88
security × 86
arrays × 83
evm × 82
nft × 82
storage × 79
metamask × 77
events × 74