All Questions

Filter by
Sorted by
Tagged with
0
votes
1answer
460 views

Transaction signing fails Invalid RLP.“,”data“:”RlpExpectedToBeList"

I'm trying to sign and push a transaction using ethereumjs and Infura. It seems to be working and I'm getting a transaction hash back, but the transaction is not visible on Etherscan, and when I'm ...
0
votes
1answer
188 views

Metamask stuck at Unknown network ID

I'm getting unknown network ID error on transferring a token in meta mask as in the image below. I'm using local network with ganache. I can transfer from metamask account to another after ...
1
vote
1answer
27 views

How to share TypeScript code between truffle tests?

I have some code in my TypeScript tests, say: function foo() { return 'bar'; } which I'd like to share with all my tests. The simple solution is to copy the function into each *_test.ts file. ...
8
votes
3answers
324 views

Is there the opposite function for evm_increaseTime?

I'm using the following function in my JS tests (with truffle) to move forward in time to test time dependent functions: const timeTravel = function (time) { return new Promise((resolve, reject) =&...
0
votes
0answers
19 views

Script for opening a geth console for a node and running commands in it

I am trying to create a script running a couple of geth nodes, open a console for each of them and run a couple of commands such as admin.addPeer() and miner.start(). I read that i can use --exec to ...
0
votes
0answers
19 views

Blockchain job statisics [closed]

My advisor asked me to prepare a presentation for undergraduate students about bitcoin and blockchains. I want to impress the students by this technology. I am looking for statistics/charts/reports/ ...
0
votes
1answer
43 views

ERC20Mintable contract call return wrong number

I use OpenZeppilin ERC20Mintable contract and add MaxSupply parameter to contraint the ERC20 token amount allowed to issue. what I want is only permit contract ower to view MaxSupply info, my ...
0
votes
1answer
338 views

Deploying new contract inside truffle test case

I was trying to transact between two contracts inside my truffle test case. But not been able to do it. The second contract instance comes back undefined always. As per the truffle documentation, ...
1
vote
2answers
624 views

C# how to compute Keccak256 to match Solidity?

I have a simple Solidity function as below: function testKeccak(uint8[] buffer) public pure returns (bytes32) { return keccak256(abi.encodePacked(buffer)); } Testing the keccak256 hash using ...
0
votes
1answer
201 views

My transaction of 0.003 ETH from MEW shows “FAIL”

My transaction of 0.003 ETH from MEW shows "FAIL" in etherscan when checked with Tx. The required Gas was set as 170000. No reason is shown on the etherscan page. What must've gone wrong? Does the ...
0
votes
1answer
24 views

Listen to transactions on EOA addresses

Haven't seen any documentation that shows that this is possible. Could someone direct me to something that would allow me to listen to transactions on non-contract addresses.
0
votes
3answers
78 views

Remove coinbase transactions in private net

I was willing to setup a private ethereum network with low difficulty. I can fix the difficulty of each block to 1 (or constant) to avoid problem of very high difficulty with increase in no of blocks. ...
1
vote
1answer
269 views

Dealing with events in ethers.js

I'm trying to get a better understanding of arbitrary bytes parameters, so I wrote a one-function smart contract that accepts a bytes argument, decodes it, and returns the response. I am having ...
0
votes
2answers
68 views

ParserError: Expected pragma, import directive or contract /interface/library definition

In an attempt to compile my ABI and verify my contract, I am getting the following warning: "ParserError: Expected pragma, import directive or contract /interface/library definition" on the first line ...
2
votes
2answers
153 views

Ethereum hangs after 3 days uploading the blockchain, do I even need the blockchain to have a wallet?

I have downloaded and run Ethereum Wallet 0.9.0 Mist. It started updating about 3 days ago. It runs, but then when it is very near the end, e.g. 300-ish blocks to go, it seems to slow down and stop. I ...
0
votes
1answer
22 views

Can i use a the msg.sender which is a address to call a function of the contract?

I am trying to mint a ERC721 token using openzeppilin/contracts. It was working correctly, but later had to change the design. So now i am forced to use the msg.sender who is the minter to call the ...
1
vote
1answer
60 views

