All Questions

0
votes
3answers
41 views

withdraw function does not work on ganache

I have written a very basic smart contract It can accept ethers using a deposit function ppl can withdraw from their balance using withdraw function Everything works fine except withdraw function,...
1
vote
1answer
24 views

Debugging a VM error in solidity

I'm getting the following error while running a test in truffle: Error: Returned error: VM Exception while processing transaction: revert Now, the code is simply to big and complicated to run ...
1
vote
1answer
21 views

How to use own custom token instead of gas price in ether? [duplicate]

I want to make my token and want that the token should be used as gas price. Is that possible,if yes please guide me for the same.
0
votes
1answer
37 views

Ganache provider not working with web3

I am trying to run a test script for my smart contract but ganache provider is not being accepted by web3 here is my code. const assert = require('assert'); const ganache = require('ganache-cli');...
0
votes
0answers
21 views

Dose not sync Ethereum main net

I have wont start go-ethereum full node on my server. when i have start with ./geth --rinkeby --rpc --ws console started sync process Ok. But when i wont start with mannet ./geth --rpc --ws ...
0
votes
1answer
17 views

eth-netstats app - Not able to see Node Type. Also network, protocol and web3 values are being displayed as null

I have a network of 3 nodes and I can see that all nodes are listed on the dashboard. However for one of the node, I am see the values of network, protocol and web3 as null. Also I am not able see ...
0
votes
1answer
33 views

Send ether to a contract [closed]

I am doing a simple smart contract for learning purposes. I would like to send ether to a smart contract after a buyer selects an item from a drop down list. I have not yet managed to transfer the ...
0
votes
1answer
27 views

infura don't catch event

when i'm working on ganache all event that i have emit are store in my nodejs server but when i turn to kovan or ropsten my server don't catch event . i'm working with infura this my code no ...
0
votes
0answers
9 views

How to pass the function of a parsed ABI to MetaMask?

I am developing a dApp that is parsing an ABI and then it shows the functions of it and fields that is for every function's variable and i want to send the function with its variables to MetaMask to ...
1
vote
1answer
39 views

Why is it impossible to get return values of state-changing calls? [duplicate]

