Commit Graph

702 Commits

Author SHA1 Message Date
Jeffrey Wilcke
262d92834a Merge pull request #2575 from bas-vk/filter
eth/filter: bugfix which can cause a nil pointer crash when parsing f…
2016-05-23 12:54:35 +02:00
Jeffrey Wilcke
847aaffbb8 Merge pull request #2589 from karalabe/estimate-remove-codecheck
accounts/abi/bind, eth: rely on getCode for sanity checks, not estimate and call
2016-05-20 15:13:29 +02:00
Jeffrey Wilcke
a8472e0fdb Merge pull request #2315 from karalabe/concurrent-headers-2
eth/downloader: concurrent header downloads
2016-05-20 14:25:28 +02:00
Péter Szilágyi
1580ec1804 accounts/abi/bind, eth: rely on getCode for sanity checks, not estimate and call 2016-05-20 12:29:28 +03:00
Péter Szilágyi
8906b2fe09 eth/downloader: fix reviewer comments 2016-05-20 10:56:01 +03:00
Jeffrey Wilcke
4b1a7d3868 eth: fixed regression in eth_signTransaction fixes #2578
Sign transaction returned the unsigned transaction rather than the
signed one.
2016-05-18 17:25:34 +02:00
Bas van Kervel
67cd4ee8d2 eth/filter: bugfix which can cause a nil pointer crash when parsing filter arguments 2016-05-17 16:17:54 +02:00
Péter Szilágyi
d87f7a1e81 eth: skip transaction handling during fast sync 2016-05-17 14:17:20 +03:00
Péter Szilágyi
e86619e75d eth/downloader: stream partial skeleton filling to processor 2016-05-17 10:03:34 +03:00
Péter Szilágyi
b40dc8a1da eth/downloader: implement concurrent header downloads 2016-05-17 10:03:34 +03:00
Péter Szilágyi
39ce85cf5d eth/downloader: bound fork ancestry and allow heavy short forks 2016-05-13 12:12:13 +02:00
Péter Szilágyi
756b62988c Merge pull request #2523 from fjl/shutdown
core, eth, miner: improve shutdown synchronisation
2016-05-09 15:59:41 +03:00
Felix Lange
56ed6152a1 core, eth, miner: improve shutdown synchronisation
Shutting down geth prints hundreds of annoying error messages in some
cases. The errors appear because the Stop method of eth.ProtocolManager,
miner.Miner and core.TxPool is asynchronous. Left over peer sessions
generate events which are processed after Stop even though the database
has already been closed.

The fix is to make Stop synchronous using sync.WaitGroup.

For eth.ProtocolManager, in order to make use of WaitGroup safe, we need
a way to stop new peer sessions from being added while waiting on the
WaitGroup. The eth protocol Run function now selects on a signaling
channel and adds to the WaitGroup only if ProtocolManager is not
shutting down.

For miner.worker and core.TxPool the number of goroutines is static,
WaitGroup can be used in the usual way without additional
synchronisation.
2016-05-09 13:03:08 +02:00
Jeffrey Wilcke
7d59c5c58d eth: fixed tracing functions using the current header instead of parent
Fixes #2525
2016-05-09 10:24:31 +02:00
Péter Szilágyi
586eddfd09 release, all: integrate the release service into geth 2016-05-02 16:20:21 +03:00
Felix Lange
1c20313a6a Merge pull request #2493 from almindor/develop
eth: add personal_importRawKey
2016-04-29 23:09:37 +02:00
Ales Katona
572da73d4d eth: add personal_importRawKey for runtime private key import 2016-04-28 09:11:40 -06:00
Bas van Kervel
48cc36ce83 eth/filters: ignore logs that don't match filter criteria on chain reorg 2016-04-28 12:33:42 +02:00
Péter Szilágyi
cdcbb2f160 accounts/abi/bind, eth: add contract non-existent error 2016-04-27 17:15:23 +03:00
Felix Lange
a40e61b4ac rpc: remove NotifierContextKey
Context keys must have a unique type in order to prevent
any unintented clashes. The code used int(1) as key.

Fix it by implementing the pattern recommended by package context.
2016-04-15 18:10:52 +02:00
Felix Lange
6fdd0893c3 all: fix go vet warnings 2016-04-15 11:17:27 +02:00
Felix Lange
24cdac41f3 core, core/types, eth: add and use Block.Body
This fixes a few uses of unkeyed Body literals which go vet was
complaining about.
2016-04-15 10:57:37 +02:00
Felix Lange
d04a2e7557 all: update license information 2016-04-15 09:48:05 +02:00
Péter Szilágyi
53016c1225 eth, rpc: make trace configs optional 2016-04-14 15:10:29 +03:00
Péter Szilágyi
bbc77f488e eth: fix single transaction tracing (run prev mutations) 2016-04-14 14:29:47 +03:00
Felix Lange
bcd8aeefdd eth: add chaindbProperty to debug API 2016-04-13 12:08:07 +02:00
Péter Szilágyi
1e9b504ee7 Merge pull request #2284 from fjl/accounts-addr-cache
accounts: cache key addresses
2016-04-12 17:51:09 +03:00
Felix Lange
46df50be18 accounts: improve API and add documentation
- Sign takes common.Address, not Account
- Import/Export methods work with encrypted JSON keys
2016-04-12 15:59:18 +02:00
Felix Lange
549f1add29 eth: report unlock errors to RPC clients 2016-04-12 15:59:12 +02:00
Felix Lange
46e8940b19 accounts: streamline API
- Manager.Accounts no longer returns an error.
- Manager methods take Account instead of common.Address.
- All uses of Account with unkeyed fields are converted.
2016-04-12 15:58:01 +02:00
Felix Lange
85e6c40c00 accounts, crypto: move keystore to package accounts
The account management API was originally implemented as a thin layer
around crypto.KeyStore, on the grounds that several kinds of key stores
would be implemented later on. It turns out that this won't happen so
KeyStore is a superflous abstraction.

