All Questions

Filter by
Sorted by
Tagged with
36
votes
2answers
53k views

how to unlock the account with geth?

when I use the web3 interface to sign on msgs, it tell me that the account should be unlocked, how can I manage this with geth and what exactly does unlocking mean?
36
votes
2answers
6k views

What are the steps to compile and deploy a library in Solidity?

I have several pieces of documentation about libraries, but I am not yet able to infer what steps are needed to compile and deploy a library and then a contract that uses it. The behavior of the ...
36
votes
6answers
28k views

How to get ether on public testnet?

I am a newbee to Ethereum and doing some research. I have installed the Ethereum Wallet app and synchronized the testnet. However, to deploy my first contract in testnet, it requires some Ether, so ...
36
votes
4answers
76k views

How to mine Ether on GNU + Linux?

How do we start mining Ether on a Debian / Ubuntu / GNU+Linux based computer? Are there PPAs or special repositories?
36
votes
5answers
7k views

Ropsten testnet is under kind of attack? What can we do?

For the last approximately 24 hours, Ropsten testnet is under an attack in my opinion. The gas limit is raised to 200m and the attacker was proposing blocks with more than 4,000 internal txs ...
35
votes
2answers
19k views

How does Lisk differ from Ethereum?

Lisk is going to be a full stack DApp development framework for building and distributing decentralized applications. It's currently in the crowdfunding stage but got also added to Microsofts ...
35
votes
1answer
16k views

What does the keyword “memory” do exactly?

I've been looking through the code of Etherdice and noticed that some variables are declared like ParserResult memory result; and I haven't found the keyword "memory" in any documentation. What I ...
35
votes
3answers
24k views

What does it mean that Ethereum is “turing complete”

People often say that Ethereum is a "turing complete" blockchain, or that it comes with a built-in "turing complete" programming language. What does this mean, and why is it an important feature for ...
35
votes
2answers
3k views

What's a precompiled contract and how are they different from native opcodes?

The Yellow Paper states: These are four so-called ‘precompiled’ contracts, meant as a preliminary piece of architecture that may later become native extensions. The four contracts in addresses ...
35
votes
1answer
3k views

How do I make my DAPP “Serenity-Proof?”

When Serenity comes around, the network will undergo many changes, some of which may have unexpected consequences on existing Smart Contracts. How can I plan so that I am best prepared to take ...
35
votes
1answer
14k views

What's the difference between Accounts and Wallets in Mist?

In Mist, there are some addresses listed as accounts, and some listed as wallets. What's the difference? Which should I use? And why do I need Ether to create a Wallet?
34
votes
5answers
11k views

How to detect if on mainnet or testnet?

Is it possible to figure out whether the network is mainnet or testnet (Ropsten) from web3.js? Or through MetaMask?
34
votes
2answers
28k views

Use string type or bytes32?

What are the benefits to using string datatypes over bytes32 to represent text data. It seems my contract runs into an out of gas exception when I switch the data structures from bytes32 to string.
34
votes
2answers
47k views

How do Ethereum's transaction fees compare to Bitcoin?

Ethereum has faster transactions than the 10 minutes of standard bitcoin protocol. How do the transaction fees compare at the moment if you translate the price into a comparable currency like dollars ...
34
votes
1answer
240k views

How to Mine Ether and use Ethereum on Windows?

Which programs should be installed and what do you need to do to start mining Ether and use Ethereum?
34
votes
5answers
13k views

Exploring and Analyzing the Ethereum blockchain

I would like to explore the data inside of the Ethereum blockchain. All transactions and contracts of the Ethereum Blockchain are stored there. So it's an interesting open dataset and I'd like to get ...
33
votes
4answers
26k views

How to get a contract's balance in Solidity?

How do I get the balance of a contract with solidity? I know geth has web3.eth.getBalance(), but that's to get the contract balance after it has been deployed. Is there a standard way of doing this, ...
33
votes
4answers
5k views

What is Olympic, Frontier, Morden, Homestead and Ropsten Ethereum blockchain?

I am studying Ethereum and have not been able to figure out the difference between Homestead and Morden. In some docs, it is written that Homestead uses a new algorithm which takes less time. I don't ...
33
votes
2answers
20k views

What is nonce in Ethereum? How does it prevent double spending?

recently I got fascinated by blockchain, and started learning Ethereum. I came across the concept of the nonce in Ethereum. After researching I found out that nonce is used for two purposes. a. To ...
33
votes
1answer
27k views

Transaction Status

A very elementary question, how do I get a transaction status after firing the transaction? I mean suppose I do a sendTransaction where I transfer some amount of ether from 1 account to other, how can ...
33
votes
5answers
17k views

How can I debug a smart contract?

When developing my smart contract, how can I debug it? Are there any debugging, testing tools or simulators that I can use to examine my code?
33
votes
3answers
29k views

How can I store data in ethereum blockchain

I want to store pdf hash in blockchain I already read this post What are some proposed ways of storing data in Ethereum? But I'm beginner in this domain and I don't understand... Is it possible to ...
33
votes
1answer
4k views

Where is the private key for a contract stored?

This is a question that I am asked often by developers who assume that a contract has a private key of its own to sign any transactions that it makes.
33
votes
3answers
37k views

How do miners profit post-PoS, if at all, how will new miners get their start, and who will execute the EVM byte code (and why)?

I've been following the release of Casper/PoS closely, and I'm curious about a few details. How will miners make money (even if GPUs are less valuable)? Are spare compute resources (say RAM, CPU) ...
33
votes
3answers
10k views

What are truffle migrations?

As written in Truffle docs: Migrations are Javascript files that help you deploy contracts to the Ethereum network. These files are responsible for staging your deployment tasks, and they're ...
32
votes
3answers
11k views

