All Questions

Filter by
Sorted by
Tagged with
1
vote
1answer
11 views

What is words in uint256?

Let's take two variable: uint256 public smalldata = 50000; uint256 public data = 500 * (10**6) * 10**18; The first on prints: BN { negative: 0, words: [ 50000, <1 empty item> ], ...
0
votes
0answers
6 views

Miner not updated to Muir Glacier. Coins now in Ice-Age-Chain(?)

What happens if a miner processes my transaction that has not updated to Muir Glacier? Is it possible that I loose coins because the miner is still on the old chain so that the coins are now on the ...
0
votes
0answers
12 views

Cannot set a proxy implementation to a non-contract address

I have deployed contracts; FiatTokenV1 https://ropsten.etherscan.io/address/0x612a2a33e4d34eb00d59f82a37918d88d8e332ec deployed proxy with implementation address=...
1
vote
2answers
16 views

My ether was automatically sent to different address without my permission

My ethereum account is 0xfAd956B56be1298ee8ec1950cc305B46268d926f (generated by metamask) and the moment friend of mine sent me an ether, it was automatically directed to another account. This is the ...
1
vote
0answers
12 views

How to reduce block time for existing ethreum blockchain network?

I had deployed my private blockchain network back in 2018-08-12 16:12:48 +0600 (1 year, 167 days ago). Since then it is working. At that time the block time was 20-30 seconds which was acceptable for ...
0
votes
0answers
15 views

Problem with running truffle code with node.js

I am trying to run truffle code with Node.JS in the backend to deploy contracts. I want to be able to do this interactively and I am intending to use the Express Library to interact with the Node ...
1
vote
1answer
58 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?
0
votes
0answers
17 views

Blockchain job statisics

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
14 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
0answers
15 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
0answers
17 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
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
1answer
14 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 ...
0
votes
1answer
27 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
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: ...
1
vote
1answer
26 views

How can I get a private key from a mnemonic phrase?

I want to convert a 24 words length seed phrase into a private key using web3.
0
votes
0answers
18 views

Oraclize ( provable) updates the value only one time

I'm trying to write a smart contract that gives me the current timestamp. The very important part is that i want this to happen locally, not on test networks. After some research, i installed ethereum-...
0
votes
2answers
28 views

Why in solidity 0.6 these functions are no more free? [duplicate]

