Commit Graph

227 Commits

Author SHA1 Message Date
Nikolay Volf b7006034b1 Decouple virtual machines (#6184)
* work in progress for splitting vms

* evm working

* Evm -> Vm

* wasm converted

* ethcore working

* test fixes
2017-08-01 13:37:57 +03:00
Anton Gavrilov 141c2fd34a Fixed comments after review and test after rebase 2017-07-31 18:10:06 +02:00
debris 81b57ceddb Merge branch 'master' into split 2017-07-31 16:19:59 +02:00
Anton Gavrilov 8826fdb03a Merge with head 2017-07-31 13:49:44 +02:00
Anton Gavrilov 5086dc3024 Working test with block reward added 2017-07-31 13:42:34 +02:00
Robert Habermeier 003eef982b Move more params to the common section. (#6134)
* move common forks and parameters to common params

* port specs over to new format

* fix RPC tests
2017-07-31 12:34:29 +02:00
debris c4989ddc44 removed util::common 2017-07-29 22:49:10 +02:00
debris eecd823d32 util reexports less std 2017-07-29 21:10:14 +02:00
Anton Gavrilov 73128039a6 Working test with block reward added 2017-07-27 18:21:36 +02:00
arkpar 9ad0ff960e Place RETURNDATA behind block number gate 2017-07-19 14:34:59 +02:00
Robert Habermeier d365281cce Ethcore crate split part 1 (#6041)
* split out types into separate crate

* split out evm into its own crate
2017-07-12 13:09:17 +02:00
Joseph Mark 0fca4f95d6 Errors & warnings for inappropriate RPCs (#6029)
* Clarify function name

Function checks if sealing is currently underway, not to be confused
with checking whether the engine performs internal sealing.

* Error when work called on internal sealing engine

* Error submitting work for internal sealing engine

* Fix inverted bool and style grumbles

* Add can_produce_work_package to TestMinerService

* Error when setting engine signer on PoW chain

* Unit tests for engine signing

Setting engine signer should fail if chain does not seal internally
or client lacks account provider.

* Tweak TestMinerService

* Fix minor style grumbles
2017-07-12 08:52:18 +02:00
Axel Chalon d970237658 Add test for loading the chain specs (#6028)
* Add test for loading the json chain specs

* Remove test on Ethereum specs as it already exists
2017-07-10 19:26:10 +02:00
Nikolay Volf 62210fb932 WASM contracts MVP (#5679)
* lifetime issues

* refactor to new 'native env'

* descriptors and such

* wasm mvp continued

* finalized env/ext bindings

* descriptor -> call_args

* inject gas counter

* result processing and engine activation

* tabify some source files

* needs return new

* wasm tests initial

* erradicate warnings

* origin in the descriptor

* update test repo

* payload verification tests

* identity return payload test

* some test description

* dispersion test

* check length here

* suicidal contract

* engine params

* fix typo

* review fixes

* submodule update

* update - purge reserved space

* doc effort

* more review fixes

* fix error message

* fix dependency url

* reorg error handling

* update submodule

* update utils

* update to latest parity-wasm

* tabify

* fix wasm magic header

* update dependencies

* external create and tests

* update to latest tests

* extra trace info

* Update parity-wasm

* update wasm-utils also

* few traces and result handle change

* alter trace content

* fix issues with optimizer, update to latest parity with validator, etc

* static initialization

* license preamble

* update wasm crates and gas costs

* fix grumbles

* bring back lifetime

* fix compilation
2017-07-10 17:42:10 +02:00
Tomasz Drwięga a24b6ad983 Use standard paths for Ethash cache (#5881)
* Use cache path to store ethash files.

* Fixing tests, more flexible API.

* Use AsRef<Path> everywhere.

* Fixing ethcore tests.

* Fix RPC tests.
2017-07-10 12:57:40 +02:00
Robert Habermeier 125aa0aeb4 Merge pull request #5959 from paritytech/dont-compute-hash
Defer code hash calculation.
2017-07-06 19:00:19 +02:00
Marek Kotewicz 46183b1cdd bigint upgraded to version 3.0 (#5986)
* bigint upgraded to version 3.0

* fixed missing FromHex import in ethcore tests

* fixed missing FromHex import in rpc tests
2017-07-06 11:26:14 +02:00
Tomasz Drwięga 5d9f5e3509
Defer code hash calculation. 2017-06-30 11:30:32 +02:00
Arkadiy Paronyan 57626b60e7 EIP-168, 169: Dust protection (#4757)
* Dust protection

* Track touched accounts in the substate

* Minor alterations
2017-06-28 09:10:57 +02:00
Marek Kotewicz 575c51f5a0 eip214, #4833 (#4851) 2017-06-19 11:41:46 +02:00
Arkadiy Paronyan 99bfef2801 EIP-211 RETURNDATACOPY and RETURNDATASIZE (#5678)
* EIP-211

* Optimized memory usage

* Optimized truncation
2017-06-06 18:47:12 +03:00
Arkadiy Paronyan e6a31e7543 EIP-210 BLOCKHASH changes (#5505)
* EIP-210

* comment
2017-05-30 11:52:33 +02:00
Arkadiy Paronyan dd004aba9f EIP-140 (#5477) 2017-05-23 16:49:17 +03:00
Robert Habermeier 60bb0de9d6 Calculate post-constructors state root in spec at load time (#5523)
* apply contract constructors at spec load time

* debugging

* do trie updates in two stages

* add lint exception to newly-dead constructor

* squash warning in RPC tests

* kill dead accountdb constructors

* restore accountdb constructors under test configuration

* use provided state root in spec, if it exists
2017-05-03 09:00:02 +02:00
Arkadiy Paronyan b50fb71dd1 EIP-86 (#4697)
* EIP-86

* Disable EIP-86 auto activation for now
2017-04-19 14:30:00 +02:00
arkpar 314af4cdae Use in-memory database in tests 2017-04-13 12:17:53 +02:00
Tomasz Drwięga d2394d3ac3 Updating paths to repos. (#5330)
* Updating paths to repos.

* Updating rotor and libusb

* Fixing other occurrences
2017-03-29 15:17:27 +02:00
keorn a61b1567d0 Strict validation transitions (#4988)
* ability to make validation stricter

* fix consensus

* remove logger
2017-03-28 10:46:52 +02:00
keorn 9fdd0e3a0a Switching ValidatorSet (#4961)
* add multi validator set

* nicer comment

* validate in constructor

* reporting
2017-03-23 13:19:28 +01:00
Marek Kotewicz 044d070667 rlp deserialization refactor, 30% faster (#4901)
* fixed naming of rlp modules

* RlpStream cleanup

* appending short rlp lists (0...55 bytes) is 25% faster

* RlpStream does not use bytes module, nor trait Stream

* removed unused code from rlp module

* compiling ethcore-util with new rlp serialization

* compiling parity with new rlp serialization

* fixed compiling ethcore-light with new rlp serialization

* fixed compiling ethsync with new rlp serialization

* moved rlp benches and rlp tests

* rlp deserialization refactor, 30% faster

* removed redundant comment, print

* fixed compiling parity with new rlp deserialization

* removed redundant double-space

* fixed failing test

* updated rlp docs, removed unused traits

* fixed rlp benchmarks

* replace usage of WriteBytesExt with ByteOrder

* removed unused, commented out code

* fixed merge conflict
2017-03-22 14:41:46 +01:00
Tomasz Drwięga 7e87e9e8ad Updating JSON-RPC crates (#4934)
* New version of jsonrpc.

* Better invalid encoding messages

* Fixing deprecated methods of tokio_core

* Using dedicated branch for jsonrpc

* Bump
2017-03-22 07:02:14 +01:00
Marek Kotewicz a555686bcd rlp serialization refactor (#4873)
* fixed naming of rlp modules

* RlpStream cleanup

* appending short rlp lists (0...55 bytes) is 25% faster

* RlpStream does not use bytes module, nor trait Stream

* removed unused code from rlp module

* compiling ethcore-util with new rlp serialization

* compiling parity with new rlp serialization

* fixed compiling ethcore-light with new rlp serialization

* fixed compiling ethsync with new rlp serialization

* removed redundant comment, print

* removed redundant double-space

* replace usage of WriteBytesExt with ByteOrder
2017-03-20 19:14:29 +01:00
Arkadiy Paronyan 43871e393c Additional kovan params (#4892) 2017-03-14 11:41:56 +01:00
keorn ade5a13f5b Add registrar fields (#4716)
* add registrar field

* use constructor for dev registrar

* fix test
2017-03-02 12:25:55 +01:00
Robert Habermeier 1bf2b27708 Propagate trie errors upwards from State (#4655)
* state backend trait mirroring state_db API

* minimal state backend trait

make state module public

* fix json tests

* return errors on database corruption

* fix tests, json tests

* fix remainder of build

* add Backend bound on state
2017-02-26 13:10:50 +01:00
Robert Habermeier 1fba73c15e minimal state backend trait
make state module public
2017-02-21 12:35:21 +01:00
Arkadiy Paronyan c012dfc3ef EIP-98: Optional transaction state root (#4296)
* EIP98: Optional receipt state root

* Use if-else

* Fixing tests
2017-01-25 20:22:48 +01:00
Gav Wood 8404edb656 Fix whitespace (#4299)
* Fix whitespace.

* Update copyright years/owner.

* Push release only for tags.
2017-01-25 18:51:41 +01:00
keorn ba0209678b ValidatorSet reporting (#4208)
* remove register_account_provider

* build rpc module

* new dummy client

* common EngineSigner struct

* from -> into

* initial report via call

* separate safe from regular contract

* transact_contract

* fix build

* return Signature, docs

* add sign method to some engines

* add safeContract spec

* update specs to new contracts

* use AuthorityRound for contract spec

* add more reporting

* add reporting test

* use gas floor

* shorter
2017-01-24 12:03:58 +03:00
keorn be30c44179 Validator/authority contract (#3937)
* dir

* simple validator list

* stub validator contract

* make the engine hold Weak<Client> instead of IoChannel

* validator set factory

* register weak client with ValidatorContract

* check chain security

* add address array to generator

* register provider contract

* update validator set on notify

* add validator contract spec

* simple list test

* split update and contract test

* contract change

* use client in tendermint

* fix deadlock

* step duration in params

* adapt tendermint tests

* add storage fields to test spec

* constructor spec

* execute under wrong address

* create under correct address

* revert

* validator contract constructor

* move genesis block lookup

* add removal ability to contract

* validator contract adding validators

* fix basic authority

* validator changing test

* more docs

* update sync tests

* remove env_logger

* another env_logger

* cameltoe

* hold EngineClient instead of Client

* add a comment about lock scope
2017-01-10 12:23:59 +01:00
keorn e5b3c092c8 Merge branch 'master' into optional-spec 2017-01-03 15:42:56 +01:00
Robert Habermeier 8125b5690c Port `try` macro to new `?` operator. (#3962)
* initial untry sweep

* restore try in ipc codegen, fix inference

* change a few missed try instances
2016-12-27 12:53:56 +01:00
keorn afc4cd2785 Allow contract constructors in chain spec (#3932)
* constructor spec

* execute under wrong address

* create under correct address

* revert

* move genesis block lookup

* remove env_logger
2016-12-23 18:44:39 +01:00
Igor Artamonov be75cbfaaa set CHAIN_ID for Classic (#3934)
* configurable CHAIN_ID

* set CHAIN_ID for Ethereum Classic
2016-12-22 13:10:58 +01:00
keorn 552a772cc1 make fields defaulting to 0 optional 2016-12-22 07:06:40 +01:00
Gav Wood 20b2f84d48 Merge pull request #3828 from ethcore/new-dirs
New directory structure
2016-12-15 14:34:01 +01:00
Gav Wood a74bce2c06 Merge pull request #3759 from ethcore/auth-bft
Tendermint Engine
2016-12-15 13:18:15 +01:00
keorn f686fa3d6f update specs and generic conversion 2016-12-14 12:50:32 +01:00
arkpar be5fefe772 Merge branch 'master' of github.com:ethcore/parity into new-dirs 2016-12-14 00:04:11 +01:00
arkpar 5fd2e15313 Style and docs 2016-12-12 23:21:44 +01:00
keorn fa504e510f Merge branch 'master' into auth-bft 2016-12-12 21:28:46 +01:00
arkpar 6601fde328 New data paths with upgrade 2016-12-12 16:51:07 +01:00
Gav Wood 17cc2be4b5
Rename ethcore -> parity in license. 2016-12-11 19:30:54 +01:00
arkpar 97f358ced9 AuthorityRound network simulation test 2016-12-09 20:38:06 +01:00
arkpar ca7406773f AuthorityRound network simulation test 2016-12-09 19:27:16 +01:00
Gav Wood ad36743122 Merge pull request #3719 from ethcore/engine-block-ordering
Engine block ordering
2016-12-05 10:37:36 -08:00
keorn 6fc943ca6d Merge branch 'master' into auth-bft 2016-12-05 16:37:35 +00:00
Robert Habermeier a726472023 Merge pull request #3713 from ethcore/fix-v-u64
Encode networkid as a u64.
2016-12-05 17:14:07 +01:00
keorn c61a0e97b3 make engine determine block order 2016-12-05 15:20:32 +00:00
keorn c39d504167 Merge branch 'spec-rlp-loading' into auth-bft 2016-12-05 14:11:06 +00:00
keorn 22632e6324 make generic seal take valid rlp 2016-12-05 14:07:31 +00:00
Gav Wood 2911c549e3
Encode networkid as a u64. 2016-12-04 10:48:26 -08:00
keorn 155da50fcd Merge branch 'master' into auth-bft 2016-11-30 13:06:21 +00:00
arkpar b0555fbe7c State export 2016-11-28 01:37:24 +01:00
keorn 66526af5a8 pass engine in tests 2016-11-21 18:53:53 +00:00
keorn 8ac989cbeb Merge remote-tracking branch 'parity/master' into bft 2016-11-16 10:29:54 +00:00
keorn d19e8c5505 Merge remote-tracking branch 'parity/master' into bft 2016-11-15 10:26:37 +00:00
keorn 54e4956345 return errors from constructor 2016-11-15 10:21:18 +00:00
keorn ae5ae765a6 Merge branch 'master' into auth-round 2016-11-14 18:04:44 +00:00
keorn 06ebd5fa1a remove most panics 2016-11-14 17:42:56 +00:00
keorn 0b5a9a6e60 nicer bundled spec message 2016-11-14 14:29:33 +00:00
keorn 501f6d3f49 Merge branch 'master' into auth-round 2016-11-14 10:08:14 +00:00
keorn d8e6dbd981 Merge branch 'master' into dev-chain 2016-11-14 10:05:34 +00:00
keorn 2d4b4cf5c9 revert moves to Spec 2016-11-14 10:04:34 +00:00
Gav Wood 4a92668c56 Fix chainspec storage field. (#3406)
Add a test.
2016-11-13 13:58:42 +01:00
keorn 53258cca6c add new dev spec 2016-11-11 17:27:20 +00:00
keorn a719b91b63 move spec constructors to spec 2016-11-11 16:37:44 +00:00
keorn ea960f1c27 Merge remote-tracking branch 'parity/master' into bft 2016-11-07 11:34:45 +00:00
keorn 255ec0c139 Merge branch 'master' into auth-round 2016-11-04 11:35:17 +00:00
Gav Wood d3de475205 EIPs 155, 160, 161 (#2976)
* The front-end for each hard-fork, also EIP-160.

* Address EIP161 a/c

* Include EIP-161b

* EIP-161 part d.

* Fix test build.

* Fix one test, add another.

* Fix use of bloom & renaming.

* Initial groundwork for EIP-155

* Fix minor bug.

* Fix all tests finally.

* Rest of EIP-155.

* Add tests for EIP-155 algorithm.

Update transaction tests validation.

* Minor reformat.

* Address grumbles.

* Remove unused code.

* Fix SUICIDE gas mechanism and add consensus tests.

* Remove commented code.

* Set Frontier hardfork block number

* Fix warning.

* Transaction tests,
2016-11-03 22:22:25 +01:00
keorn 3ff26dd544 Merge branch 'master' into auth-round-no-mocknet 2016-10-26 17:50:04 +01:00
Robert Habermeier 0fedc27332 Remove ethcore::common re-export module (#2792)
* no longer export action_params

* remove transaction, header, receipt re-rexports from common

* remove env_info and builtins re-exports from common

* remove everything but util export from common

* replace common usages with util, remove module

* add a prelude module for ethcore-bigint
2016-10-24 18:35:25 +02:00
keorn aa05823afe Merge remote-tracking branch 'parity/master' into auth-round-no-mocknet 2016-10-24 15:32:30 +01:00
Robert Habermeier 96f4c10453 sweep most unwraps from ethcore crate, dapps crate (#2762)
* sweep most unwraps from ethcore crate

* purge unwrap from dapps server

* whitespace

[ci:none]
2016-10-20 23:41:15 +02:00
keorn 44f42ac7d3 Merge remote-tracking branch 'parity/master' into auth-round-no-mocknet
Conflicts:
	ethcore/src/state/mod.rs
	ethcore/src/tests/mod.rs
2016-10-12 18:39:31 +01:00
keorn 1f56588b87 Merge remote-tracking branch 'parity/master' into bft
Conflicts:
	ethcore/src/client/client.rs
2016-10-05 14:57:14 +01:00
keorn 64d7bcbd0c validators -> authorities 2016-10-05 14:31:31 +01:00
Nikolay Volf e1d3b3fff8 Accounts bloom in master (#2426)
* bloom crate link

* database layout and outdated tests

* state db alterations

* v10 migration run

* using arc

* bloom migration

* migration fixes and mess

* fix tests
2016-10-03 12:02:43 +02:00
keorn 9ca938f740 Merge remote-tracking branch 'parity/master' into bft
Conflicts:
	ethcore/src/client/client.rs
	sync/src/api.rs
2016-09-30 12:44:52 +01:00
keorn d59e9e816e fix tests compilation 2016-09-29 16:57:52 +01:00
Gav Wood 15a14a5f49 Expanse compatibility (#2369)
* Add support for Expanse.

* Fix build.

* Refactor to be able to alter the eth subprotocol name

* Fix JSON.

* Support exp hardfork.

* Fix exp json again.

* Fixed test

* Fix tests.
2016-09-28 14:21:59 +02:00
Arkadiy Paronyan ad63780b4d Canonical state cache (master) (#2311)
* State cache

* Reduced copying data between caches

Whitespace and optional symbols

* Reduced copying data between caches

Whitespace and optional symbols

* Set a limit on storage cache

* Style and docs
2016-09-27 18:02:11 +02:00
keorn fd6900bbb3 Merge remote-tracking branch 'parity/master' into bft
Conflicts:
	Cargo.lock
2016-09-27 12:37:43 +02:00
keorn 49fba0b548 Merge branch 'master' into auth-round
Conflicts:
	ethcore/src/miner/miner.rs
	sync/Cargo.toml
2016-09-19 14:35:44 +02:00
Tomasz Drwięga 7f7e74869c Bump clippy & Fix warnings (#2109)
* Bump clippy

* Fixing warnings
2016-09-16 23:03:26 +02:00
keorn bb59c2288e docs on authority spec 2016-09-14 17:28:57 +02:00
keorn bedbe6e65e update test spec loading 2016-09-14 11:20:22 +02:00
keorn ddb6fec171 add new test specs 2016-09-14 11:17:39 +02:00
keorn 341e06481e Split internal sealing from work preparation (#2071)
* separate block preparation methods

* Split internal sealing from work sealing, add cli option

* replace cli with engine method, simplify

* More docs about sealing types. Bypass work in external txs.

* split requires_reseal, add test and new test miner
2016-09-13 15:09:07 +02:00
keorn 8b9e7c0ba5 Merge remote-tracking branch 'parity/split-internal-seal' into auth-round 2016-09-13 12:57:52 +02:00
keorn e41b6c410f split requires_reseal, add test and new test miner 2016-09-13 12:52:14 +02:00
keorn 747898d8e7 add new engine to spec 2016-09-08 12:28:59 +02:00
keorn 4ccbec1148 Merge remote-tracking branch 'parity/master' into bft
Conflicts:
	sync/src/api.rs
	sync/src/lib.rs
2016-09-07 16:54:39 +02:00
keorn 91fbaf935c Merge remote-tracking branch 'parity/master' into bft
Conflicts:
	ethcore/src/client/client.rs
2016-09-05 18:16:09 +02:00
keorn 0af4bf23a9 add internal timeout service, test proposer switching 2016-09-05 17:51:29 +02:00
debris aa8b871e49 handling invalid spec jsons properly, additional tests, closes #1840 2016-09-05 17:41:34 +02:00
Robert Habermeier bb6243c550 merge with master 2016-09-01 15:07:06 +02:00
Robert Habermeier 5dd56aa070 port ethcore 2016-09-01 14:29:59 +02:00
Robert Habermeier 9a5668f802 get rid of populatable and bytesconvertable traits (#2019) 2016-09-01 12:23:31 +02:00
keorn 2f3d162f57 Merge remote-tracking branch 'parity/master' into bft 2016-08-31 18:19:24 +02:00
Nipunn Koorapati 4389742ca3 Make the block header struct's internals private (#2000)
* Make the block header struct's internals private

Currently, this involves a lot of explicit cloning, but we
could migrate the return types of the get_* functions to
be copies rather than references since they are mostly copy
types anyway.

I opted to eliminate the constructor in favor of using
Default::default() plus calling a bunch of setters. This
is similar to the model that a Google Protobuf client uses
and I think it looks fine.

* Drop some unnecessary cloning by comparing references

* Fix compiler errors from callsites in tests.
2016-08-29 11:35:23 +02:00
keorn 3aa862c9c2 add test, start tendermint 2016-08-23 12:58:40 +02:00
keorn a20a0de48f add spec 2016-08-21 15:28:40 +02:00
Robert Habermeier 76a7246369 Snapshot creation and restoration (#1679)
* to_rlp takes self by-reference

* clean up some derefs

* out-of-order insertion for blockchain

* implement block rebuilder without verification

* group block chunk header into struct

* block rebuilder does verification

* integrate snapshot service with client service; flesh out implementation more

* initial implementation of snapshot service

* remove snapshottaker trait

* snapshot writer trait with packed and loose implementations

* write chunks using "snapshotwriter" in service

* have snapshot taking use snapshotwriter

* implement snapshot readers

* back up client dbs when replacing

* use snapshot reader in snapshot service

* describe offset format

* use new get_db_path in parity, allow some errors in service

* blockchain formatting

* implement parity snapshot

* implement snapshot restore

* force blocks to be submitted in order

* fix bug loading block hashes in packed reader

* fix seal field loading

* fix uncle hash computation

* fix a few bugs

* store genesis state in db. reverse block chunk order in packed writer

* allow out-of-order import for blocks

* bring restoration types together

* only snapshot the last 30000 blocks

* restore into overlaydb instead of journaldb

* commit version to database

* use memorydbs and commit directly

* fix trie test compilation

* fix failing tests

* sha3_null_rlp, not H256::zero

* move overlaydb to ref_overlaydb, add new overlaydb without on-disk rc

* port archivedb to new overlaydb

* add deletion mode tests for overlaydb

* use new overlaydb, check state root at end

* share chain info between state and block snapshotting

* create blocks snapshot using blockchain directly

* allow snapshot from arbitrary block, remove panickers from snapshot creation

* begin test framework

* blockchain chunking test

* implement stateproducer::tick

* state snapshot test

* create block and state chunks concurrently, better restoration informant

* fix tests

* add deletion mode tests for overlaydb

* address comments

* more tests

* Fix up tests.

* remove a few printlns

* add a little more documentation to `commit`

* fix tests

* fix ref_overlaydb test names

* snapshot command skeleton

* revert ref_overlaydb renaming

* reimplement snapshot commands

* fix many errors

* everything but inject

* get ethcore compiling

* get snapshot tests passing again

* instrument snapshot commands again

* fix fallout from other changes, mark snapshots as experimental

* optimize injection patterns

* do two injections

* fix up tests

* take snapshots from 1000 blocks efore

* address minor comments

* fix a few io crate related errors

* clarify names about total difficulty

[ci skip]
2016-08-05 17:00:46 +02:00
Robert Habermeier 11b65ce53d Remove (almost all) panickers from trie module (#1776)
* memorydb ub patch and other cleanup

* fix denote invocations

* move trie traits into trie module

* replace "denote" with shim

* triedb returns results and no longer panics

* fix warnings

* get ethcore compiling

* warn on trie errors in ethcore

* remove unsafety from node decoder

* restore broken denote behavior for this branch

* fix overlayrecent fallout

* fix triedb tests

* remove unwrap in state

* alter Trie::get to return Result<Option<_>>

* fix refcell error in require

* fix test warnings

* fix json tests

* whitespace

[ci:skip]

* Avoid unneeded match/indentation

* whitespace

* prettify map_or_else

* remove test warning
2016-08-03 18:35:48 +02:00
keorn b672d51a74 Instant sealing engine (#1767)
* add an instant sealing engine

* add sealing engine tests

* rename to InstantSeal

* update name in json

* whitespace

[ci:skip]
2016-07-30 14:42:31 -07:00
keorn 11cb544c24 Collect consensus/null engines into a single module (#1754)
* collect consesnsus engine code into module

* move Engine to mod

* fix json test
2016-07-28 20:32:20 +02:00
Arkadiy Paronyan 6b1e722a6b Disconnect peers on a fork (#1738) 2016-07-27 21:38:22 +02:00
Gav Wood e734810293 Ethereum classic (#1706)
* Add Ethereum Classic support

(Rename homestead-dogmatic -> classic)

* Additional change needed.

* More needed changes.

* Separate database path for known forks.

* Address minor grumble.
2016-07-25 10:20:22 +02:00
Robert Habermeier 36d3d0d7d7 replace synchronization primitives with those from parking_lot (#1593)
* parking_lot in cargo.toml

* replace all lock invocations with parking_lot ones

* use parking_lot synchronization primitives
2016-07-13 19:59:59 +02:00
Robert Habermeier 7200cfcbc9 expunge &Vec<T> pattern (#1579)
* expunge &Vec<T> pattern

* fix travis
2016-07-12 10:28:35 +02:00
Gav Wood 3b662c285f Switch out .X().unwrap() for .unwrapped_X 2016-07-07 09:37:31 +02:00
Gav Wood 335bce85e8 Gas price statistics. (#1291)
* Gas price statistics.

Affects eth_gasPrice.
Added ethcore_gasPriceStatistics.

Closes #1265

* Fix a bug in eth_gasPrice

* Fix tests.

* Revert minor alteration.

* Tests for gas_price_statistics.

- Tests;
- Additional infrastructure for generating test blocks with
transactions.
2016-06-18 10:52:50 +02:00
Gav Wood ac73b2628a Basic Authority (#991)
* Firt commit.

* First non-functional but correct implementation of BasicAuthority.

Still needs:
- Sealing infrastructure.

* Punch a hole to give miner access to key store.

* Fix test built.

* Basic version of synchronous mining.

This will seal a block whenever a new transaction comes through.
To be made better we need a timer which will wait for one second after the
last block before sealing a new one - better still would be to cooperatively
interleave blocks with other sealing nodes.

* Add tests.

* Fix minor issues from repotting.

* Address grumbles.
2016-05-03 17:23:53 +02:00
Marek Kotewicz 373284ca0a spec loading cleanup (#858)
* spec loading cleanup in progress

* changed engine field in json spec

* refactored engine params

* polishing spec loading refactor

* fixed compiling json tests

* fixed compiling parity

* removed warnings

* removed commented out code

* fixed failing test

* bringing back removed TODO in spec.
2016-04-09 10:20:35 -07:00
Gav Wood 72b604b8e8 Avoid tracing DELEGATECALL and CALLCODE. Plus tests for it. 2016-03-20 19:20:37 +01:00
debris 1f03ae54d6 moved ethcores spec to its own module, added genesis 2016-03-17 15:15:10 +01:00