Why does not Ethereum allow removing all entries from a mapping, like clear() in Python

Is it common that dictionaries like mapping(uint => uint) foo; cannot be cleared with something like clear()? What is the reason deleting mappings aren't allowed in Ethereum?
2
votes
2answers
639 views

Decoding ethereum leveldb keys and values

I've created a simple script to read ethereum data from the leveldb using C++. Basically this testing program would print all keys in leveldb to the console. #include <cassert> #include <...
0
votes
1answer
277 views

how to import UTC-JSON file through web3-eth methods

hey I am working on ethereum wallet. in this i want to import my account through UTC json file, but i didn't find any solution for this in web3-eth command someone can please help to find out the ...
2
votes
1answer
148 views

How can I check if a contract contains a specific function signature in the ABI?

I'm using Geth and thinking maybe I'll have to deep dive into the Go code to make this happen, but it should be possible. What would I need to do to check if a function signature exists in a contract?
0
votes
1answer
24 views

Is it possible to instantiate a deployed contract in js using contract address alone? without copying abi data?

Is it possible to instantiate a deployed contract in js(dapp) using contract address alone? without copying abi data?
0
votes
2answers
18 views

ERC20 Mixer to transfer fund privatly

I am working on idea to mix erc20 token from one account to many account. i have seen many example but all example has some limitation. like you can mix fixed amount. Sender can mix one ...
0
votes
1answer
196 views

Building smart contract

I am trying to build a simple smart contract following the rules on the website below. https://medium.com/crypto-currently/build-your-first-smart-contract-fc36a8ff50ca For some reason after ...
0
votes
1answer
19 views

How to convert to 8 digits in etherum

I have a token that has 8 digits, so the output is 4762575931 instead of 47.62575.. How can i change this so this works on UI and for metamask input? I know there is the function to wei but this is ...
0
votes
1answer
135 views

Geth sync too slow on MacMini to catch up with latest blocks

My workaround used to be do a geth -removedb and start a fresh fast sync from scratch. Trying to sync with existing blockchain data instead was a lost race of catching up to the latest block. Today ...
0
votes
1answer
384 views

How to get only past 2 days events using getPastEvents everytime?

How can the following query be modified to only fetch the past two days worth of events: const events= await MyContract.getPastEvents("eventName", { fromBlock: 0, toBlock: "latest" });
1
vote
1answer
17 views

Mocha assertions not returning correctly on assert.equal with BN

Is this an issue with deep matching/object identity? AssertionError: expected <BN: 204fce5e3e25026110000000> to equal <BN: 204fce5e3e25026110000000> It seems strange that chai.should ...
1
vote
2answers
204 views

Transaction Hash after deploying contract with Web3.py too long

I managed to successfully deploy a contract using Web3.py to the Ethereum Ropsten network using this bit of code def deploy(self): instance = self.w3.eth.contract(abi=self.abi, bytecode=self.bin) ...
0
votes
0answers
16 views

Any opensource (github) ETH based scriptural transaction + data scripts available [closed]

I am looking for a 'github' or open-sourced script/framework so that I can scripturally automate an eth transaction from 'a' to 'b' that will include 'data' within the transaction. Like a smart-...
0
votes
1answer
245 views

Local account to local node

If I create my wallet / accounts client-side with web3.eth.accounts how can I "publish" them on my local node? For example, I want to send some ether with an eth faucet to the first created account. ...
0
votes
1answer
190 views

Web wallet best practices

I'm putting together an ether/erc20 token wallet in a chrome extension but would like to follow best practices with regards to private key security. I'm using localstorage to handle login and its ...
1
vote
2answers
38 views

What are contract Variables and how are they different from normal varables declaration

