* Add trace information to eth_estimateGas
* replace unwrap better version
* change vm::Error formatter to more user-friendly
* remove extra error format
* use map_or instead sequence of map/unwrap_or
* fix(extract `timestamp_checked_add` as lib)
* fix(whisper types): remove unused `EmptyTopics`
* fix(time-lib): feature-flag to use time-lib or std
This commit adds conditional compilation checks that falls back to `our time-lib` when
`time_checked_add` is not available in the standard library
Note, `time_checked_add` covers both `checked_add` and `checked_sub`
* fix(grumble): use cfg_attr to define rustc feature
* ethash: initial implementation of progpow
* progpow: use wrapping arithmetic
* progpow: cleanup comments
* progpow: fix keccak_f800
* progpow: reorder definitions
* progpow: general fixing
* progpow: add basic tests from geth
* progpow: generate c_dag and add test
* progpow: fix progpow_init and progpow_loop
* progpow: fix and add new test
* progpow: tabify
* progpow: add shared testvectors from geth and aleth
* progpow: add benchmarks
* progpow: don't read bytes from dag
* ethash: use criterion for progpow benchmarks
* progpow: dont borrow hash on fnv1a_hash
* progpow: don't borrow operand on progpow merge
* progpow: hardcode dag lookup function
we only support light verification anyway
* progpow: read double words directly from the dag
* progpow: inline some small functions
* progpow: remove some bounds checking from the main loop
* progpow: remove unreachable match cases
* progpow: remove bounds check in keccak_f800_round
* progpow: fix ptr::swap
* progpow: force loop unroll in keccak_f800_round
* progpow: remove unnecessary branching in progpow_loop
* progpow: force loop unroll in fill_mix
* progpow: silence unused warning
* progpow: dont run last keccak_f800_round out of the loop
rustc generates the same assembly, it unrolls the loop
* progpow: fix output of keccak_f800_short
* ethcore: support progpow in ethash engine
* ethash: fix typo
* ethcore, ethash: fix tests
* json: fix ethash spec tests
* ethash: update quick_get_difficulty for progpow
* ethash: drop light cache on progpow transition block
* ethash: fix quick_get_difficulty tests
* progpow: update to spec v0.9.0
* progpow: update to spec v0.9.1
* progpow: update to spec v0.9.2
* ethash: rename progpow benchmarks
* fix Cargo.lock bad merge
* ethash: only export modules for benchmarks
* ethash: progpow: remove unsafe unchecked indexing
* ethash: create enum for pow algorithm
* ethash: box the progpow cdag
* ethash: skip slow progpow test vectors on ci
* ethash: don't skip progpow test vectors
they don't take too long when running in release mode which is the case
for CI.
* ethash: progpow: update copyright date
Co-Authored-By: andresilva <andre.beat@gmail.com>
* ethcore: remove verification of ci-skip-tests on non-test builds
* Add function to update minimum gas price
* Update TestMinerService to handle min_gas_price changes
* Place minimum gas price test behind feature flag
* Update check for fixed gas pricer to be more explicit
* Use errors::unsupported instead of errors::request_rejected
* Add test that fails to set minimum gas price
* Fix test that should fail when setting new gas price
* Put dev dependencies behind feature flag
* Fix deadlock in set_minimal_gas_price()
* Update RPC tests with mocked error response
* Remove unnecessary cfg flag
* Remove duplicate crate imports
* Extract accounts from ethcore.
* Fix ethcore.
* Get rid of AccountProvider in test_helpers
* Fix rest of the code.
* Re-use EngineSigner, fix tests.
* Simplify EngineSigner to always have an Address.
* Fix RPC tests.
* Add deprecation notice to RPCs.
* Feature to disable accounts.
* extract accounts in RPC
* Run with accounts in tests.
* Fix RPC compilation and tests.
* Fix compilation of the binary.
* Fix compilation of the binary.
* Fix compilation with accounts enabled.
* Fix tests.
* Update submodule.
* Remove android.
* Use derive for Default
* Don't build secretstore by default.
* Add link to issue.
* Refresh Cargo.lock.
* Fix miner tests.
* Update rpc/Cargo.toml
Co-Authored-By: tomusdrw <tomusdrw@users.noreply.github.com>
* Fix private tests.
* Make check_epoch_end_signal to only use immutable data
* Move check_epoch_end_signals out of commit_block
* Make check_epoch_end_signals possible to fail
* Actually return the error from check_epoch_end_signals
* Remove a clone
* Fix import error
* Allow specifying local accounts via CLI
* Add `tx-queue-locals` CLI option
* ethcore: modify miner to check options vec before importing transaction
* modify tests (ethcore/parity)
Resolves#9634
* fix formatting
* fixes: Make prefer HashSet over Vec<>, add test, comment formatting
* Update ethcore/src/miner/miner.rs
Co-Authored-By: insipx <aplaza@liquidthink.net>
* Fix comments and add helper for set->vec conversion
* remove blank line from use statement
* fix helper test
* formatting
* fix test to pass on nightly
* revert test fix for nightly
* Tx permission contract improvement
* Take in account zero gas price certification when doing transact_contract
* DRY in ServiceTransactionChecker
* Fix typos and regroup mod
* Fix imports
* Simplify code in struct instantiation
Co-Authored-By: VladLupashevskyi <vlad@lupashevskyi.com>
* Remove re-export of `CallContract` and `RegistryInfo` from `ethcore/client`
* Remove CallContract and RegistryInfo re-exports again
This was missed while fixing merge conflicts
* added BlockChainReset trait, client impl, and cli interface
* show block hashes to be deleted and new best block, update best block in db, better cli interface
* delete BlockNumber from COL_EXTRA
* add TODO comment
* add BlockReciepts to imports
* refactor block_headers_from_best_block, better cli documentation
* exit gracefully if reset arg isn't supplied
* fix cli usage macro
* removed stray int literals
* use Vec::with_capacity
Co-Authored-By: seunlanlege <seunlanlege@gmail.com>
* cast n to usize
* correct imports
* make db reset arg required
* Add is_base_storage_root_unchanged
* Fix compile, use a shortcut for check, and remove ignored tests
* Add a warn!
* Update ethereum/tests to v6.0.0-beta.2
* grumble: use {:#x} instead of 0x{:x}
Co-Authored-By: sorpaas <accounts@that.world>
currently trace_filter can't return failed contract creation transaction
but trace_block can query the failed contract creation transaction.it
because the logic of parity-ethereum/ethcore/src/trace/types/filter.rs
Line 109 in 9982eba
```
_ => false
```
this patch correct the logic:
```
_ => self.to_address.matches_all()
```
Signed-off-by: Deshi Xiao <xiaods@gmail.com>
* Make sure parent block is not in importing queue when importing ancient blocks
* Clear queue when an ancient import fails
* Lock only once in clear
* Add comments why queued check is needed
* Should push the value back to the queue
* Directly check in chain.read()
* Remove extra empty line
* Revert unused verification change
* Replace ethcore-logger with env-logger.
* Fix logger initialization in WASM tests.
* uncomment logger initialization in secret store
* Don't use ethcore-logger in whisper.
* Move ethcore-logger within parity dir.
* Uncomment rest from secret-store.
* Use `let _ =` in private_contract for consistency
* `ok()` to `let _ =` fix in service
* Use `let _ = ` for state_db
Fix: new blocks notifications sometimes missing in pubsub RPC
Implement new struct to pass to `new_blocks()` with extra parameter - `has_more_blocks_to_import`, which was previously used to determine whether the notification should be sent. Now it's up to each implementation to decide what to do.
Updated all implementations to behave as before, except `eth_pubsub`, which will send notification even when the queue is not empty.
Update tests.
- Refactor (and rename crate) and implement RwLock len cache.
- improve docs
- update ethcore verification queue to new version
- Implement Default, From, also derive Debug
- update: parking_lot to 0.7
New util LenCachingMutex can be used in place of a Mutex, when working
with collections, or other types with a len() method. When
the Guard is dropped, the value returned from len() is stored
into an AtomicUsize and can be queried using load_len() without
needing to lock the Mutex. Implementations for ```Vec``` and
```VecDeque```.
Now used in [Verification](4ded4181a6/ethcore/src/verification/queue/mod.rs (L196)) so that calls to ```VerificationQueue.queue_info()```
no longer require locks.
* Add a dump of the state at the end of transaction for --json-test.
Also fixes json-test output on finish, and allow to put both on err or
out (--out-only and --err-only).
* Dump state resolution from trie, function behind evm-bin feature to avoid misuse.
* Rename 'slow' method to 'to_pod_full'.
Use cache first in 'to_pod_full', for in between commits case.
Change dump activation to use a function pointer instead.
* Fix tests.
* Query and add storage values to dump.
* Switch to use `require` method, even if less efficient it is better in
this case to reuse existing code.
Reuse of `storage_at` was not easy in this case (could not iterate and
use the method at the same time (refcell mutable borrow panics) so
keeping code as is.
* Switch to returning error.
Use 'base_storage_root' instead of 'storage_root'.
Added a test, it will only execute with json-test in ci, or when launch
with the feature.
* Renaming of command line parameters.
Comments fixes.
Minor code changes.
* Fix evmbin cmd parsing test.
* README update.
* Fix extra space and avoid clone call on copiable address.
* Revert test submodule.
* Revert wasm-test submodule.
* Use map_or instead of map + unwrap_or
* restore tests submodule
* Rename db_restore => client
* First step: make it compile!
* Second step: working implementation!
* Refactoring
* Fix tests
* PR Grumbles
* PR Grumbles WIP
* Migrate ancient blocks interating backward
* Early return in block migration if snapshot is aborted
* Remove RwLock getter (PR Grumble I)
* Remove dependency on `Client`: only used Traits
* Add test for recovering aborted snapshot recovery
* Add test for migrating old blocks
* Fix build
* PR Grumble I
* PR Grumble II
* PR Grumble III
* PR Grumble IV
* PR Grumble V
* PR Grumble VI
* Fix one test
* Fix test
* PR Grumble
* PR Grumbles
* PR Grumbles II
* Fix tests
* Release RwLock earlier
* Revert Cargo.lock
* Update _update ancient block_ logic: set local in `commit`
* Update typo in ethcore/src/snapshot/service.rs
Co-Authored-By: ngotchac <ngotchac@gmail.com>
* ethcore: use Machine::verify_transaction on parent block
also fixes off-by-one activation of transaction permission contract
* ethcore: clarify call to verify_transaction
* Add FIXME link for a state mod statement
* Remove unused benches feature in ethcore
* Fix evm benches compile
* Fix ethash benches compile
* Switch to criterion
* Update test reference.
Block test are really not working so I disabled a few by commenting
directly in source.
* Move ethtest commit cursor.
* Implements 'NoProof' engine from https://github.com/ethereum/tests/issues/464 .
Since tests has been regenerated those one were failing on block
difficulty check.
Update ethereum/tests, waiting for cost fix (block test are still
commented).
* Update tests submodule reference to latest (all test passing except an
identified case).
Fix block reward of constantinople json.
* Restore broken test by using old json tests files.
* Use CanonNoSeal instead of a custom engine, still have to include some
additional tests code.
* Gas upper limit check in json_chain test was bad, moving the test to
verification, the test is running in `verify_header_param`.
Note that test was previously only for ethash, and now for any engine.
* Restore old behavior (gas uper limit only for ethash engine), at the
cost of an additional trait method.
* Proper rpc test fix.
* Update tests submodule, add SStore bug tests.
* Fix json issue tabulation.
Update tests submodule to latest master (lot of new sstore tests
passing)
* Switch ethereum/tests to tag 6.0.0-beta.1 (no tests changes from latest
synch).
* Display hex with separator, use indirection instead of clone for copy
types.
* Fixing and disabling some tests for windows 10 compatibility.
* Few adjustment for windows in tests (eg bigger timeout for keyserver tests)
* Spaces and temporary single thread ci (to be able to spot the error).
* aura: emit ancestry actions for finalizing blocks
* aura: refactor is_epoch_end to get finalized blocks as argument
* ethcore: add is_epoch_end_light method to Engine
The full client now tracks finality by querying the engine on each block import,
and it also persists the finalization state to the DB. For the light client
current it doesn't persist finality information and only keeps track of finality
for epoch signals, by calling `is_epoch_end_light`. This method implements the
previously existing logic of building finality for all the blocks in the current
epoch and then checking the finalized blocks against the transition store.
* ethcore: allow finalizing current block
* aura: fix construction of finality proof
* aura: fix warnings
- missing docs for is_epoch_end_light
- unused method unfinalized_hashes in RollingFinality
* aura: fix clone on copy types
* Add signed refund
* Use signed 256-bit integer for sstore gas refund substate
* Fix tests
* Remove signed mod and use i128 directly
* Fix evm test case casting
* Fix jsontests ext signature
* `ExecutionsRequest` from light-clients as read-only
This changes so all `ExecutionRequests` from light-clients are executed
as read-only which the `virtual``flag == true ensures.
This boost up the current transaction to always succeed
Note, this only affects `eth_estimateGas` and `eth_call` AFAIK.
* grumbles(revert renaming) : TransactionProof
* grumbles(trace) : remove incorrect trace
* grumbles(state/prove_tx) : explicit `virt`
Remove the boolean flag to determine that a `state::prove_transaction`
whether it should be executed in a virtual context or not.
Because of that also rename the function to
`state::prove_transction_virtual` to make more clear
* sync: Validate received BlockHeaders packets against stored request.
* sync: Validate received BlockBodies and BlockReceipts.
* sync: Fix broken tests.
* sync: Unit tests for BlockDownloader::import_headers.
* sync: Unit tests for import_{bodies,receipts}.
* tests: Add missing method doc.
* Add new Vm trappable interface
* Exec/Resume interface
* Basic implementation of CallCreateExecutive
* Implement resume_call and resume_create for executive
* Move convertion to call/create result to separate function
* Implement consume that converts resumable to non-resumable
* Use consume for Executive::call/create
* Resumable EVM
* Implement tracing mode without needing subtracers
* Implement vmtracer so it doesn't require extra structs for subtracing
* Use the new tracing mode in executive
* Fix most of the linting errors for cargo build
* Add the concept of stack_depth
* Add back crossbeam
* Fix some test compile
* Fix prefix address test
* Fix evm crate tests
* Fix wasm crate test compile
* Fix wasm runner compile
* Fix jsontests compile
* Fix evmbin compile
* Fix an issue with create nonce and better vm tracing interface
* Fix linting
* Fix evmbin compile
* Fix unconfirmed_substate and static_flag
* Fix an issue in create address logic
* Fix top-level tracing
* Handle builtin tracing
* Fix suicide and reward tracing index stack
* Fix an issue where trap conflicts with tracing
* Fix an issue in parent step vm tracing
* Fix revert tracing
* Fix evmbin tests
* Remove params clone
* Fix TODO proofs
* Fix jsontests compile
* Fix evmbin merge issue
* Fix wasm merge issue
* Fix wasm test
* Fix ethcore merge warnings
* Fix evmbin compile
* Better expect messages and add some trace::skip_one asserts
* ethcore: propose hardfork block number 4230000 for ropsten
* ethcore: propose hardfork block number 9000000 for kovan
* ethcore: enable kip-4 and kip-6 on kovan
* etcore: bump kovan hardfork to block 9.2M
* ethcore: fix ropsten constantinople block number to 4.2M
* ethcore: disable difficulty_test_ropsten until ethereum/tests are updated upstream
* VerificationQueue don't spawn up extra threads
In the verification queue we spawn up worker threads to do the work.
However, if `num-verifiers` is specified we still spawn the maximum
number of threads which consume extra memory.
There is one catch though when `--scale-verifiers` is specified then
we can't do it because all threads are created upon initilization AFAIK.
In my opinion, is doesn't to use both `num-verifiers` and
`scale-verifiers` they are kind of contradictory!
* Fix nits in logic and add tests for verification
* refactor(verification queue) - rm hardcoded const
* Address grumbles in new tests
* Remove hardcoded `MAX_VERIFIERS` constant and replace it by relying
entirely on `num_cpu` crate instead inorder to support CPUs that have
more cores/logical cores
* Add constantinople conf to EvmTestClient.
* Skip some test to update submodule etheureum/tests submodule to latest.
* Put skipping 'under issue' test behind a feature.
* Change blockReward for const-test to pass ethereum/tests
* Update tests to new constantinple definition (change of reward at block
5).
Switch 'reference' to string, that way we can include issues from others
repo (more flexible)Update tests to new constantinple definition (change
of reward at block 5).
Switch 'reference' to string, that way we can include issues from others
repo (more flexible).
* Fix modexp and bn128_mul gas prices in chain config
* Changes `run_test_path` method to append its directory results (without
that it stop testing at the first file failure).
Add some missing tests.
Add skip for those (block create2 is one hundred percent false but on
hive we can see that geth and aleth got similar issue for this item).
* retab current.json
* Update reference to parity issue for failing tests.
* new ethabi migration in progress
* parity migrated to new ethabi
* migrated secred-store to new ethabi
* bump ethabi to 6.0
* fixed review suggestions
* Enable all Constantinople hard fork changes in constantinople_test.json
* Address grumbles
* Remove EIP-210 activation
* 8m -> 5m
* Temporarily add back eip210 transition so we can get test passed
* Add eip210_test and remove eip210 transition from const_test
* Update & fix JSON state tests.
* Update tests to be able to run ethtest at
021fe3d410773024cd5f0387e62db6e6ec800f32.
- Touch user in state
- Adjust transaction tests to new json format
* Switch to same commit for submodule ethereum/test as geth (next includes constantinople changes).
Added test `json_tests::trie::generic::TrieTests_trieanyorder` and a few
difficulty tests.
* Remove trietestnextprev as it would require to parse differently and
implement it.
* Support new (shitty) format of transaction tests.
* Ignore junk in ethereum/tests repo.
* Ignore incorrect test.
* Update to a later commit
* Move block number to a constant.
* Fix ZK2 test - touched account should also be cleared.
* Fix conflict resolution
* Implement last_checkpoint_storage_at
* Add reverted_storage_at for externalities
* sstore_clears_count -> sstore_clears_refund
* Implement eip1283 for evm
* Add eip1283Transition params
* evm: fix tests
* jsontests: fix test
* Return checkpoint index when creating
* Comply with spec Version II
* Fix docs
* Fix jsontests feature compile
* Address grumbles
* Fix no-checkpoint-entry case
* Remove unnecessary expect
* Add test for State::checkpoint_storage_at
* Add executive level test for eip1283
* Hard-code transaction_checkpoint_index to 0
* Fix jsontests
* Add tests for checkpoint discard/revert
* Require checkpoint to be empty for kill_account and commit
* Get code coverage
* Use saturating_add/saturating_sub
* Fix issues in insert_cache
* Clear the state again
* Fix original_storage_at
* Early return for empty RLP trie storage
* Update comments
* Fix borrow_mut issue
* Simplify checkpoint_storage_at if branches
* Better commenting for gas handling code
* Address naming grumbles
* More tests
* Fix an issue in overwrite_with
* Add another test
* Fix comment
* Remove unnecessary bracket
* Move orig to inner if
* Remove test coverage for this PR
* Add tests for executive original value
* Add warn! for an unreachable cause
* ethcore: don't validate difficulty when ignoring seal check
* ethcore: fix block verification test
* ethcore: document skipped verifications when check_seal is disabled
* Add EIP-1014 transition config flag
* Remove EIP-86 configs
* Change CREATE2 opcode index to 0xf5
* Move salt to the last item in the stack
* Change sendersaltandaddress scheme to comply with current EIP-1014
* Fix json configs
* Fix create2 test
* Fix deprecated comments
This adds block reward contract config to ethash. A new config `blockRewardContractCode` is also added to both Aura and ethash. When specified, it will execute the code directly and overrides any `blockRewardContractAddress` config. Having this `blockRewardContractCode` config allows chains to deploy hard fork by simply replacing the current config value, without the need from us to support any `multi` block reward scheme.
* Verify private transaction before propagating
* Private transactions queue reworked with tx pool queue direct usage
* Styling fixed
* Prevent resending private packets to the sender
* Process signed private transaction packets via io queue
* Test fixed
* Build and test fixed after merge
* Comments after review fixed
* Signed transaction taken from verified
* Fix after merge
* Pool scoring generalized in order to use externally
* Lib refactored according to the review comments
* Ready state refactored
* Redundant bound and copying removed
* Fixed build after the merge
* Forgotten case reworked
* Review comments fixed
* Logging reworked, target added
* Fix after merge
* Remove pass-by-reference return data value from executive
* Fix tests
* Fix a missing test output
* typo: wasm_activation_test
* Tracing change in output
* json_tests: fix compile
* typo: 0..32 -> ..32 to keep it consistent with other occurance
* Fix tests
* Feed in ActionParams on VM creation
* Fix ethcore after Vm interface change
* Move informant inside Interpreter struct
* Move do_trace to Interpreter struct
* Move all remaining exec variables to Interpreter struct
* Refactor VM to allow single opcode step
* Fix all EVM tests
* Fix all wasm tests
* Fix wasm runner tests
* Fix a check case where code length is zero
* Fix jsontests compile
* Fix cargo lock
* Use match instead of expect
* Use cheaper check reader.len() == 0 for the initial special case
* Get rid of try_and_done! macro by using Result<(), ReturnType>
* Use Never instead of ()
* Fix parity-bytes path
* Bypass gasometer lifetime problem by borrow only for a instance
* typo: missing {
* Fix ethcore test compile
* Fix evm tests
* Implement EIP234
* Make filter conversion returns error if both blockHash and from/toBlock is found
This also changes PollFilter to store the EthFilter type, instead of the jsonrpc one, saving repeated conversion.
* Return error if block filtering target is not found in eth_getLogs
Use the old behavior (unwrap_or_default) for anywhere else.
* fix test: secret_store
* Fix weird indentation
* Make client log filter return error in case a block cannot be found
* Return blockId error in rpc
* test_client: allow return error on logs
* Add a mocked test for eth_getLogs error
* fix: should return error if from_block/to_block greater than best block number
* Add notes on pending
* Add comment for UNSUPPORTED_REQUEST
* Address grumbles
* Return err if from > to
* ethcore: fix pow difficulty validation
* ethcore: validate difficulty is not zero
* ethcore: add issue link to regression test
* ethcore: fix tests
* ethcore: move difficulty_to_boundary to ethash crate
* ethcore: reuse difficulty_to_boundary and boundary_to_difficulty
* ethcore: fix grumbles in difficulty_to_boundary_aux
Closes#9255
This PR also removes the limit of max 64 transactions per packet, currently we only attempt to prevent the packet size to go over 8MB. This will only be the case for super-large transactions or high-block-gas-limit chains.
Patching this is important only for chains that have blocks that can fit more than 4k transactions (over 86M block gas limit)
For mainnet, we should actually see a tiny bit faster propagation since instead of computing 4k pending set, we only need `4 * 8M / 21k = 1523` transactions.
Running some tests on `dekompile` node right now, to check how it performs in the wild.
* Comply EIP-86 with the new CREATE2 opcode
* Fix rpc compile
* Fix interpreter CREATE/CREATE2 stack pop difference
* Add unreachable! to fix compile
* Fix instruction_info
* Fix gas check due to new stack item
* Add new tests in executive
* Fix have_create2 comment
* Remove all unused references of eip86_transition and block_number
* Implement EIP-1052 and fix several issues related to account cache
* Fix jsontests
* Merge two matches together
* Avoid making unnecessary Arc<Vec>
* Address grumbles
* blockchain insert expects owned block instead of block reference
* reduce a number of times a block is deserialized
* removed cached uncle_bytes from block
* removed is_finalized from OpenBlock
* removed unused parity_machine::WithMetadata trait
* removed commented out code
* remove unused metadata from block
* remove unused metadata from block
* BlockDetails extras may have at most 5 elements
* Insert PROOF messages for some cases in blockchain
* Break expect to its own line to avoid things being too long
* Be more specific for all low-level database error cases
* Fix BranchBecomingCanonChain expect
* ethcore: fix typo in expect proof message
* Added --tx-queue-no-early-reject flag to disable early tx queue rejects because of low gas price
* Fixed failing tests, clarified comments and simplified no_early_reject field name.
* Added test case for the --tx-queue-no-early-reject flag
* Reject if Engine::on_close_block returns error
* Unify open block behaviors
* Fix tests in ethcore
* Fix Aura tests
* Fix RPC test
* Print a warning if open block failed
* Print the actual error when closing the block
* Update comments for prepare_pending_block
* Add BlockPreparationStatus to distingish three different state after prepare_pending_block
* getting started
* refactor main
* unwrap_or -> unwrap_or_else
* force parity to lower version number to trigger update
* Fix typos
* formating
* some minor refactoring
* enable lints and fix some warnings
* make it compile
* minor tweaks to make it work
* address review comments
* Rename exe to exe_path and minor import changes
* updater: unreleased -> unknown
* Add `debug` configuration to force parity-updater
* Introduce a new feature `test-updater` in order conditionally hardcode
the version number in parity in order to force an update
* This should only be used for debug/dev purposes
* nits
* Pulled latest submodule of `wasm-tests`
* aura: only report after checking for repeated skipped primaries
* aura: refactor duplicate code for getting epoch validator set
* aura: verify_external: report on validator set contract instance
* aura: use correct validator set epoch number when reporting
* aura: use epoch set when verifying blocks
* aura: report skipped primaries when generating seal
* aura: handle immediate transitions
* aura: don't report skipped steps from genesis to first block
* aura: fix reporting test
* aura: refactor duplicate code to handle immediate_transitions
* aura: let reporting fail on verify_block_basic
* aura: add comment about possible failure of reporting
* Make work-notify an optional feature
* More optional ethcore features: price-info, stratum
* Make ethcore features part of dependency instead of local features
* Put cfg gate in right location
* Feature gate register function on work-notify
* rpc: return unordered transactions in pending transactions filter
* ethcore: use LruCache for nonce cache
Only clear the nonce cache when a block is retracted
* Revert "ethcore: use LruCache for nonce cache"
This reverts commit b382c19abdb9985be1724c3b8cde83906da07d68.
* Use only cached nonces when computing pending hashes.
* Give filters their own locks, so that they don't block one another.
* Fix pending transaction count if not sealing.
* Clear cache only when block is enacted.
* Fix RPC tests.
* Address review comments.
* Store recently rejected transactions.
* Don't cache AlreadyImported rejections.
* Make the size of transaction verification queue dependent on pool size.
* Add a test for recently rejected.
* Fix logging for recently rejected.
* Make rejection cache smaller.
* obsolete test removed
* obsolete test removed
* Construct cache with_capacity.
The `patricia_trie` crate is generic over the hasher (by way of HashDB) and node encoding scheme. Adds a new `patricia_trie_ethereum` crate with concrete impls for Keccak/RLP.
* disable hardware-wallets that don't support libusb
* address grumbles
* nits
* Refactor to get rid off as much annotations asap
* Might consume slight more memory than pure conditional compilation
flags
* formatting nits
* Enable libusb for android
* Tested by it compiling succesfully with `cargo build --target=armv7--linux-androideabi`
* The binary is ~66 MB
```bash
$ size
size target/armv7-linux-androideabi/release/parity
text data bss dec hex filename
50676230 416200 31456 51123886 30c16ae target/armv7-linux-androideabi/release/parity
```
* Move all `fake-hardware-wallet` to its own crate
* Removes some conditional compilation flags
* Introduces `fake-hardware-wallet` crate
* return error if no hardware wallets are found
* Make it possible to expose jsontests using feature flag
* Add start_stop_hook for jsontests
* Fix evmbin compile
* Implement vm jsontests times to tsv result
* Use /usr/bin/env to avoid errors on non-Debian systems
* Move evmbin/bench.sh to scripts and add vm_jsontests script for convenience
* Add tempdir as required deps for test-helpers
* Address grumbles on comments
* Detect file/folder automatically and add command docs
* Fix bench script
* times -> timings
* typo: wrong if condition
* new blooms database
* fixed conflict in Cargo.lock
* removed bloomchain
* cleanup in progress
* all tests passing in trace db with new blooms-db
* added trace_blooms to BlockChainDB interface, fixed db flushing
* BlockChainDB no longer exposes RwLock in the interface
* automatically flush blooms-db after every insert
* blooms-db uses io::BufReader to read files, wrap blooms-db into Mutex, cause fs::File is just a shared file handle
* fix json_tests
* blooms-db can filter multiple possibilities at the same time
* removed enum trace/db.rs CacheId
* lint fixes
* fixed tests
* kvdb-rocksdb uses fs-swap crate
* update Cargo.lock
* use fs::rename
* fixed failing test on linux
* fix tests
* use fs_swap
* fixed failing test on linux
* cleanup after swap
* fix tests
* fixed osx permissions
* simplify parity database opening functions
* added migration to blooms-db
* address @niklasad1 grumbles
* fix license and authors field of blooms-db Cargo.toml
* restore blooms-db after snapshot
* Add tx_queue_allow_unknown_local config option
- Previous commit messages:
dispatcher checks if we have the sender account
Add `tx_queue_allow_unknown_local` to MinerOptions
Add `tx_queue_allow_unknown_local` to config
fix order in MinerOptions to match Configuration
add cli flag for tx_queue_allow_unknown_local
Update refs to `tx_queue_allow_unknown_local`
Add tx_queue_allow_unknown_local to config test
revert changes to dispatcher
Move tx_queue_allow_unknown_local to `import_own_transaction`
Fix var name
if statement should return the values
derp de derp derp derp semicolons
Reset dispatch file to how it was before
fix compile issues + change from FLAG to ARG
add test and use `into`
import MinerOptions, clone the secret
Fix tests?
Compiler/linter issues fixed
Fix linter msg - case of constants
IT LIVES
refactor to omit yucky explict return
update comments
Fix based on diff AccountProvider.has_account method
* Refactor flag name + don't change import_own_tx behaviour
fix arg name
Note: force commit to try and get gitlab tests working again 😠
* Add fn to TestMinerService
* Avoid race condition from trusted sources
- refactor the miner tests a bit to cut down on code reuse
- add `trusted` param to dispatch_transaction and import_claimed_local_transaction
Add param to `import_claimed_local_transaction`
Fix fn sig in tests
* getting started
* getting started
* signing personal messages works and refactoring
* Refactor `Ledger`
* Make `Ledger Manager` only visible inside the hardwallet-crate
* Refactor `send_apdu` with separate functions for read and write
* Add support for signing messages through `ethcore`
* Trezor modify update_devices and some error msgs
* nits
* Remove unused Result wrap in has_account
* Check whether we need to reseal for external transactions
* Fix reference to has_account interface
* typo: missing )
* Refactor duplicates to prepare_and_update_sealing
* Fix build
* Tx permission contract improvement
* Use tuple for to address
* Introduced ABI for deprecated tx permission contract
* Improved ABI for tx permission contract with contract name, name hash and version
* Introduced support for deprecated tx permission contract + fixed cache for the new version + introduced `target` for tx filter loging
* Introduced test for the new tx permission contract version + old test renamed as deprecated
* Removed empty lines
* Introduced filter_only_sender return value in allowedTxTypes fn + improved caching
* Introduced version checking for tx permission contract
* Moved tx permission contract test genesis specs to separate files
* handle queue import errors a bit more gracefully (#8385)
* Some tweaks to main.rs for parity as a library (#8370)
* Some tweaks to main.rs for parity as a library
* Remove pub from PostExecutionAction
* New Transaction Queue implementation (#8074)
* Implementation of Verifier, Scoring and Ready.
* Queue in progress.
* TransactionPool.
* Prepare for txpool release.
* Miner refactor [WiP]
* WiP reworking miner.
* Make it compile.
* Add some docs.
* Split blockchain access to a separate file.
* Work on miner API.
* Fix ethcore tests.
* Refactor miner interface for sealing/work packages.
* Implement next nonce.
* RPC compiles.
* Implement couple of missing methdods for RPC.
* Add transaction queue listeners.
* Compiles!
* Clean-up and parallelize.
* Get rid of RefCell in header.
* Revert "Get rid of RefCell in header."
This reverts commit 0f2424c9b7319a786e1565ea2a8a6d801a21b4fb.
* Override Sync requirement.
* Fix status display.
* Unify logging.
* Extract some cheap checks.
* Measurements and optimizations.
* Fix scoring bug, heap size of bug and add cache
* Disable tx queueing and parallel verification.
* Make ethcore and ethcore-miner compile again.
* Make RPC compile again.
* Bunch of txpool tests.
* Migrate transaction queue tests.
* Nonce Cap
* Nonce cap cache and tests.
* Remove stale future transactions from the queue.
* Optimize scoring and write some tests.
* Simple penalization.
* Clean up and support for different scoring algorithms.
* Add CLI parameters for the new queue.
* Remove banning queue.
* Disable debug build.
* Change per_sender limit to be 1% instead of 5%
* Avoid cloning when propagating transactions.
* Remove old todo.
* Post-review fixes.
* Fix miner options default.
* Implement back ready transactions for light client.
* Get rid of from_pending_block
* Pass rejection reason.
* Add more details to drop.
* Rollback heap size of.
* Avoid cloning hashes when propagating and include more details on rejection.
* Fix tests.
* Introduce nonces cache.
* Remove uneccessary hashes allocation.
* Lower the mem limit.
* Re-enable parallel verification.
* Add miner log. Don't check the type if not below min_gas_price.
* Add more traces, fix disabling miner.
* Fix creating pending blocks twice on AuRa authorities.
* Fix tests.
* re-use pending blocks in AuRa
* Use reseal_min_period to prevent too frequent update_sealing.
* Fix log to contain hash not sender.
* Optimize local transactions.
* Fix aura tests.
* Update locks comments.
* Get rid of unsafe Sync impl.
* Review fixes.
* Remove excessive matches.
* Fix compilation errors.
* Use new pool in private transactions.
* Fix private-tx test.
* Fix secret store tests.
* Actually use gas_floor_target
* Fix config tests.
* Fix pool tests.
* Address grumbles.
* clarify that windows need perl and yasm (#8402)
* Unify and limit rocksdb dependency places (#8371)
* secret_store: remove kvdb_rocksdb dependency
* cli: init db mod for open dispatch
* cli: move db, client_db, restoration_db, secretstore_db to a separate mod
* migration: rename to migration-rocksdb and remove ethcore-migrations
* ethcore: re-move kvdb-rocksdb dep to test
* mark test_helpers as test only and fix migration mod naming
* Move restoration_db_handler to test_helpers_internal
* Fix missing preambles in test_helpers_internal and rocksdb/helpers
* Move test crates downward
* Fix missing docs
* cli, db::open_db: move each argument to a separate line
* Use featuregate instead of dead code for `open_secretstore_db`
* Move pathbuf import to open_secretstore_db
Because it's only used there behind a feature gate
* Use tokio::spawn in secret_store listener and fix Uri (#8373)
* Directly wait for future to resolve in a threadpool
* Ignore return value
* Use path.starts_with instead of req_uri.is_absolute
The later now means something else in hyper 0.11..
* Use tokio::spawn
* typo: remove accidential unsafe impl
* remove Tendermint extra_info due to seal inconsistencies (#8367)
* More code refactoring to integrate Duration (#8322)
* More code refactoring to integrate Duration
* Fix typo
* Fix tests
* More test fix
* tokio-core v0.1.16 -> v0.1.17 (#8408)
* Replace legacy Rlp with UntrustedRlp and use in ethcore rlp views (#8316)
* WIP
* Replace Rlp with UntrustedRlp in views, explicity unwrap with expect
First pass to get it to compile. Need to figure out whether to do this or to propogate Errors upstream, which would require many more changes to dependent code. If we do this way we are assuming that the views are always used in a context where the rlp is trusted to be valid e.g. when reading from our own DB. So need to fid out whether views are used with data received from an untrusted (e.g. extrernal peer).
* Remove original Rlp impl, rename UntrustedRlp -> Rlp
* Create rlp views with view! macro to record debug info
Views are assumed to be over valid rlp, so if there is a decoding error we record where the view was created in the first place and report it in the expect
* Use $crate in view! macro to avoid import, fix tests
* Expect valid rlp in decode functions for now
* Replace spaces with tabs in new file
* Add doc tests for creating views with macro
* Update rlp docs to reflect removing of UntrustedRlp
* Replace UntrustedRlp usages in private-tx merge
* Fix TODO comments (#8413)
* update zip to 0.3 (#8381)
* update zip to 0.3
* enable zip deflate feature
* typo, docs parity_chainId: empty string -> None (#8434)
* Fix receipts stripping. (#8414)
* Changelogs for 1.9.6 and 1.10.1 (#8411)
* Add changelog for 1.9.6
* Add Changelog for 1.10.1
* Move ethcore::Error to error_chain (#8386)
* WIP
* Convert Ethcore error to use error_chain
* Use error_chain for ImportError and BlockImportError
* Fix error pattern matches for error_chain in miner
* Implement explicit From for AccountsError
* Fix pattern matches for ErrorKinds
* Handle ethcore error_chain in light client
* Explicitly define Result type to avoid shadowing
* Fix remaining Error pattern matches
* Fix tab space formatting
* Helps if the tests compile
* Fix error chain matching after merge
* remove From::from. (#8390)
* Some tiny modifications.
1. fix some typo in the comment.
2. sort the order of methods in 'impl state::Backend for StateDB`
* Remove the clone of code_cache, as it has been done in clone_basic.
* remove From::from. It seems not necessary.
* Use forked app_dirs crate for reverted Windows dir behavior (#8438)
* Remove unused appdirs dependency in CLI
* Use forked app_dirs crate for reverted Windows dir behavior
* Permission fix (#8441)
* Block reward contract (#8419)
* engine: add block reward contract abi and helper client
* aura: add support for block reward contract
* engine: test block reward contract client
* aura: test block reward contract
* engine + aura: add missing docs
* engine: share SystemCall type alias
* aura: add transition for block reward contract
* engine: fix example block reward contract source link and bytecode
* Improve VM executor stack size estimation rules (#8439)
* Improve VM executor stack size estimation rules
* typo: docs add "(Debug build)" comment
* Fix an off by one typo and set minimal stack size
This avoids the case if `depth_threshold == max_depth`. Usually setting stack size to zero will just rebound it to
platform minimal stack size, but we set it here just in case.
* Use saturating_sub to avoid potential overflow
* Private transactions processing error handling (#8431)
* Integration test for private transaction returned
* Do not interrupt verification in case of errors
* Helpers use specified
* Review comments fixed
* Update Cargo hidapi-rs dependency (#8447)
* Allow 32 bit pipelines to fail (#8454)
* Disable 32bit tragets for gitlab
* Rename linux pipelines
* Update wasmi (#8452)
* Return error in case eth_call returns VM errors (#8448)
* Add VMError generator
* Return executed exceptions in eth_call
* ParityShell::open `Return result` (#8377)
* start
* add error handling for winapi
* fix typo
* fix warnings and windows errors
* formatting
* Address review comments
* fix docker build (#8462)
* Add changelog for 1.9.7 and 1.10.2 (#8460)
* Add changelog for 1.9.7
* Add Changelog for 1.10.2
* Apply proper markdown
* Run a spellchecker :)
* Be pedantic about the 32-bit pipelines :)
* fix typos in vm description comment (#8446)
* Use rename_all for RichBlock and RichHeader serialization (#8471)
* typo: fix a resolved TODO comment
* Use rename_all instead of individual renames
* Don't require write lock when fetching status. (#8481)
* Bump master to 1.12 (#8477)
* Bump master to 1.12
* Bump crates to 1.12
* Bump mac installer version to 1.12
* Update Gitlab scripts
* Fix snap builds (#8483)
* Update hardcodedSync for Ethereum, Kovan, and Ropsten (#8489)
* Update wasmi and pwasm-utils (#8493)
* Update wasmi to 0.2
New wasmi supports 32bit platforms and no longer requires a special feature to build for such platforms.
* Update pwasm-utils to 0.1.5
* Remove three old warp boot nodes. (#8497)
* Return error if RLP size of transaction exceeds the limit (#8473)
* Return error if RLP size of transaction exceeds the limit
* Review comments fixed
* RLP check moved to verifier, corresponding pool test added
* `duration_ns: u64 -> duration: Duration` (#8457)
* duration_ns: u64 -> duration: Duration
* format on millis {:.2} -> {}
* Remove unused dependency `bigint` (#8505)
* remove unused dependency bigint in
* remove bigint in rpc_cli
* Show imported messages for light client (#8517)
* Directly return None if tracing is disabled (#8504)
* Directly return None if tracing is disabled
* Address gumbles: release read locks as fast as possible
* Hardware Wallet trait (#8071)
* getting started with replacing HardwareWalletManager
* trezor and ledger impls the new trait with some drawbacks
* Everything move to the new trait
* It required lifetime annotations in the trait because [u8] in unsized
* Lets now start moving entry point from HardwareWalletManager
* rename trait to Wallet
* move thread management to the actual wallets
* Moved thread management to each respective Wallet
* Cleaned up pub items that is needed to be pub
* Wallet trait more or less finished
* Cleaned up docs
* fix tests
* omit removed docs
* fix spelling, naming och remove old comments
* ledger test is broken, add correct logging format
* So locally on my machine Linux Ubuntu 17.10 the test doesn't panic but on the CI server libusb::Context::new()
fails which I don't understand because it has worked before
* Additionally the ledger test is optional so I lean toward ignoring it the CI Server
* ignore hardware tests by default
* more verbose checking in ledger test
* SecretStore: merge two types of errors into single one + Error::is_non_fatal (#8357)
* SecretStore: error unify initial commit
SecretStore: pass real error in error messages
SecretStore: is_internal_error -> Error::is_non_fatal
warnings
SecretStore: ConsensusTemporaryUnreachable
fix after merge
removed comments
removed comments
SecretStore: updated HTTP error responses
SecretStore: more ConsensusTemporaryUnreachable tests
fix after rebase
* fixed grumbles
* use HashSet in tests
* Enable WebAssembly and Byzantium for Ellaism (#8520)
* Enable WebAssembly and Byzantium for Ellaism
* Fix indentation
* Remove empty lines
* More changes for Android (#8421)
* Transaction Pool improvements (#8470)
* Don't use ethereum_types in transaction pool.
* Hide internal insertion_id.
* Fix tests.
* Review grumbles.
* Fetching logs by hash in blockchain database (#8463)
* Fetch logs by hash in blockchain database
* Fix tests
* Add unit test for branch block logs fetching
* Add docs that blocks must already be sorted
* Handle branch block cases properly
* typo: empty -> is_empty
* Remove return_empty_if_none by using a closure
* Use BTreeSet to avoid sorting again
* Move is_canon to BlockChain
* typo: pass value by reference
* Use loop and wrap inside blocks to simplify the code
Borrowed from https://github.com/paritytech/parity/pull/8463#discussion_r183453326
* typo: missed a comment
* Pass on storage keys tracing to handle the case when it is not modified (#8491)
* Pass on storage keys even if it is not modified
* typo: account and storage query
`to_pod_diff` builds both `touched_addresses` merge and storage keys merge.
* Fix tests
* Use state query directly because of suicided accounts
* Fix a RefCell borrow issue
* Add tests for unmodified storage trace
* Address grumbles
* typo: remove unwanted empty line
* ensure_cached compiles with the original signature
* Don't panic in import_block if invalid rlp (#8522)
* Don't panic in import_block if invalid rlp
* Remove redundant type annotation
* Replace RLP header view usage with safe decoding
Using the view will panic with invalid RLP. Here we use Rlp decoding directly which will return a `Result<_, DecoderError>`. While this path currently should not have any invalid RLP - it makes it safer if ever called with invalid RLP from other code paths.
* Remove expect (#8536)
* Remove expect and propagate rlp::DecoderErrors as TrieErrors
* EIP 145: Bitwise shifting instructions in EVM (#8451)
* Add SHL, SHR, SAR opcodes
* Add have_bitwise_shifting schedule flag
* Add all EIP tests for SHL
* Add SHR implementation and tests
* Implement SAR and add tests
* Add eip145transition config param
* Change map_or to map_or_else when possible
* Consolidate crypto functionality in `ethcore-crypto`. (#8432)
* Consolidate crypto functionality in `ethcore-crypto`.
- Move `ecdh`/`ecies` modules to `ethkey`.
- Refactor `ethcore-crypto` to use file per module.
- Replace `subtle` with `ethcore_crypto::is_equal`.
- Add `aes_gcm` module to `ethcore-crypto`.
* Rename `aes::{encrypt,decrypt,decrypt_cbc}` ...
... to `aes::{encrypt_128_ctr,decrypt_128_ctr,decrypt_128_cbc}`.
* ethcore, rpc, machine: refactor block reward application and tracing (#8490)
* Keep all enacted blocks notify in order (#8524)
* Keep all enacted blocks notify in order
* Collect is unnecessary
* Update ChainNotify to use ChainRouteType
* Fix all ethcore fn defs
* Wrap the type within ChainRoute
* Fix private-tx and sync api
* Fix secret_store API
* Fix updater API
* Fix rpc api
* Fix informant api
* Eagerly cache enacted/retracted and remove contain_enacted/retracted
* Fix indent
* tests: should use full expr form for struct constructor
* Use into_enacted_retracted to further avoid copy
* typo: not a function
* rpc/tests: ChainRoute -> ChainRoute::new
* Node table sorting according to last contact data (#8541)
* network-devp2p: sort nodes in node table using last contact data
* network-devp2p: rename node contact types in node table json output
* network-devp2p: fix node table tests
* network-devp2p: note node failure when failed to establish connection
* network-devp2p: handle UselessPeer error
* network-devp2p: note failure when marking node as useless
* Rlp decode returns Result (#8527)
rlp::decode returns Result
Make a best effort to handle decoding errors gracefully throughout the code, using `expect` where the value is guaranteed to be valid (and in other places where it makes sense).
* Parity as a library (#8412)
* Parity as a library
* Fix concerns
* Allow using a null on_client_restart_cb
* Fix more concerns
* Test the C library in test.sh
* Reduce CMake version to 3.5
* Move the clib test before cargo test
* Add println in test
* Trace precompiled contracts when the transfer value is not zero (#8486)
* Trace precompiled contracts when the transfer value is not zero
* Add tests for precompiled CALL tracing
* Use byzantium test machine for the new test
* Add notes in comments on why we don't trace all precompileds
* Use is_transferred instead of transferred
* Don't block sync when importing old blocks (#8530)
* Alter IO queueing.
* Don't require IoMessages to be Clone
* Ancient blocks imported via IoChannel.
* Get rid of private transactions io message.
* Get rid of deadlock and fix disconnected handler.
* Revert to old disconnect condition.
* Fix tests.
* Fix deadlock.
* Make trace-time publishable. (#8568)
* Remove State::replace_backend (#8569)
* Refactoring `ethcore-sync` - Fixing warp-sync barrier (#8543)
* Start dividing sync chain : first supplier method
* WIP - updated chain sync supplier
* Finish refactoring the Chain Sync Supplier
* Create Chain Sync Requester
* Add Propagator for Chain Sync
* Add the Chain Sync Handler
* Move tests from mod -> handler
* Move tests to propagator
* Refactor SyncRequester arguments
* Refactoring peer fork header handler
* Fix wrong highest block number in snapshot sync
* Small refactor...
* Address PR grumbles
* Retry failed CI job
* Fix tests
* PR Grumbles
* Decoding headers can fail (#8570)
* rlp::decode returns Result
* Fix journaldb to handle rlp::decode Result
* Fix ethcore to work with rlp::decode returning Result
* Light client handles rlp::decode returning Result
* Fix tests in rlp_derive
* Fix tests
* Cleanup
* cleanup
* Allow panic rather than breaking out of iterator
* Let decoding failures when reading from disk blow up
* syntax
* Fix the trivial grumbles
* Fix failing tests
* Make Account::from_rlp return Result
* Syntx, sigh
* Temp-fix for decoding failures
* Header::decode returns Result
Handle new return type throughout the code base.
* Do not continue reading from the DB when a value could not be read
* Fix tests
* Handle header decoding in light_sync
* Handling header decoding errors
* Let the DecodeError bubble up unchanged
* Remove redundant error conversion
* Update CHANGELOG for 1.9, 1.10, and 1.11 (#8556)
* Move changelog for 1.10.x
* Mark 1.9 EOL
* Prepare changelog for 1.10.3 stable
* Prepare changelog for 1.11.0 stable
* Update changelogs
* Update CHANGELOG for 1.10.3 beta
* Update CHANGELOG for 1.11.0 beta
* Update CHANGELOG for 1.11.0 beta
* Update CHANGELOG for 1.11.0 beta
* Format changelog
* Handle socket address parsing errors (#8545)
Unpack errors and check for io::ErrorKind::InvalidInput and return our own AddressParse error. Remove the foreign link to std::net::AddrParseError and add an `impl From` for that error. Test parsing properly.
* Remove unnecessary cloning in overwrite_with (#8580)
* Remove unnecessary cloning in overwrite_with
* Remove into_iter
* changelog nit (#8585)
* Rename `whisper-cli binary` to `whisper` (#8579)
* rename whisper-cli binary to whisper
* fix tests
* Add whisper CLI to the pipelines (#8578)
* Add whisper CLI to the pipelines
* Address todo, ref #8579
* Added Dockerfile for alpine linux by @andresilva, closes#3565 (#8587)
* Changelog and Readme (#8591)
* Move changelog for 1.10.x
* Mark 1.9 EOL
* Prepare changelog for 1.10.3 stable
* Prepare changelog for 1.11.0 stable
* Update changelogs
* Update CHANGELOG for 1.10.3 beta
* Update CHANGELOG for 1.11.0 beta
* Update CHANGELOG for 1.11.0 beta
* Update CHANGELOG for 1.11.0 beta
* Format changelog
* Update README for 1.11
* Fix typo
* Attempt to fix intermittent test failures (#8584)
Occasionally should_return_correct_nonces_when_dropped_because_of_limit fails, possibly because of multiple threads competing to finish. See CI logs here for an example: https://gitlab.parity.io/parity/parity/-/jobs/86738
* Make mio optional in ethcore-io (#8537)
* Make mio optional in ethcore-io
* Add some annotations, plus a check for features
* Increase timer for test
* Fix Parity UI link (#8600)
Fix link https://github.com/paritytech/parity/issues/8599
* fix compiler warning (#8590)
* Block::decode() returns Result (#8586)
* block_header can fail so return Result (#8581)
* block_header can fail so return Result
* Restore previous return type based on feedback
* Fix failing doc tests running on non-code
* Remove inject.js server-side injection for dapps (#8539)
* Remove inject.js server-side injection for dapps
* Remove dapps test `should_inject_js`
Parity doesn't inject a <script> tag inside the responses anymore
* Fix the mio test again (#8602)
* 2 tiny modification on snapshot (#8601)
* Some tiny modifications.
1. fix some typo in the comment.
2. sort the order of methods in 'impl state::Backend for StateDB`
* Remove the clone of code_cache, as it has been done in clone_basic.
* remove From::from. It seems not necessary.
* change mode: remove rust files' executable mode.
* 2 tiny modifications on snapshot.
* Use full qualified syntax for itertools::Itertools::flatten (#8606)
* Fix packet count when talking with PAR2 peers (#8555)
* Support diferent packet counts in different protocol versions.
* Fix light timeouts and eclipse protection.
* Fix devp2p tests.
* Fix whisper-cli compilation.
* Fix compilation.
* Fix ethcore-sync tests.
* Revert "Fix light timeouts and eclipse protection."
This reverts commit 06285ea8c1d9d184d809f64b5507aece633da6cc.
* Increase timeouts.
* typo: wrong indentation in kovan config (#8610)
* Fix account list double 0x display (#8596)
* Remove unused self import
* Fix account list double 0x display
* Remove manually added text to the errors (#8595)
These messages were confusing for the users especially the help message.
* Gitlab test script fixes (#8573)
* Exclude /docs from modified files.
* Ensure all references in the working tree are available
* Remove duplicated line from test script
* Fix BlockReward contract "arithmetic operation overflow" (#8611)
* Fix BlockReward contract "arithmetic operation overflow"
* Add docs on how execute_as_system works
* Fix typo
* ´main.rs´ typo (#8629)
* Typo
* Update main.rs
* Store morden db and keys in "path/to/parity/data/Morden" (ropsten uses "test", like before) (#8621)
* Store morden db and keys in "path/to/parity/data/morden" (ropsten uses "test", like before)
* Fix light sync with initial validator-set contract (#8528)
* Fix#8468
* Use U256::max_value() instead
* Fix again
* Also change initial transaction gas
* Remove NetworkContext::io_channel() (#8625)
* Remove io_channel()
* Fix warning
* Check that the Android build doesn't dep on c++_shared (#8538)
* Fork choice and metadata framework for Engine (#8401)
* Add light client TODO item
* Move existing total-difficulty-based fork choice check to Engine
* Abstract total difficulty and block provider as Machine::BlockMetadata and Machine::BlockProvider
* Decouple "generate_metadata" logic to Engine
* Use fixed BlockMetadata and BlockProvider type for null and instantseal
In this way they can use total difficulty fork choice check
* Extend blockdetails with metadatas and finalized info
* Extra data update: mark_finalized and update_metadatas
* Check finalized block in Blockchain
* Fix a test constructor in verification mod
* Add total difficulty trait
* Fix type import
* Db migration to V13 with metadata column
* Address grumbles
* metadatas -> metadata
* Use generic type for update_metadata to avoid passing HashMap all around
* Remove metadata in blockdetails
* [WIP] Implement a generic metadata architecture
* [WIP] Metadata insertion logic in BlockChain
* typo: Value -> Self::Value
* [WIP] Temporarily remove Engine::is_new_best interface
So that we don't have too many type errors.
* [WIP] Fix more type errors
* [WIP] ExtendedHeader::PartialEq
* [WIP] Change metadata type Option<Vec<u8>> to Vec<u8>
* [WIP] Remove Metadata Error
* [WIP] Clean up error conversion
* [WIP] finalized -> is_finalized
* [WIP] Mark all fields in ExtrasInsert as pub
* [WIP] Remove unused import
* [WIP] Keep only local metadata info
* Mark metadata as optional
* [WIP] Revert metadata db change in BlockChain
* [WIP] Put finalization in unclosed state
* Use metadata interface in BlockDetail
* [WIP] Fix current build failures
* [WIP] Remove unused blockmetadata struct
* Remove DB migration info
* [WIP] Typo
* Use ExtendedHeader to implement fork choice check
* Implement is_new_best using Ancestry iterator
* Use expect instead of panic
* [WIP] Add ancestry Engine support via on_new_block
* Fix tests
* Emission of ancestry actions
* use_short_version should take account of metadata
* Engine::is_new_best -> Engine::fork_choice
* Use proper expect format as defined in #1026
* panic -> expect
* ancestry_header -> ancestry_with_metadata
* Boxed iterator -> &mut iterator
* Fix tests
* is_new_best -> primitive_fork_choice
* Document how fork_choice works
* Engine::fork_choice -> Engine::primitive_fork_choice
* comment: clarify types of finalization where Engine::primitive_fork_choice works
* Expose FinalizationInfo to Engine
* Fix tests due to merging
* Remove TotalDifficulty trait
* Do not pass FinalizationInfo to Engine
If there's finalized blocks in from route, choose the old branch without calling `Engine::fork_choice`.
* Fix compile
* Fix unused import
* Remove is_to_route_finalized
When no block reorg passes a finalized block, this variable is always false.
* Address format grumbles
* Fix docs: mark_finalized returns None if block hash is not found
`blockchain` mod does not yet have an Error type, so we still temporarily use None here.
* Fix inaccurate tree_route None expect description
* typo (#8640)
* Changelog for 1.10.4-stable and 1.11.1-beta (#8637)
* Add changelog for 1.10.4
* Add changelog for 1.11.1
* Fix Typos
* Don't open Browser post-install on Mac (#8641)
Since we start parity with the UI disabled per default now, opening the browser post installation will show an annoying error message, confusing the user. This patch removes opening the browser to prevent that annoyance.
fixes#8194
* Resumable warp-sync / Seed downloaded snapshots (#8544)
* Start dividing sync chain : first supplier method
* WIP - updated chain sync supplier
* Finish refactoring the Chain Sync Supplier
* Create Chain Sync Requester
* Add Propagator for Chain Sync
* Add the Chain Sync Handler
* Move tests from mod -> handler
* Move tests to propagator
* Refactor SyncRequester arguments
* Refactoring peer fork header handler
* Fix wrong highest block number in snapshot sync
* Small refactor...
* Resume warp-sync downloaded chunks
* Add comments
* Refactoring the previous chunks import
* Fix tests
* Address PR grumbles
* Fix not seeding current snapshot
* Address PR Grumbles
* Address PR grumble
* Retry failed CI job
* Update SnapshotService readiness check
Fix restoration locking issue for previous chunks restoration
* Fix tests
* Fix tests
* Fix test
* Early abort importing previous chunks
* PR Grumbles
* Update Gitlab CI config
* SyncState back to Waiting when Manifest peers disconnect
* Move fix
* Better fix
* Revert GitLab CI changes
* Fix Warning
* Refactor resuming snapshots
* Fix string construction
* Revert "Refactor resuming snapshots"
This reverts commit 75fd4b553a38e4a49dc5d6a878c70e830ff382eb.
* Update informant log
* Fix string construction
* Refactor resuming snapshots
* Fix informant
* PR Grumbles
* Update informant message : show chunks done
* PR Grumbles
* Fix
* Fix Warning
* PR Grumbles
* Fix not downloading old blocks (#8642)
* Remove HostInfo::next_nonce (#8644)
* Remove the Keccak C library and use the pure Rust impl (#8657)
* Add license and readme
* Use pure rust implementation
* Bump version to 0.1.1
* Don't use C, prefer the pure Rust implementation
* Add test for `write_keccak`
* Bump version
* Add benchmarks
* Add benchmarks
* Add keccak_256, keccak_512, keccak_256_unchecked and keccak_512_unchecked – mostly for compatibility with ethash
* Remove failed git merge attempt from external git repo
Cargo.lock updates
* whitespace
* Mark unsafe function unsafe
* Unsafe calls in unsafe block
* Document unsafety invariants
* Revert unintended changes to Cargo.lock
* updated tiny-keccak to 1.4.2 (#8669)
* parity: improve cli help and logging (#8665)
* parity: indicate disabling ancient blocks is not recommended
* parity: display decimals for stats in informant
* Refactor EIP150, EIP160 and EIP161 forks to be specified in CommonParams (#8614)
* Allow post-homestead forks to be specified in CommonParams
* Fix all json configs
* Fix test in json crate
* Fix test in ethcore
* Fix all chain configs to use tabs
Given we use tabs in .editorconfig and the majority of chain configs.
This change is done in Emacs using `mark-whole-buffer` and `indent-region`.
* Remove HostInfo::client_version() and secret() (#8677)
* Move connection_filter to the network crate (#8674)
* Remove the error when stopping the network (#8671)
* Allow making direct RPC queries from the C API (#8588)
* Fix cli signer (#8682)
* Update ethereum-types so `{:#x}` applies 0x prefix
* Fix tx permission tests
* Use impl Future in the light client RPC helpers (#8628)
* Update mod.rs (#8695)
- Update interfaces affected by unsafe-expose
- replace `{{ }}` as this throws an error in Jekyll (wiki)
* remove empty file (#8705)
* Set the request index to that of the current request (#8683)
* Set the request index to that of the current request
When setting up the chain of (two) requests to look up a block by hash, the second need to refer to the first. This fixes an issue where the back ref was set to the subsequent request, not the current one. When the requests are executed we loop through them in order and ensure the requests that should produce headers all match up. We do this by index so they better be right.
In other words: off by one.
* parity: trim whitespace when parsing duration strings (#8692)
* Implement recursive Debug for Nodes in patrica_trie::TrieDB (#8697)
fixes#8184
* Remove unused imports (#8722)
* Update dev chain (#8717)
* Make dev chain more foundation-like and enable wasm.
* Fix compilation warnings.
* Add a test for decoding corrupt data (#8713)
* Fix compilation error on nightly rust (#8707)
On nightly rust passing `public_url` works but that breaks on stable. This works for both.
* network-devp2p: handle UselessPeer disconnect (#8686)
* Shutdown the Snapshot Service early (#8658)
* Shutdown the Snapshot Service when shutting down the runner
* Rename `service` to `client_service`
* Fix tests
* Fix local transactions policy. (#8691)
* Add a deadlock detection thread (#8727)
* Add a deadlock detection thread
Expose it under a feature flag:
`cargo build --features "deadlock_detection"`
* Address Nicklas's comments
* Remove unused function new_pow_test_spec (#8735)
* Add 'interface' option to cli (#8699)
Additionally as to the port, the new command line option
now allows the user to specify the network interface the P2P-Parity
listens, too. With support for 'all' and 'local' like in all other
versions of this flag. Default is 'all' (aka ).
* Fix some nits using clippy (#8731)
* fix some nits using clippy
* fix tests
* Remove a couple of unnecessary `transmute()` (#8736)
* bump tinykeccak to 1.4 (#8728)
* ease tiny-keccak version requirements (1.4.1 -> 1.4) (#8726)
* Remove -k/--insecure option from curl installer (#8719)
Piping `curl` to `bash` while **disabling** certificate verification can lead to security problems.
* Fix PoW blockchains sealing notifications in chain_new_blocks (#8656)
* Print warnings when fetching pending blocks (#8711)
* Lots of println to figure out what eth_getBlockByNumber does/should do
* Remove debugging
* Print warnings when fetching pending blocks
When calling `eth_getBlockByNumber` with `pending`, we now print a deprecation warning and:
* if a pending block is found, use it to respond
* if no pending block is found, respond as if if was a request for `Latest`
Addresses issue #8703 (not sure if it's enough to close it tbh)
* Fix XOR distance calculation in discovery Kademlia impl (#8589)
* network-devp2p: Test for discovery bucket insertion.
All test values are randomly generated and the assertions are checked manually.
Test fails because distance metric is implemented incorrectly.
* network-devp2p: Fix discovery distance function.
The Kademlia distance function (XOR) was implemented incorrectly as a population count.
* network-devp2p: Refactor nearest_node_entries to be on instance.
Optimizations are possible with more access to the discovery state.
* network-devp2p: Fix loss of precision in nearest_node_entries.
* network-devp2p: More efficient nearest node search.
The discovery algorithm to identify the nearest k nodes does not need to scan
all entries in all buckets.
* Remove NetworkService::config() (#8653)
* CI: Fixes for Android Pipeline (#8745)
* ci: Remove check for shared libraries in gitlab script
* ci: allow android arm build to fail
* Custom Error Messages on ENFILE and EMFILE IO Errors (#8744)
* Custom Error Messages on ENFILE and EMFILE IO Errors
Add custom mapping of ENFILE and EMFILE IO Errors (Failure because of missing system resource) right when chaining ioError into ::util::Network::Error to improve Error Messages given to user
Note: Adds libc as a dependency to util/network
* Use assert-matches for more readable tests
* Fix Wording and consistency
* Unordered iterator.
* Use unordered and limited set if full not required.
* Split timeout work into smaller timers.
* Avoid collecting all pending transactions when mining
* Remove println.
* Use priority ordering in eth-filter.
* Fix ethcore-miner tests and tx propagation.
* Review grumbles addressed.
* Add test for unordered not populating the cache.
* Fix ethcore tests.
* Fix light tests.
* Fix ethcore-sync tests.
* Fix RPC tests.
* Use sealing.enabled to emit eth_mining information
* Be more accurate on last_requests by using Option
* Add tests for internal sealing
* Add test for pow non-mining
* Add test for mining pow
* Revert "Fix not downloading old blocks (#8642)"
This reverts commit d1934363e7.
* Make sure only one thread actually imports old blocks.
* Add some trace timers.
* Bring back pending hashes set.
* Separate locks so that queue can happen while we are importing.
* Address grumbles.
* Mark test helpers and test-only specs as cfg(test)
* Use test-probe to conditionally compile test helpers
* Remove test probe and directly use features tag
* Update `add_license` script
* run script
* add `remove duplicate lines script` and run it
* Revert changes `English spaces`
* strip whitespaces
* Revert `GPL` in files with `apache/mit license`
* don't append `gpl license` in files with other lic
* Don't append `gpl header` in files with other lic.
* re-ran script
* include c and cpp files too
* remove duplicate header
* rebase nit