What happens when a transaction nonce is too high?

From Design Rationale: One weakness of the account paradigm is that in order to prevent replay attacks, every transaction must have a "nonce", such that the account keeps track of the nonces used ...
32
votes
6answers
41k views

How long is the first sync supposed to last?

I've been running Geth (latest version) for around 12 hours and it's still not finished. The command prompt shows this : INFO [05-21|12:05:00] Imported new chain segment blocks=1 txs=...
32
votes
1answer
23k views

What are ipc and rpc?

The question is quite simple , I have only basic Idea of RPC but none of IPC. AFAIK, if I connect to ethereum node via ipc then the my geth should be running on same machine. and If I connect via ...
32
votes
2answers
4k views

Do contracts also have a nonce?

Do contracts also have a nonce and if so how is it calculated? Usual accounts have a nonce that is increased with every transaction. However, contracts can't make transactions, they can only make ...
32
votes
3answers
8k views

Difference between Memory and Storage?

What is the difference between Memory and Storage ? From both the EVM point of view and the contract design one. Thanks!
32
votes
5answers
25k views

How can I run go-ethereum as daemon process on Ubuntu?

The Installation Instructions for Ubuntu suggest running geth from the command line, how can I run it as daemon process / service on Ubuntu?
32
votes
2answers
21k views

Solidity, create contract from contract

Based on documentation it should be possible to create new contract from contract contractAddress = new OwnedToken(name); When I invoke this method from contract, the address I receive seems to be ...
32
votes
3answers
16k views

What is the difference between an internal/external and public/private function in solidity?

Currently reading solidity documentation: https://solidity.readthedocs.io/en/develop/types.html#function-types By default, function types are internal, so the internal keyword can be omitted. In ...
32
votes
1answer
11k views

What are event topics?

I know that indexed arguments index the values for those arguments so that filtering will be faster. But what are topics? And what are they used for? I know that signature of an event is a topic. ...
32
votes
2answers
23k views

Remix warnings - state mutability and public visibility

I noticed the new Remix gave me two new warnings: browser/Untitled.sol:6:5: Warning: No visibility specified. Defaulting to "public". function setFee(uint _fee){ ^ Spanning multiple lines. ...
32
votes
4answers
4k views

How can a DApp detect a fork or chain reorganization using web3.js or additional libraries?

Take an example of a voting DApp. A user clicks on a vote button, then behind the scenes a transaction gets mined on the blockchain, and finally the DApp tells the user their vote has been recorded. ...
31
votes
4answers
21k views

When to use “View” and “Pure” in place of “Constant” [duplicate]

According to the solidity 0.4.17 Release Notes this release finally checks the modifiers view (used to be named constant) and pure on functions. As a rule of thumb, use view if your function ...
31
votes
3answers
20k views

ERC20 vs ERC223. List of differences

Is there a list of improvements that we will have in ERC223? Are there examples of contracts? Is there a migration path for existing ERC20 tokens?
31
votes
8answers
13k views

What are the development tools for Ethereum?

Could someone make a list with development tools for Ethereum together with a short description what they are good for?
31
votes
3answers
4k views

What was the reason to invent the EVM?

What was the reason to invent the Ethereum Virtual Machine (EVM)? Why not use an existing virtual machine like the Java-VM. The big advantage would be that the existing toolsets for Java development ...
31
votes
5answers
19k views

How to access the event log by knowing the contract address (web3)?

How can I access a log stored in one of the tx of the contract via web3? Code example: event newtest(string indexed name, uint indexed idlevel,string indexed multib, string objmulti, uint objnm); ...
31
votes
2answers
24k views

How can you figure out if a certain key exists in a mapping, Struct defined inside Library (in Solidity)?

pragma solidity ^0.4.8; library Library { struct data { unit val; } } - contract Array{ using Library for Library.data; mapping(address => Library.data) clusterContract; ...
31
votes
4answers
7k views

Error while compiling: Stack too deep

When trying to compile, I am getting the following error: "Internal compiler error: Stack too deep, try removing local variables." Is there any way around this? I'm not sure if I'll be able to ...
30
votes
13answers
25k views

How to upgrade solidity compiler in truffle

I couldn't find a way to upgrade a version of truffle solidity compiler. Also curious how to see that information for deployed contracts in truffle console
30
votes
6answers
16k views

ecrecover from Geth and web3.eth.sign

I have tried to use ecrecover() to verify the signature of a message. I have looked at lots of references here and elsewhere, like: https://lab-blog.ey.com/2016/12/19/ecrecover/ How does one ...
30
votes
5answers
7k views

Who is msg.sender when calling a contract from a contract

When I call a function in my contract which calls another function in another contract. In the second called contract function who is msg.sender? the contract calling the second contract or my account?...
30
votes
3answers
13k views

How to write an optimized (gas-cost) smart contract?

As we all know, there are many factors that determine a good smart contract, such as: Security: it has minimal/zero vulnerability so they cannot be exploited by an adversary. Immune to Attacks. Cost:...
30
votes
4answers
26k views

How to convert a bytes32 to string

How can I convert a bytes32 to a string? Does anyone has a magic function or library which does it?
30
votes
3answers
6k views

What is the difference between transaction cost and execution cost in remix?

What is the difference between transaction cost and execution cost as seen after contract instantiation in remix? I don't think it matters, but here is my contract: contract DepositCounter { ...
30
votes
2answers
9k views

Why do Solidity examples use bytes32 type instead of string?

In many Solidity examples I read that use strings for parameters or return values, I see they are typed as bytes32 although there's a string type. What is the real reason for that? Thanks.

15 30 50 per page