All Questions

Filter by
Sorted by
Tagged with
0
votes
2answers
446 views

Smart contract machine learning use case with highly mutable model

I was thinking about different smart contract uses cases. Idea Imagine a service that classifies images. It takes an image of an animal (e.g. a cat) as input and determines the type of the animal. ...
0
votes
1answer
83 views

Define variables inside tests for contract

I write a bit more than plain contract on solidity and working on test to it. I faced with issue to put pass variables inside. If I define variable as let I receive compilation error like this: ...
0
votes
1answer
166 views

Speed up android geth sync

Hi I'm using rinkeby as test node for my mobile app. When I connect to node it need much time for sync mobile client with current head (especially on new accounts). Is there possibility not to ...
2
votes
1answer
332 views

Does the EVM always allocate new memory or can it reuse already allocated, but unused, memory?

Does the EVM always allocate new memory or can it reuse already allocated, but unused, memory? Reading the docs for delete (http://solidity.readthedocs.io/en/develop/types.html), it is mentioned ...
1
vote
2answers
150 views

Is Merkle tree applicable at block level also?

As per my understanding, Merkle tree is applied in case of transactions. Through Merkle tree we generate root hash transaction from all the transaction present in a block. So does it work the same way ...
0
votes
3answers
937 views

Is it possible to get the exact amount of Ethers deducted in a 'simple' send?

I can specify a gas price and a gas limit. These give me the maximum values. I need to be able to compute the exact amount that is going to be deducted when I do a simple send (EOA to EOA transfers). ...
4
votes
3answers
1k views

Ethereum Name Service (ENS) is case-sensitive?

Are the ENS addresses case-sensitive? Making different example.eth from ExAmple.ETH? If I'm going to bid on a name I must pay attention on that?
7
votes
3answers
817 views

Are local variables stored in memory or on the stack in Solidity?

Are local variables stored in memory or on the stack in Solidity? If memory, is the memory freed after the function returns?
5
votes
1answer
616 views

Does the EVM support garbage collection (reclaim unused memory)?

The EVM can reclaim storage by using the ‘delete’ keyword in Solidity. However, memory expands when more is allocated by the ‘new’ keyword, right? Are local variables also stored in memory? When ...
3
votes
1answer
637 views

Calling parent method with multiple inheritance

I have the following contract definition: contract MyToken is StandardToken, Ownable { ... function transfer(address _to, uint256 _value) public returns (bool){ require(...); // would ...
2
votes
2answers
6k views

Is it possible to upload a file to IPFS using HTML's <input type="file"> tag?

I'm trying to upload a file to IPFS and display the returning hash address on a browser using JavaScript and HTML. But I don't know how to handle the JavaScript API. My HTML code: <p id="text">...
2
votes
3answers
785 views

Ethereum Solidity Contracts w/ Fiat Money

Is there anyway to fix a price for a ERC20 token? It seems like a major problem with blockchain and crypto is all of the volatility, which is why I am hesitant to use it for applications even though ...
0
votes
1answer
104 views

unable to read updated value after smart contract execution

I am new to blockchain. I am trying to implement a dapp project in my college curriculum. I am trying to implement seller-buyer smart contract on private ethereum node(using solidity, geth console, ...
0
votes
1answer
340 views

truffle use without metamask

kindly let me know is that necessary to make use of metamask,my etherwallet or mist with truffle while making coin for ICO launching Thanks waiting for your valuable reply
0
votes
1answer
59 views

Can we run a separate blockchain on Ethereum. if so how? [duplicate]

I would like to know whether separate blockchain can be hosted on Ehereum and i am wiling to try this out. Hope someone will be able to guide me to right path Thanks in Advance
1
vote
1answer
6k views

How do I send Ether using geth on Windows?

I've mined Ether and it has gone into a wallet that I created using geth. When I look online, people say to use eth.sendTransaction({from: 'address', to: 'address', value: web3.toWei(1, "ether")}), ...
0
votes
4answers
2k views

How do I implement buffer/readable stream in order to add a file to IPFS?

I'm trying to upload a file from my directory to IPFS. Below is what they require from API: const files = [ { path: '/tmp/myfile.txt', content: (Buffer or Readable stream) } ] ipfs....
0
votes
1answer
392 views

Import contract wallet

I am trying to import a contract wallet after having deleted all the data from my laptop. I have the keystore file so I am able to recover my main account (in theory this should give me access to ...
0
votes
1answer
110 views

testing the hello world application on a different computer when the compute crashes/node not working

I am new to the blockchain technology. I want to test the blockchain functionality of a decentralized ledger. I have created a hello world smart contract(on solidity, geth, mist browser) on computer ...
0
votes
1answer
2k views

how to send / receive data from one smart contract to another smart contract

I have created 2 contracts in solidity and trying to deploy the contract using (geth console, mist browser). Seller and Buyer. In seller contract, I am creating seller name, productquantity, ...
0
votes
1answer
95 views

Why I cannot use multiple dynamically-sized variables in Solidity?

The following code snippet does not work. pragma solidity ^0.4.11; contract Test1 { uint[] public a; uint[] public b; function putX(uint x) public { a.push(x); b.push(...
2
votes
3answers
1k views

How to make a token private

How can I create a smart contract that has a function that receives an input ( either eth or another erc20 token ) and sends it to a specified address without revealing who sent it? Basically making ...
1
vote
0answers
197 views

How to send tokens from an existing contract to multiple people (will reward with $20 in eth) [duplicate]

EDIT: This question is not a duplicate. I am asking for someone to walk me through the entire process of distributing my token to multiple individuals. I am entirely new to coding and as such have ...
2
votes
1answer
999 views

I'll never reach final block updating with geth, it's too slow

I´m updating my ethereum blockchain with geth. But I feel it is going really slowly. Each block is done in 1 minute, sometimes 30 seconds, but at this pace I'll never reach the final block, ...
0
votes
2answers
857 views

truffle/web3 event listeners returns nothing

We have an event being triggered in a contract and our listeners on the client cant receive the return value. https://gist.github.com/stupeters187/9529b54fe0d48ee606ad06ced6b16031 Update: metamask ...
0
votes
2answers
414 views

Looking for multisig wallet source code?

Found several multisig wallet source codes but I can't deploy them in ethereum wallet because they can't be compiled. Either they use an old version of solidity or I get the error "No visibility ...
4
votes
1answer
785 views

How does Solidity handle insertion of duplicate keys in mapping?

I tried to insert two entries of identical keys into a map for testing. The map seems to reject the later entry and preserves the original entry. Is this just Solidity behaving normally? (If it is ...
0
votes
1answer
83 views

Like Ethereum can you store information on a POS blockchain

So I know you can store hashed information on the Ethereum blockchain. Lets say I forked blackcoin a POS version of bitcoin (https://github.com/CoinBlack/blackcoin). Can I also store hashed ...
0
votes
1answer
323 views

How to get geth syncing

I have get 1.7.2. on Ubuntu 16.04, which is currently stucked at block 3768477 and is not syncing (eth.syncing = false). How do I get it to sync (and not loose my accounts on which I already have some ...
4
votes
2answers
4k views

Concat two bytes arrays with Assembly

Does anyone know how to efficiently concat two bytes arrays with assembly language to save gas costs? Currently I have function mergeBytes(bytes param1, bytes param2) returns (bytes) { bytes ...
0
votes
1answer
91 views

I am trying to replicate an ecommerce system using a DApp and want to know how to decrement product quantity

For my class project I am trying to replicate ebay on a DApp. When a buyer buys something from a seller, the wallet shows ether transacted, I also want to show quantity transacted. E.g. Jan 1 2018: ...
0
votes
1answer
440 views

How to start GETH console?

I'm getting the following: ➜ voting_truffle geth console WARN [11-29|22:53:43] No etherbase set and no accounts found as default Fatal: Error starting protocol stack: datadir already used by another ...
1
vote
2answers
786 views

Is it secure to rely on 'now' or 'block.timestamp' for the deadline of an ICO?

I am planning on launching an ICO and have been reading through the security recommendations for writing solidity contracts. My ICO checks if the deadline has been reached by using if(now >= ...
0
votes
1answer
74 views

When closing node (geth ropsten) I cannot save created accounts

I am pretty new to this. I downloaded the ropsten blockchain using a geth command line. Then, using Truffle, I created an account, but when I closed my node (ctrl - c on the geth command line) and ...
1
vote
1answer
283 views

What is the best or recommended method for updating geth to include all my custom blockchain parameters?

I have a blockchain based on Ethereum, I will call it my testnet for now and I have a few nodes running and mining. All seems well so far, I am currently starting geth with several parameters If I ...
3
votes
1answer
7k views

How can I convert a 24 word seed into a 12 word seed (BIP39)?

The Ethereum wallet app Blockwallet for iOS generates seed phrases with 24 words (BIP39). Using their keytools I am able to get a private key. How do I convert the private key into a 12 word seed ...
2
votes
0answers
147 views

Why light client can't solo mine?

Can a light client solo-mine in theory ? It could download the DAG and the latest EVM state. Given these two , it can mine without downloading full blockchain, right? If this is true, why hasn't this ...
0
votes
1answer
460 views

How to use smart contract setters from JS Console?

I'm having accessing my smart contracts' setters from console using a simple HTML / JS website. I'm able to access public variables and getters, but when trying to use my setters from console it ...
3
votes
1answer
194 views

Raiden: only for ERC20 transfers?

Is Raiden network only suited for ERC20 token transfers? Does / will it support other token standards (e.g., ERC223) or simple ETH payments?
4
votes
1answer
478 views

Is there any architectural difference between Lightning and Raiden?

Lightning and Raiden are payment channel networks for Bitcoin and Ethereum respectively. Is there any difference between these projects in terms of architecture, or is Raiden simply an Ethereum ...
0
votes
2answers
626 views

How to make sense of the 'Downloading blocks' status and numbers?

I want to build mist from source. I started the mist application for the very first time following the instruction here: https://github.com/ethereum/mist#run-mist. I did not have any wallet so I did ...
0
votes
1answer
3k views

Airdropping ERC20 Tokens to multiple addresses in a single transaction

done , wrong question. better to use this contract ERC20 { function transfer(address _recipient, uint256 _value) public returns (bool success); } contract Airdrop { function drop(ERC20 token, ...
1
vote
2answers
1k views

Unable to test allowance and transferFrom function in a ERC20 contract?

I am learning ERC20 contract and stuck with allowance and transferFrom part. Approve function approves an allowance for an address (spender) to transfer tokens from owner's contract to another ...
1
vote
0answers
540 views

How many token get for one Wei?

How to calculate the number of tokens to be sent out for an incoming transaction of 1ETH. Assume my value for token is 0.80 USD? Token Price : 0.80 USD Value : 0.0016940 ETH == ...
5
votes
7answers
20k views

Web3: How do I get just the first account on testrpc using web3.eth.getAccounts()?

When I run this code in web3 web3.eth.getAccounts().then(e => console.log(e)); The console returns this: [ '0x772f437b0f15e1F205C8BD923b5C8357e9c0c429', '...
1
vote
1answer
148 views

Interacting with trade/order function which require sha3 hash

I'm currently building a dapp that use both of theses functions : function order(address tokenGet, uint amountGet, address tokenGive, uint amountGive, uint expires, uint nonce) { bytes32 hash = ...
2
votes
1answer
594 views

What happens when a function call fails within my contract method?

I am mostly interested in the following aspects: does the entire stack get unwind? if the entire stack gets unwind does this lead to all the changes made to the state by the contract get reverted? do ...
4
votes
1answer
521 views

bootnodes on Parity

Do you have to do anything special to create a bootnode on Parity? I was just using the Parity enodes in a private genesis file. I guess I have to open port 30301? Anything else?
1
vote
1answer
776 views

How to connect peers which are on different computers in geth on private network?

I am trying to setup a private network and trying to connect peers. Currently I'm trying it on my laptop and virtual machine(VM) runing on the same laptop (both of them are connected to internet). I ...
1
vote
0answers
2k views

Is it profitable to mine Ethereum on AWS?

I got $5000 on AWS from Facebook by being part of FbStart. Since I wont be using these credits for web development, I want to know if it would be profitable for me to mine Ethereum? Can I at least ...

15 30 50 per page
1
608 609
610
611 612
827