Try this code pragma solidity >=0.5.0 <0.6.0; contract test05 { address payable public admin = msg.sender; function() payable external {} function getBalance() public view ...
1
vote
1answer
20 views

Understanding Transaction in Bitcoin [closed]

I read a lecture about Bitcoin Blockchain. As shown in the slide below, a user Alice sends a transaction to BoB. Alice should 1-) Hash(Hash of the transaction of the coin || Bob Public Key || Alice ...
0
votes
1answer
18 views

Solidity error message on compilation (DeclarationError: Identifier not found or not unique. using Address for address;)

I'm trying to compile a code for a crowdsale contract (Timed and with allowance) from openzeppelin library that is based on a deployed token. However during compilation on remix i get a syntax error ...
0
votes
1answer
25 views

Ho can a server act for third party?

I will try to explain my idea. Our server receive data to save from different servers, we call it S1, S2 and S3. Our server uses a node script with web3.js to call function over a contract. Actually ...
0
votes
1answer
18 views

Why do we use `serialize` function of `ethereumjs-tx` package before broadcasting a transaction

I just want to know the purpose/functionality of serialize function which we use before broadcasting a transaction: const serializedTransaction = tx.serialize() const raw = '0x' + ...
0
votes
1answer
15 views

Are there any API to get real money value equivalent of a transaction?

I know that etherscan shows the total cost of a transaction both in eth and in US dollars. Is there any api of any kind to be able to get instant value of eth when I send a transaction?
0
votes
0answers
12 views

Private Blockchain Chain Spec Sanity Check Please

A private blockchain running for two years runs find on Parity 2.3.9. When upgrading a node to 2.4, sync stops. Peers are still strong (25) but block import repeats at Block X where Block X is the ...
0
votes
2answers
16 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
22 views

eth.getBalance(eth.accounts[0]) Shows me 0 balance though my syncing is still Running [duplicate]

I am using geth on windows with 1.9.10 version. I used geth --rinkeby --rpc --rpcapi="personal,eth,network,web3,net" command for launch my geth. I am on the Rinkeby testnet, i already transfer 3 ...
0
votes
1answer
8 views

how to send parameters to smart contract while deploying using metamask

I am trying to deploy a smart contract using BrowserSolc and Metamask. and deployed successfully when the contract doesn't have constructor parameters but now I am trying to deploy with the ...
0
votes
0answers
10 views

Contract is not deploying properly on Geth private network using web3j SDK

I am new to Ethereum. I have created private blockchain using Geth on my local and trying to deploy my smart contract using java web3j SDK. I am able to deploy my contract using java and getting ...
0
votes
1answer
17 views

Getting revert error on transfer ether to wallet address

hi i m calculate the ether value with token price and quantity of tokens and than sending calculated ether value to seller account but i am getting revert error on remix at escrow.originatorAddress....
0
votes
1answer
17 views

Can I use other tokens in loom network (sidechains)? How does loom network handles it?

How to receive other tokens in the smart contract deployed in loom and keep it in escrow?, this is the code. pragma solidity ^0.5.0; //import ERC20 functionality ... contract Example { ...
0
votes
2answers
21 views

Solidity 0.6.1 Receive Fallback Forwarder reverts due to insufficient gas

I am playing around with Solidity 0.6.1 and trying to build a simple funds forwarder. So ETH is sent to the contract and it sends the funds to another address. I deployed it to Ropsten. But every ...
0
votes
0answers
12 views

How to trace transactions to get information about hot and cold wallets?

I am researching ways how to trace transactions to get data about hot and cold wallets of exchanges, gambling sites, cantors, mixers. What sources of data could I use? What algorithms and scripts ...
1
vote
1answer
15 views

Was throw part of DAO (attacked) code?

I have attached a picture related to DAO attack. I got the image from the following link A Survey on Ethereum Systems Security: Vulnerabilities, Attacks and Defenses . The image shows a code ...
1
vote
0answers
25 views

Exiting out of a smart contract early?

Basically i want to have a smart contract that can allow users to exit early under specific conditions. Does anyone have any resources for this or know whether its possible?
0
votes
1answer
26 views

msg.sender not increasing the balance

I am trying to execute the following code obtained from`Solidity Tutorial pragma solidity 0.5.4; contract ERC20Token { string name; mapping(address => uint256) public balances; ...
1
vote
1answer
21 views

How to calculate total cost of a transaction

I've a transaction that consumed 276798 of gas, paid 900000000 (wei I think) Is the total cost gasUsed x gasPrice, right? Total = 249,118,200,000,000‬ (wei I think) So how many ether is ? 0....
0
votes
1answer
33 views

Using the correct/best solc version with Truffle and general tooling setup

I haven't worked with Truffle/Solidity for a while and I am trying to get my environment/toolchain configure correctly. I have some questions regarding the compiler config. I was originally not ...
0
votes
0answers
21 views

Geth on AWS EC2, rpc call networking

I'm trying to boot up a Geth node on an AWS EC2 instance and for some reason I'm unable to connect to it via a simple RPC call from outside the instance. I've done this successfully with a Parity ...
0
votes
0answers
23 views

Unable to change/read local variable in a smart contract on a local private geth blockchain

I trying to create and test an ERC-20 Token on a local geth blockchain. I tried compiling and testing my contract on Remix's Javascript VM environment and it works fine. Then, I wanted to try ...
0
votes
0answers
25 views

gas estimation fails when trying to run a recursive function? Is there an alternative?

I have been trying to traverse a graph kind of data structure and the only way to do this is by using a recursive function is what I feel. So, now when I try to execute my contract code in remix it ...
0
votes
0answers
24 views

Unhandled Rejection (Error): invalid address web3.js

I got above error. But I can't solve this problem. I use web3.js 0.20.5 version; Here's my web3.js code: var web3js; export function setupWeb3(){ if (typeof web3 !== "undefined") { ...
1
vote
1answer
13 views

bootstrap node vs cmd/bootnode

I am using bootnode as a starting/meeting point for my private POA/clique network. When I start it since one of the latest versions it says: fmt.Println("Note: you're using cmd/bootnode, a developer ...
0
votes
1answer
19 views

API call to get a list of all transactions sent TO a specific address (not contract)?

I have used the Etherscan API call "http://api.etherscan.io/api?module=account&action=txlist&address=0xddbd2b932c763ba5b1b7ae3b362eac3e8d40121a&startblock=0&endblock=99999999&sort=...
1
vote
1answer
24 views

Logic help needed, how to transfer funds to the address who placed bets on winning team?

This is a betting application and right now -> if I place bets on HOME, the amount gets stored but I want to transfer the amount only to the address who placed bets on winning team. I have developed ...
0
votes
0answers
21 views

I can't see smart contract's value in my web browser

I have compiled myself smart contract in Truffle. But when i use its js app (that there is in src file from pet-shop box downloaded) to interaction with my smart contract, i can't understand how i can ...
0
votes
1answer
19 views

Multiple callbacks with provable random oracle

I'm making a simple lottery game where there are hourly, daily and weekly prizes. My contract has functions to pick winners for each of these game types. Each game types will have different number of ...
0
votes
1answer
26 views

How i can exchange the erc20 with ether

i want to make crypto to crypto smart contract where i need to sell erc20 token and on buyer side i need to calculate the price which i have to send to seller and i have a price of token can you ...
0
votes
1answer
19 views

What is nodekey of bootnode command?

My understanding is that bootnode --genkey commands generate private key of node, and bootnode --writeaddress commands generate public key of node. However, why node needs private key and public key?...
0
votes
0answers
19 views

How to assign event output to variable when testing?

I'm using Truffle test(chai/mocha) and openzeppelin-test-helpers. Can anyone help me about how to assign values from event to variables in the above testing environment?
0
votes
0answers
20 views

Is there a graph data structure in solidity?

I am trying to achieve a file lineage information Dapp and I need a graph kind of data structure for that. I know I can always write one but is there a ready to use data structure that is efficient ...

15 30 50 per page