ethereum Questions

4

currently, I'm practicing solidity. However, I'm a little confused about accessing a private variable in a contract. For example here; address private a; address private b; mapping (bytes32 =>...
Stoush asked 23/5, 2018 at 16:23

2

I would like to make a word generation function based on the letters of the alphabet, but I don't know how to proceed. I would like to generate 12 words string letters public = "abcdefghijklmn...
Danica asked 31/8, 2022 at 11:12

1

Solved

I'm trying to generate a random number with Chainlink VRF for a raffle system. This number should have a maximum value of ticketOwners.length and a minimum of 0, as I'll be getting the index of the...
Rodger asked 11/12, 2022 at 2:8

4

Reading the docs it says to "add semantics to a function in a declarative ways" Can I understand it as an "interface" in Java?
Figurative asked 8/7, 2017 at 4:18

2

Solved

I came from Java OOP background and understand interfaces. Currently working on a simple budgeting app (https://github.com/compound-developers/compound-supply-examples) that takes ETH or Stablecoin...
Doss asked 8/11, 2020 at 1:15

8

I have been running into the specified in the title. I have developed a smart contract and have successfully compiled and deployed it to the network as follows: 1. Run testrpc 2. truffle compile...
Chemotropism asked 8/2, 2018 at 20:24

4

Solved

I have created a ERC-721 contract deployed on ropston network. Using contract I'm creating NFT's and its totally working fine. Now for the transfer part I need to get tokenID of any NFT and transfe...
Jonna asked 2/6, 2021 at 10:12

7

Solved

I am trying to deploy my SimpleStorage.sol contract to a ganache local chain by making a transaction using python. It seems to have trouble connecting to the chain. from solcx import compile_standa...
Madelle asked 16/1, 2022 at 15:27

2

I'm having a hard time understanding why and when SetApprovalForAll is called on NFT generating contracts. Take Cool Cats, for example. And for convenience there's a screen shot of relevant transac...
Lotta asked 5/11, 2021 at 13:58

8

Solved

An address in Solidity can be an account or a contract (or other things, such as a transaction). When I have a variable x, holding an address, how can I test if it is a contract or not? (Yes, I've...
Travertine asked 5/6, 2016 at 16:48

3

Solved

In a smart contract, let's say I have a function which wants to invoke another function dynamically, based on some internal logic. Here it obtains the function selector as a bytes4 variable. After ...
Stabilizer asked 7/4, 2022 at 2:42

2

before anything here's some context : Let's say I'm implementing a dApp, and I want to reduce the number of times users have to call the related smart-contract. In order to do this, all the users...
Elfredaelfrida asked 10/10, 2018 at 9:52

2

Solved

I am creating a contract that issues tokens. I would like an account that holds tokens to be able to check what percentage they own out of all the tokens issued. I know that Ethereum has not implem...
Augusto asked 11/3, 2017 at 17:56

2

I am using hardhat to compile, deploy and verify an Ethereum Smart Contract. Currently, I am mannually peforming these commands: npx hardhat compile npx hardhat run scripts/deploy.js Wait until...
Athletic asked 8/7, 2022 at 20:31

2

I've already spend few hours trying to understand execution price. I understand the the concept of Mid price as it is the reserve ratio between two pairs. According to Uniswap sdk documentation, Ex...
Candie asked 4/11, 2020 at 4:41

3

index.js:1 Failed to fetch multicall chunk [{…}] 1 Error: sending a transaction requires a signer (operation="sendTransaction", code=UNSUPPORTED_OPERATION, version=contracts/5.0.2)...
Displace asked 22/12, 2020 at 6:44

9

I had an error to run on web3 provider (localhost:8545) Not possible to connect to the Web3 provider. Make sure the provider is running and a connection is open (via IPC or RPC). So I figured ou...
Coopt asked 16/1, 2018 at 3:4

4

Solved

I am using web3j to query the Ethereum blockchain. Now I want to check if a transaction was mined or just sent to the network. How can I achieve this?
Obbard asked 17/4, 2018 at 19:50

15

Solved

I am trying to compile solidity smart contract using npm solc. I tried to follow different examples. Link to example: https://medium.com/coinmonks/how-to-compile-a-solidity-smart-contract-using-no...
Navarro asked 17/11, 2018 at 16:29

2

Solved

So I have followed multiple tutorials on getting started with smart contract development in Ethereum and have read many, many pages on security and development in OpenZeppelin. How exactly do I go ...
Concert asked 20/2, 2021 at 9:37

2

In javascript I run contract's method contract[methodName](...params, { from: myAccount }, (err, response) => { console.log('get transaction', methodName, err, response); if (err) return rej...
Lentil asked 31/5, 2018 at 10:16

8

Solved

I'm ramping up on learning Solidity, and have some ideas. At the moment I am curious if files/images can be put on the blockchain. I'm thinking an alternative would be some hybrid approach where so...
Wieche asked 25/10, 2018 at 16:54

3

I just started to learn Solidity as a personal challenge. I'm not a developer so I've a loooooong way to go. I'm following the Ethereum.org tutorial, here is what I've got doubt about: What does [m...
Fredi asked 1/2, 2018 at 12:11

4

Solved

Problem I am trying to use a method of a contract on the test network (ropsten), but it fails due to this error: reason: 'cannot estimate gas; transaction may fail or may require manual gas limit'...
Dropline asked 7/1, 2022 at 13:38

5

Solved

I'm trying to compile (through Hardhat) a contract that imports several interfaces with different Solidity versions but I'm getting the following error: Error HH606: The project cannot be compiled,...
Antigen asked 28/6, 2021 at 12:23

© 2022 - 2024 — McMap. All rights reserved.