In this commit crypto.KeyStore and everything related to it moves to
package accounts and is unexported.
2016-04-12 15:56:49 +02:00
Péter Szilágyi
aceaaa5178 eth: gracefully fail if chain config is missing 2016-04-12 16:48:43 +03:00
Jeffrey Wilcke
8627680e24 Merge pull request #2359 from bas-vk/rpc-optional-args
rpc: several fixes and support for optional arguments
2016-04-12 14:03:21 +02:00
Bas van Kervel
aa9fff3e68 rpc: various fixes/enhancements
rpc: be less restrictive on the request id
rpc: improved documentation
console: upgrade web3.js to version 0.16.0
rpc: cache http connections
rpc: rename wsDomains parameter to wsOrigins
2016-04-12 11:02:39 +02:00
Péter Szilágyi
bf1f620343 eth: fix GPU miner chain config regression 2016-04-11 17:31:00 +03:00
Jeffrey Wilcke
ed92f116f7 Merge pull request #2407 from bas-vk/rpc-notifications
RPC pub sub
2016-04-05 09:43:32 +02:00
Felix Lange
cf842b3fe5 cmd/geth, eth: move --genesis deprecation warning to cmd/geth
This prevents display of the warning for --dev and --olympic.
2016-04-01 21:59:35 +02:00
Bas van Kervel
f7328c5ecb rpc: add pub/sub support 2016-04-01 18:26:35 +02:00
Jeffrey Wilcke
be44651523 Merge pull request #2402 from obscuren/eth-sign-fix
eth: enforce signing hashes using eth_sign instead of arbitrary data
2016-04-01 13:42:48 +02:00
Jeffrey Wilcke
1f3596c25a core: transition db now also returns the required gas amount
Exposes some core methods to transition and compute new state
information and adds an additional return value to the transition db
method to fetch required gas for that particular message (excluding gas
refunds from any SSTORE[X] = 0 and SUICIDE.

Fixes #2395
2016-04-01 01:01:10 +02:00
Jeffrey Wilcke
9055c16efa accounts/a/b/backends, core: chain maker homestead block set to 0
The chain maker and the simulated backend now run with a homestead phase
beginning at block 0 (i.e. there's no frontier).

This commit also fixes up #2388
2016-04-01 01:01:10 +02:00
Jeffrey Wilcke
f0cbebb19f core: added basic chain configuration
Added chain configuration options and write out during genesis database
insertion. If no "config" was found, nothing is written to the database.

Configurations are written on a per genesis base. This means
that any chain (which is identified by it's genesis hash) can have their
own chain settings.
2016-04-01 01:01:10 +02:00
Jeffrey Wilcke
916fe11241 eth: enforce signing hashes using eth_sign instead of arbitrary data 2016-04-01 00:43:14 +02:00
Péter Szilágyi
4326061e35 eth: fix accidental nil panic on nil errors 2016-03-31 18:26:25 +03:00
Péter Szilágyi
6c670eff01 eth: manually convert errors to strings on the trace API (json cannot) 2016-03-31 17:41:26 +03:00
Péter Szilágyi
72826bb5ad accounts/abi/bind, cmd/abigen: Go API generator around an EVM ABI 2016-03-24 14:15:18 +02:00
Jeffrey Wilcke
75c86f8646 Merge pull request #2141 from obscuren/evm-init
core, core/vm, tests: changed the initialisation behaviour of the EVM
2016-03-23 23:20:51 +01:00
Jeffrey Wilcke
0cfa21fc7f core, eth, cmd: temporary work around for enabling the jit
This commit serves as a temporary workaround for enabling the jit until
the block customisation PR is merged in.
2016-03-23 23:02:44 +01:00
Jeffrey Wilcke
5f92606be2 eth/api: added root to the receipts 2016-03-23 23:02:44 +01:00
Jeffrey Wilcke
3601320ccd eth, rpc: implemented block debugging rpc calls
Implemented the following block debugging RPC calls

* Block(RLP)
* BlockByFile(fileName)
* BlockByNumber(number)
* BlockByHash(hash)
2016-03-23 23:02:44 +01:00