pragma solidity ^0.4.2; import DappToken; contract DappTokenSale { address admin; DappToken public tokenContract; function DappTokeSale(DappToken _tokenContract) public { ...
1
vote
2answers
25 views

Can i disable direct transactions to smart contract address?

I want to use rewardsAmount variable to calculate my rewards: uint rewardsAmount = 0; // Only here i can withdraw rewards function withdrawRewards() onlyOwner external { require(rewardsAmount !=...
0
votes
1answer
595 views

How to make API calls from a .NET Application to an Ethereum Private Network

I'm starting on blockchain development and I have a question: I was wondering if it is possible to make RPC calls to a private ethereum network (handling user private keys is not a problem in our ...
1
vote
3answers
161 views

See in geth if a smart contract (ICO) was never executed

If I send ether to a smart contract, how can I see in geth, that it was rejected? I want to see which of my transfers were accepted by an ICO and which were not. I don't see any such field in ...
0
votes
1answer
283 views

Ganache and truffle - how to set zero deployment fees

I am running a local ganache-cli node on my machine and would like to have zero transaction fees. For this reason I am starting the node using ganache-cli -g 0 which sets the gas price to zero. ...
0
votes
1answer
205 views

Changing end date to smart contract?

Newbie question. Can someone walk me through the steps I have to take to extend the date to my smart contract from May 2, 2018 to August 2, 2018? Like to try without asking my programmers for help....
0
votes
1answer
425 views

Using ERC20 token contract with my own token code

I am using the ERC20 token contract from OpenZeppelin and want to add my own code with the total supply, decimals, token name, token symbol and owner of total balance. I have tried adding my code ...
1
vote
2answers
347 views

Smart Contract - Update implementation using a Relay with delegateCall

I know that smart contracts are supposed to be immutable and that's the whole point, but to expect someone to implement a logic that never changes (no upgrade or no bugs) from day 1 is also ...
0
votes
0answers
8 views

How to revert chain to previous block in Parity 2.4.x?

Parity 2.4.x has the ability to revert to a particular block. Has anyone used this feature? Can you share an example? https://github.com/paritytech/parity-ethereum/pull/9782
1
vote
3answers
228 views

How do i add to a nested array within a struct

I am unable to add elements to a array within the struct struct D { string name; address key; } struct Aone { string aid; B[] blist; D[] dlist; } ...
0
votes
1answer
296 views

java.lang.RuntimeException: Error processing transaction request: insufficient funds for gas * price + value when invoking smart contract function

using web3j for loading a contract which is deployed on the private network following this tutorial https://web3j.readthedocs.io/en/latest/smart_contracts.html#constant-methods smart contract ...
0
votes
1answer
197 views

Geth syncing - Jan 18, how much time should wait before I call it quits. (First time miner)

After 3 days; current status: > eth.syncing { currentBlock: 4829460, highestBlock: 4829665, knownStates: 19675738, pulledStates: 19646971, startingBlock: 4828906 } Getting ti
0
votes
2answers
5k views

Transaction has been pending for long time

I send funds using MetaMask. But,maybe I didn't put enough gas. So it's stuck with other payments that I made after first payment. Transaction is.. ...
5
votes
2answers
432 views

Geth: bootnode tool and --nodiscover

In Geth, if I use the --nodiscover option, my node won't be discovered by default from other nodes. Conversely, with bootnode tool implemented in geth, first I have to generate a key, then I have to ...
0
votes
1answer
28 views

How can I turn this into a human readable output? [closed]

I have this buy function but the output gives me a transaction Nr. or whatever this is async function buy() { var a = document.getElementById("amount").value; var accounts= await web3.eth....
0
votes
1answer
295 views

Can I find constructor arguments from truffle artifact?

I'm in the process of verifying my contract on Etherscan. Etherscan asks for ABI-encoded constructor arguments during the verification process, though I was a bit silly and don't quite know what they ...
0
votes
1answer
187 views

Custom token transfer, what am I doing wrong?

I am trying to hash an address then send tokens to a mapping of the hash in the token contract, then be able to withdraw those tokens using a hash of the address. It compiles but cannot make it work. ...
0
votes
1answer
454 views

How to see event name in etherscan.io transaction event log?

In etherscan.io, I want to be able to see the event name (signature) in the transaction page event log, like here. Currently, I don't see it here. I'll note that the transaction is indeed sent to a ...
0
votes
0answers
5 views

Web3.py Could not transact with/call contract function, is contract deployed correctly and chain synced?

I am trying to call a contract function deployed in Ganache. I am pretty sure the contract is deployed because I can transact() and work with other functions. But when I call() it, I get this error: ...

15 30 50 per page