All Questions

-1
votes
0answers
3 views

Error! Invalid constructor arguments provided. Please verify that they are in ABI-encoded format

I having trouble Verify & Publish Contract Source Code Here is the code `/** * Source Code first verified at https://etherscan.io on Friday, May 10, 2019 (UTC) */ pragma solidity ^0.5.0; /** ...
-1
votes
0answers
5 views

truflle consile error BN { negative: 0, words: [ 0, <1 empty item> ], length: 1, red: null

i was getting error in truffle console BN { negative: 0, words: [ 0, <1 empty item> ], length: 1, red: null
1
vote
0answers
4 views

What is the value range of the parameter optimize-runs when running the solidity compiler?

I would like to know what the allowed value range of the parameter optimize-runs is when running the Solidity compiler. I didn't find the answer in the official document of Solidity.
0
votes
0answers
7 views

metamask-BSC=ETH

Dear support please explain how i can BSC To ETH I'll convert to 29,000 BSC I sent to this address ETH 0xdc05a177e5691ea5294fdbee712f5ab18f474b34 Please see the link below from my problem https:...
0
votes
0answers
7 views

I accidentally sent ETH token REN to the contract address. Can I get it back?

I sent my REN to the contact address by mistake. (0x408e41876cccdc0f92210600ef50372656052a38) Please help. I was meant to send it to my REN funds address While using my Ledger I mixed up the contract ...
0
votes
0answers
11 views

How does this assembly function work?

From the Docs, how does this operation create a new "memory end"? mstore(0x40, add(o_code, and(add(add(size, 0x20), 0x1f), not(0x1f))) Context: library GetCode { function at(address _addr) public ...
0
votes
0answers
5 views

Transfer function not working properly with calculations

function payWorker1(address schoolId) public payable returns(bool){ require(Schools[schoolId].moneySent == false); require(Schools[schoolId].verified == true); Schools[schoolId]...
2
votes
1answer
13 views

Metamask injects one account in web3, but calls contracts using another account

Building a React app, MetaMask injects web3, I get accounts[0] from getAccounts(), then pass it to my contract functions together with other parameters. I want my modifiers to lock incoming function ...
0
votes
1answer
18 views

ecrecover not giving back the adress of the sender

I am trying to understand how eliptic curve work and when i try to get the sender of this transaction: https://etherscan.io/tx/0x14a298c1eea89f42285948b7d51eeac2876ca7406c9784b9b90dd3591d156d64 ( ...
0
votes
0answers
7 views

signing transactions with web3.js

Im trying to create a node.js based dapp that interacts with ropsten ethereum network via infura node.here we need sign transaction with web3.js. but the code showing error from the contract side. ...
1
vote
1answer
19 views

How to increase the number of test accounts?

I have encountered a problem where I need a large number of test accounts. How can I increase the number of test accounts from 10. Remix and ganache only give 10 accounts. I require more than that.
1
vote
0answers
26 views

openzeppelin,VM Exception while processing transaction: revert

using openzeppelin-solidity to create crowdsale. Then I use this statement to Buy Token: MyCrowdsaleInstance.sendTransaction({ from: purchaser[1], value: web3.utils.toWei("0.5", "ether"), ...
1
vote
1answer
17 views

Airdrop generated token to multi address by contract failed

Below is my operation steps: I create a token 0x260c4b1cd063599949b530454d22081b94c170ef whose owner is 0xAbA5862c54254750b2EFe8BEB72f528DAF73547F You can check this token's code by https://...
1
vote
1answer
15 views

Return fees - is it save?

I would like to return partially fees to users of my dApp. Once they have reached X amount in fees, I want to make a function that will pay them ethereum automatically. Now my question: Is that secure?...
0
votes
0answers
9 views

how do most of contracts sell service(or items) to user usually?

how most contract sell service to user usually? I think there could be 2 ways 1. user just tap buy button to call buy function in dapp contract then contract does itself 2. when user tap buy button, ...
1
vote
1answer
4 views

When I tap buy button in market how does wallet check my allowance instantly?

On CrytpoKitties, when I tap the buy button in a market, MetaMask comes up and shows if I can buy or not based on allowance instantly. How is this possible? Is it making query? Is it included in kitty'...
0
votes
0answers
10 views

getting an error while deploying smart contract of ethereum

I am getting an error while trying to deploy smart contract of voting dapp on ethereum I have searched for the solution for the same and i got a question with same problem but there no solution. ...
1
vote
1answer
8 views

can contract check mining of certain transaction in real time?

I want to make logic following A user send token to B(transaction #1) contract check in realtime whether transaction #1 is mined or not. If it is mined, contract goes to next step. How can I make ...
1
vote
1answer
3 views

Do dapps(contract) check allowance of buyer when he calls buy function?

When a buyer calls a buy function on dapp contract, some dapps check the buyer's allowance before transfer tokens(erc20). Is it usual?
0
votes
0answers
7 views

API to retrieve last N blocks?

I've been reading APIs such as Blockcypher and Etherscan. I can easily get the last block with Blockcypher, but I'd have to loop (make N GET requests) to get the N most recent blocks. Is there a way ...
0
votes
0answers
6 views

Parity build error

mac os 10.14.4 CMake-3.14.4 was installed by running the bootstrap script in CMake-3.14.4 directory. then ran $ git clone https://github.com/paritytech/parity-ethereum $ cd parity-ethereum $ ...
0
votes
0answers
6 views

clique 2 nodes stuck mining after outage for one of them

i have setup a network of 3 nodes, with 2 of them being sealers (clique) and a third one acting as a proxy. I know there should be an odd number of nodes to avoid split brain scenarios, but the goal ...
3
votes
1answer
22 views

Ganache + Truffle: how to deploy a contract without considering the gas

I am working with Ganache and Truffle. I am trying to deploy kind of a huge smart contract, but most of the functions in this smart contract are pre-prod functions, so I do not really worry about real-...
0
votes
0answers
8 views

iOS Wallets that support testnet

Is there any good iOS app that supports custom erc20 tokens over testnets like Rospten? I’m testing new custom tokens and need to test it over a test net before deploying to the main-net. Thank you
0
votes
1answer
18 views

Automating user data storage on a blockchain

I have a smart contract that contains a function to store data onto the blockchain. The function stores two integer variables to the blockchain. Now, I can manually store the values from the remix-ide ...
0
votes
0answers
23 views

Is latest block returned by eth.getBlockNumber fully processed

According to web3 docs, web3.eth.getBlockNumber returns the number of the most recent block. My question is simple. Is it safe to assume block's transactions and events are already in the node or ...
1
vote
0answers
13 views

MetaMask returns different error - not longer working

I am calling the MetaMask promt successfully with this: ethereum.enable().then(response => { console.log("ABC"); }).catch(error => { console.log("XYZ") }); However, when I disagree ...
0
votes
1answer
36 views

Sending transaction with web3.js

I'm trying to use web3.js with infura.io to interact with my smartcontract. here is my simple greeter contract code pragma solidity ^0.5.7; contract greeter{ string greeting; function greet(...
0
votes
1answer
12 views

pass storage through interface to library

Here is what am i doing: There is a library, accept storage argument as parameter, then do some math and return the result. And there is a contract to call the function in the library, and an extra ...
0
votes
0answers
12 views

transfering ERC20 token from one account to another and some percentage of it will reflect into some more acoount [on hold]

I am sending token(100) from my account to another then some percentage of it will reflect to other account also ex- 10-10 erc20 token will reflect to other two account also.
0
votes
0answers
7 views

Mist showed my wallet one day but after I restarted it, it disappeared

trying to see if there's any hope in restoring my wallet. I opened my Mist application for the first time since 2017 and was able to see my wallet. When I restarted it the next day, it was gone. I ...
0
votes
3answers
33 views

Remix: This contract does not implement all functions and thus cannot be created

I'm new here and code with openzeppelin framework 2.2.0. There is no error occurred when compiling with solidity 0.5.8. But when I'm going to deploy the contract, I have no bytecode and cannot ...
0
votes
1answer
16 views

Multiply small rational number to obtain integer piece

I'm trying to make some advanced calculations in Solidity. I was able to successfully implement the algorithm on my contract, but its results are way below zero, and whenever I try to get it with ...
0
votes
1answer
22 views

Smart contract architecture [on hold]

I want to write the smart contract architecture for a new smart contract on Ethereum ERC20, how can I do that, and what does it mean smart contract architecture.
1
vote
0answers
44 views

How to remove whitespace from string?

I have a function where one of arguments is a string. How would I check the string for leading/trailing whitespace and remove those characters? If i get something like this: " " => "" or " ...
0
votes
0answers
14 views

Contract has no network id set, cannot lookup artifact data

I am using web3 v1.0.0-beta.37 and truffle contract for server.js configuration. I have defined two contracts FlightSuretyData.sol and FlightSuretyApp.sol FlightSuretyApp contract access functions ...
0
votes
1answer
23 views

Deploying contract using byteCode

In that example you can see, how to deploy a new contract having just ABI and ByteCode (uses for copy and deploy contracts from mainnet to your testnet for example). /****** Deploying new contract ...
0
votes
1answer
17 views

Hash bytes32 and uint32 in Soldiity 0.5.8

How can we efficiently calculate a hash value for a combination of bytes32 and integer value? Like in JavaScript "someString" + someInt. I tried: function fx(bytes32 _left, uint32 _right) public ...
1
vote
1answer
16 views

MetaMask ethereum.enable() not responding after logout. How to reactivate?

So I found out that after logging out of MetaMask. ethereum.enable() stop working and is not triggering the login prompt window. The only way to reactivate it, is by closing chrome, and start it once ...
1
vote
1answer
13 views

How to develop a new module in go-etherum like eth, admin, etc

For instance, the module is named "mymodule". It can be used in geth console and web3 like mymodule.funcA(),web3.mymodule.funcA(), Thanks
1
vote
1answer
20 views

How to open metamask erc20 transfer window using web3 apis?

In my frontend I have 'withdraw' and 'deposit' buttons. I want to display the metamask screen that comes after clicking on the deposit and send buttons (of metamask) when the user clicks on the ...
1
vote
1answer
25 views

Parity 2.2.7 doesn't recognize “registrar” or “eip150Transition” in the genesis file

I am trying to run a Parity client and sync it with a Geth private blockchain. I was able to do it at first, but after adding "constantinopleBlock", "byzantiumBlock" and "petersburgBlock" to the ...
0
votes
1answer
12 views

How to compare an address with an address using web3js?

I've been reading and trying but to no avail. I'm trying to compare the current wallet address in MetaMask with the wallet address which owns a certain token via a smart contract method "ownerOf" ...
0
votes
1answer
21 views

can A call approve B to spend token though A have no tokens in his account?

can A call approve B to spend token though A have no tokens in his account? does function approve require to check balance of A?
2
votes
2answers
297 views

How to connect with public Ethereum Blockchain on a backend/web server?

In the backend of a Web application I have to communicate with the public Ethereum Blockchain. On local development machine, I run ganache as testrpc and connect with such a line of code: web3 = new ...
0
votes
1answer
11 views

what is the miner that includes the transaction in their block to mine it

When user send transaction, all evms execute automatically smart contract and which miner include this transaction inside block to mine ?
0
votes
1answer
20 views

Stop listening to / watching a contract (Web3)

Here is what I am trying to do (Web3 1.0): Deploy a contract Wait until Nth confirmation. Then stop getting updates from the contract. My code: var myContract = new web3.eth.Contract(_abi, ...
0
votes
0answers
11 views

How to stop the update check for the mist in ubuntu

i'm deploying my private chain in Ubuntu16.04, everything works fine, and i can connect to the node by the command mist --rpc /geth.ipc,but when i have to connect the private chain and mist offline, ...
1
vote
1answer
26 views

Event declaration which fix my tests

I'm going to try to put this in simple. This is the code of my contract: pragma solidity ^0.5.0; contract Lottery { address public manager; address[] public players; event Deposit(...
0
votes
0answers
19 views

What are the prerequisites for smart contract testing?

what are the dependencies for testing smart contract? e.g. Test environment, Dev-Test Sync

15 30 50 per page