From reading I have surmised that it is impossible to get the return value of state changing calls. Consider this example.sol: contract F { function createChildContract() public returns (address ...
0
votes
1answer
13 views

I have a question relating to the Ethereum transaction

The amount of I had was transferred to another wallet I didn't know. https://etherscan.io/address/0xcf487d1a303b42bb419f06717209ef5358294759 I have a few questions about why this could happen. Can ...
2
votes
0answers
14 views

How Merkle trees are implemented in a database exactly

I have just checked out these resources: What is a Merkle Tree? Beginner’s Guide to this Blockchain Component Using Merkle trees to detect inconsistencies in data Exploring the use of Hash Trees for ...
0
votes
0answers
28 views

Running out of Gas while deploying contract via web3.js

// contract is storing ABI var instance = contract.new( "0x12", // bytes32 "0x12", // bytes32 [], // array of addresses 11, // uint 11, // uint "...
0
votes
0answers
7 views

Token Swap in ERC1400

Any idea about the swapping of tokens under ERC 1400. If anyone knows pleas e share some references documents for the same
0
votes
0answers
19 views

cannot retrieve token price

i am trying to code a decentralized application and what i am trying to do right now is to get the token price of 1000000000000000 and display it. but when i try to get token price i keep getting 0. ...
0
votes
1answer
16 views

I want to withdraw amount from Receiver Contract's tokenFallback() function in ERC223 how to implement this scenario?

I am using ERC223 standard token transfer contract and receiver contract which includes tokenFallback(). I've transferred tokens from my ERC223 contract to receiver's contract address, now I want to ...
0
votes
1answer
18 views

Constantinople gas change, reentrancy possibilities

With the new reduced fee for using SSTORE for 'dirty' storage slots, is it possible to re-enter a function from a send() or transfer() and have the contract call send() or transfer() again? Or is it ...
0
votes
1answer
26 views

Unhandled Rejection (Error): invalid string value (arg=“x”, coderType=“string”, value=5)

Using Truffle unbox react to unbox a boilerplate. received the following error from running npm run start Changes: Addition of "memory" parameters in the simpleStorage.sol Changed unit to string in ...
1
vote
1answer
22 views

web3 is not defined problem

This is my simple html source code for my website. <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewpoint" content="width=device-width, ...
2
votes
2answers
111 views

Why are transaction tries in Ethereum not plain Merkle Tries?

I understand the Ethereum block header contains a Merkle Patricia Trie (MPT) root for the global state, one for receipts (which I don't understand but am not focussed on for now), and one for all the ...
0
votes
0answers
15 views

Missing binary for Win kernel :\ethminer\bin\kernels\ethash_geforce 940m_lws192.bin

Win 10 x64 ethminer -G stratum+tcp://@eu1.ethpool.org:3333 m 01:08:55 main ethminer 0.17.0 m 01:08:55 main Build: windows/release i 01:08:55 main Found suitable OpenCL device [GeForce ...
1
vote
2answers
36 views

Unable to get abi and bytecode when compiling using solc

I am new to solidity and am following a tutorial that uses solidity compiler version 0.4.25. In the tutorial, solc.compile is used in a compile.js file followed by extract abi and bytecode and ...
1
vote
1answer
9 views

Smart Contract Tokens and exchanges?

Is there any special code you need so your token can be traded on exchanges example Binance? Right now its a pretty basic contact like Fixed Supply token. Or is it as long as the exchange(...
1
vote
1answer
24 views

How does USDC manage to only cost 25k gas instead of 35k++ for transfer?

I am baffled why Centre's USDC only costs around 25k for token transfer instead of 35k++ like other common ERC20. For example this is Gemini USD: https://etherscan.io/tx/...
1
vote
0answers
20 views

Event Watching Web3 v1 in Truffle test

I want to test off chain data input in truffle testing. So basically I kick off a test and then need to wait for another program to do something. In the old web3, this worked great: function ...
1
vote
0answers
40 views

“before all” hook: prepare suite

This is the error code: Adoption.sol code: TestAdoption.sol code: I dont know how to solve this, it fails when i try to use this comand: "truffle test". Thanks.
1
vote
1answer
14 views

Issue with Contract function return value data type

I am using a simple contract Contract code contract Bank { address public owner; mapping(address => uint) private customerBalance; event fallbackCalled(address, uint256); event ...
0
votes
2answers
38 views

How to install web3 latest version manually in windows10?

I used npm install web3 which would install (as of now) v1.0.0-beta.41 But it gave me the following error: E:\sheep\node_modules\sha3>if not defined npm_config_node_gyp (node "C:\Program Files\...
0
votes
4answers
40 views

Programming contracts and blockchain: Where do I start?

So I'm doing my academic practices in my university and I'm assigned to a company that has plans of doing blockchain projects. Neither of them has actually been defined so far, and I'll work alone. ...
0
votes
0answers
18 views

Myetherwallet Balances?

I was testing on (Ropsten) Myetherwallet, everything was fine yesterday morning, then that evening, my balances (Ropsten Ether and Tokens) would not show. I was getting "(error_21) Not a valid ERC-...
0
votes
1answer
12 views

Minted Crowdsale vs Non Minted Crowdsale

I am exploring openzeppelinr-solidity smart contracts for Initial Coin Offering(ICO). There are two options available for a token smart contract one is to have hardcoded total supply tokens or mint a ...
0
votes
1answer
33 views

Invalid bytes32 value [duplicate]

I am trying to learn about solidity so I just watch a tutorial about it, I already copy the same code as the tutorial but there is an error with bytes32. Here it is: That is the deploy code: And ...
0
votes
2answers
19 views

Truffle console keep showing “undefined”. Solved by rolling back to v4 stable

I have updated my truffle version to the latest v5.0.3. By running truffle version, I can get the following version statements. Truffle v5.0.3 (core: 5.0.3) Solidity v0.5.0 (solc-js) Node v10.8.0 ...
1
vote
0answers
14 views

Secuirty Token Escrow setllement

Is Esrcow could be applied in ST 20 tokens ? If yes, please guide for the same.
1
vote
0answers
16 views

What is contex_canceled error in Geth?

I'm trying to run a public method in my smart contract in rinkeby network. But it fails with following error in Geth, INFO [02-06|06:01:19.593] Served eth_call conn=172.17.42.1:23241 reqid=1 t=320....
0
votes
0answers
22 views

Decline a transaction in a PoA network

Is it possible to decline a transaction in a PoA network? Or to say it in other words: Can a sealer decline to put a transaction into a block he is going to mine? I want to prevent transactions to be ...
0
votes
1answer
25 views

Who is “from” in case of inheritance in solidity?

I have the following code: // Test.sol pragma solidity ^0.5.2; import "./TestBase.sol"; contract Test is TestBase{ string[] name ; constructor() public payable { name.push("sheep"); ...
0
votes
1answer
27 views

Multi-signature Ecrow time based?

I have a user A and a user B. They do not trust each other. So, they run the following smart contract: User A specify a time locked deposit of x coins to user B under a predefined condition( For ...
0
votes
2answers
15 views

Keep private data in contract and manage access

Is it possible to keep data in a contract, in a similar way that we can create wallet contract? Wondering if it would be possible to keep that and then manage the access to this 'hidden' data ...
0
votes
1answer
20 views

Calling another contracts function -minimum info required

I understand how to call another contracts function. My question is, if I want to use an interface like in this question over call(): Call function on another contract contract Name { mapping(...
0
votes
1answer
25 views

Problems with Geth 1.8.19-stable

I am trying to add static peers by static-nodes.json file but with this version it does not work. What is the way to do it ? If I add peers with admin.addPeer() it works, but if I am using --syncmode ...
1
vote
2answers
65 views

Solidity public variable getter call doesn't return

I have deployed a very basic solidity contract (pragma solidity^0.4.0) to Rinkeby. When I call the getters on my state variables, nothing is returned and I do not understand why. To compile the ...
0
votes
1answer
27 views

Quorum node address

In the Node class of the Quorum Web3j. The String address what is? package org.web3j.quorum; import java.util.List; /** * Quorum node configuration class. */ public class Node { private final ...
0
votes
1answer
9 views

Remix IDE: How can I open a file from GitHub repository ID

I want to compile and use a smart contract located in a GitHub repository on a specific branch or compile ID. I did it the same thing in the past but I've always used a URL which prompted the Git ID ...
2
votes
0answers
22 views

Ropsten issues - two forks happening, transactions showing in both places

There seems to be a few issues going on with ropsten right now: https://twitter.com/sbetamc/status/1092167042709573633 https://twitter.com/stevenleeg/status/1092546643604459521 At the same time, a ...
0
votes
0answers
16 views

Ethereum fork with Ring Signature at the core layer

Today we can have Ring Signature at the contract-level. https://github.com/HarryR/solcrypto/blob/master/contracts/UAOSRing.sol I wanted to know if there is any fork or project that would like to ...
0
votes
1answer
25 views

ERC223 Token doesn't transfer while working with data field in transfer() function

Instead of showing tokens the output shows Internal transactions or just contract interactions. what changes are needed to transfer tokens to any other ERC223 receiver contract? function transfer(...
0
votes
0answers
33 views

using events in private blockchain raises leveldb not found error

i'm getting { [Error: Node error: {"code":-32000,"message":"leveldb: not found"}] when trying to use events on a private eth blockhain. What might be the problem? (I've installed Leveldb with brew) ...
0
votes
1answer
38 views

Get value by calling a function from External Smart contract

There are 2 smart contract contract A { function abc(string _a) public returns (address) { return new B(_a); } } contract B { function xyz(string _a) { A a = A(contact address); // ...
0
votes
1answer
25 views

To handle emitted events from solidity in javascript in truffle suite

The function I am accessing will emit events i need to use that event but the function is a transaction when i am accessing the event it turns as promise pending . So suggest me some methods. thanks! ...

15 30 50 per page