* expand parameters for pending_transactions()
* move ready_transactions content into filtered method
* apply filter based on tx_hash, sender or receiver
* call filtered transactions from RPC interface
* attempt at testing...
* replace parameters with _ on light client
* addes some comments
* removed uncompleted tests in miner.rs
* attempt at testing, needs more work...
* Formatting for ready_transactions_filtered
Co-Authored-By: Tomasz Drwięga <tomusdrw@users.noreply.github.com>
* Use map_or instead of if-let
Co-Authored-By: Tomasz Drwięga <tomusdrw@users.noreply.github.com>
* additional map_or replacement
* change receiver type to Option<Option<Address>>
* remove faulty MiningService tests, test RPC later
* remove tx hash from pending transaction filtering
* as_unsigned() method for SignedTransaction
* implement Deserialize for FilterOptions
* implement Validate for MapAccess type
* additional formatting
* directly name cover in pattern matching
* test valid vull deserialization
* test valid sender operators
* test valid receiver operators
* test valid gas operators
* test valid gas price operators
* test valid value operators
* test valid nonce operators
* additional tsets for defaults, unknown filter types, unknown operators and some renames
* move filter_options to ethcore to avoid package cycling
* adjusted function/method parameters for FilterOptions
* implement filter for sender and receiver
* implement filter for gas
* implement filter for gas price, tx value and nonce
* improve filtering implementation; use common function, use combinators
* improved documentation for FilterOptions
* small documentation adjustments
* remove warnings
* replace FilterOperator::ContractCreation with FilterOperator::Eq(None)
* implement validate_receiver
* make small changes like renames, preamble
* cleanup code according to suggestions, add docs
* small improvements like formatting and newline
* Stop breaking out of loop if a non-canonical hash is found
* include expected hash in log msg
* More logging
* Scope
* Syntax
* Log in blank RollingFinality
Escalate bad proposer to warning
* Check validator set size: warn if 1 or even number
* More readable code
* Use SimpleList::new
* Extensive logging on unexpected non-canonical hash
* Wording
* wip
* Update ethcore/blockchain/src/blockchain.rs
Co-Authored-By: Tomasz Drwięga <tomusdrw@users.noreply.github.com>
* Improved logging, address grumbles
* Update ethcore/src/engines/validator_set/simple_list.rs
Co-Authored-By: Luke Schoen <ltfschoen@users.noreply.github.com>
* Report benign misbehaviour iff currently a validator
* Report malicious behaviour iff we're a validator
* Escalate to warning and fix wording
* Test reporting behaviour
Don't require node to be part of the validator set to report malicious behaviour
* Include missing parent hash in MissingParent error
* Update ethcore/src/engines/validator_set/simple_list.rs
Co-Authored-By: Luke Schoen <ltfschoen@users.noreply.github.com>
* cleanup
* On second thought non-validators are allowed to report
* cleanup
* remove dead code
* docs: Update Readme with TOC, Contributor Guide and License sections
* docs: Simplify package descriptions in Readme
* docs: Fix typos
* docs: Update Cargo package configs adding missing descriptions
* fix: Remove machine since was accidental from diff branch. Fix contribting indentation.
* fix: Fix formatting
* remove details snippet since not code and formats badly
* review-fix: Remove duplicate description
* fix dot point formatting
* fix: Add missing description to vm package
* fix: Remove duplicate Code of Conduct and Contributor guidelines
* docs: Update Contributing for consistency with other repos
* docs: Update Readme to link to existing Code of Conduct and Contributor guidelines in .github folder
* refactor: Add missing space
* fix: Fix links to be markdown format
* review-fix: Update CONTRIBUTING.md to link to Parity Ethereum Style Guide
* docs: Fix type in .github/CONTRIBUTING.md
Co-Authored-By: David <dvdplm@gmail.com>
* docs: Fix typo in .github/CONTRIBUTING.md
Co-Authored-By: David <dvdplm@gmail.com>
* docs: Rephrase parity-clib/Cargo.toml
Co-Authored-By: David <dvdplm@gmail.com>
* review-fix: Fix whole paragraph
* review-fix: Add comment to prevent direct pushes to master branch
* review-fix: Change some rules to recommendations
* Update .github/CONTRIBUTING.md
Co-Authored-By: Tomasz Drwięga <tomusdrw@users.noreply.github.com>
* review-fix: Replace feature reduction with breaking changes dot point
* review-fix: Rephrase what to do when reviewing PR
* review-fix: Update parity-rpc package description and module rustdocs
* docs: Add missing fullstop
* review-fix: Update rustdoc section to show all packages first as default
* review-fix: Rename Parity Util to Parity Core Libraries
* review-fix: Rename readme too for the C bindings name change
* review-fix: Remove some docs since we do not teach the reader Rust
* review-fix: Wrap Parity Ethereum specific packages in a details section
* review-fix: Separate tools that are in this repo vs those that are not
* review-fix: Add link to ethabi on crates.io
* review-fix: Remove unnecessary extra line talking about pushing to master
* review-fix: Remove useless summary of parts of the rust book documentation section
* docs: Update .github/CONTRIBUTING.md to specify two reviewers required
Co-Authored-By: David <dvdplm@gmail.com>
* docs: Update README.md with simplification
Co-Authored-By: David <dvdplm@gmail.com>
* docs: Update README.md renaming to Test Runner instead of just Run
Co-Authored-By: David <dvdplm@gmail.com>
* review-fix: Remove hardware wallet from docs
* review-fix: Remove veto PR section of contributor doc
* review-fix: Change to test generator title
* Stop breaking out of loop if a non-canonical hash is found
* include expected hash in log msg
* More logging
* Scope
* Syntax
* Log in blank RollingFinality
Escalate bad proposer to warning
* Check validator set size: warn if 1 or even number
* More readable code
* Use SimpleList::new
* Extensive logging on unexpected non-canonical hash
* Wording
* Update ethcore/blockchain/src/blockchain.rs
Co-Authored-By: Tomasz Drwięga <tomusdrw@users.noreply.github.com>
* Improved logging, address grumbles
* Update ethcore/src/engines/validator_set/simple_list.rs
Co-Authored-By: Luke Schoen <ltfschoen@users.noreply.github.com>
This commit does the following:
- Prevent overflow in `verify_timestamp()` by not adding `now` to found faulty timestamp
- Use explicit `CheckedSystemTime::checked_add` to prevent potential consensus issues because SystemTime is platform
depedent
- remove `#[cfg(not(time_checked_add))]` conditional compilation
* Add a way to signal shutdown to snapshotting threads
* Pass Progress to fat_rlps() so we can abort from there too.
* Checking for abort in a single spot
* Remove nightly-only weak/strong counts
* fix warning
* Fix tests
* Add dummy impl to abort snapshots
* Add another dummy impl for TestSnapshotService
* Remove debugging code
* Return error instead of the odd Ok(())
Switch to AtomicU64
* Use fewer threads for snapshotting
When taking a snapshot the current default number of threads is equal to half the number of **logical** CPUs in the system. On HT enabled CPUs this value seems a bit high, e.g. 6 snapshotting threads on a 6/12 core/hyperthread CPU. Maybe a better default value is half the number of physical cores?
* fix test
* Replace error chain for network error
* Fix usages and add manual From impls
* OnDemand Error and remove remaining dependencies
* Die error_chain, die.
* DIE
* Hasta la vista, baby
* Stop breaking out of loop if a non-canonical hash is found
* include expected hash in log msg
* More logging
* Scope
* Syntax
* Log in blank RollingFinality
Escalate bad proposer to warning
* More readable code
* Extensive logging on unexpected non-canonical hash
* Wording
* Use Drop to shutdown stepper thread
Make period == 0 an error and remove the Option from step_service
* Remove StepService
Remove StepService and spawn the stepping thread in `Clique::new()`. Don't store the thread handle and instead trust the `AtomicBool` to signal shutdown time.
Don't check for `period > 0`: we assume a valid chainspec file.
* Don't shutdown the stepper thread at all, just let it run until exit
Also: fix a few warnings and tests
* Put kvdb_memorydb back
* Warn&exit when engine is dropped
Don't sleep too long!
* Don't delay stepping thread
* Better formatting
* [whisper] Move needed aes_gcm crypto in-crate
In the latest `parity-crypto` release (upcoming 0.4), the aes GCM features were removed (done to remove the dependency on `ring`).
This PR adds the bare minimum crypto needed for Whisper directly to the crate itself and as those were the only features needed from `parity-crypto`, removes the dependency on that crate altogether.
* Upgrade to parity-crypto 0.4
Reverts using NonZeroU32 (introduced [here](b347599cf7)).
* Check for 0 in `args.arg_keys_iteration`
* Use beta.4
* parity-crypto 0.4.0 is released
* Remove annoying compiler warnings
* Fix compiler warning (that will become an error)
Fixes https://github.com/paritytech/parity-ethereum/issues/10648
I'm not sure this fix is Good™ but rustc seems happy enough.
There's a deeper issue which may or may not be related to this: the Engine is not shutdown properly and the `StepService` thread keeps running indefinitely after Ctrl-C (so `update_sealing()` is called repeatedly for 300sec). I don't think this is related to Clique as I've seen this happen on mainnet as well, but I wonder if the effects of it are worse for a PoA network where the node can create new blocks all on its own?
* Use saturating_sub
* WIP
* Fix warning, second attempt
The idea here is to avoid using `Arc::get_mut()` (which does not work: fails every time here) and instead trust `drop()` to do the right thing.
This is a conservative change. I think this can be reformed further, e.g. by `impl Drop for StepService` and halt the thread there, or even skip `join()`ing the thread entirely and trust the `AtomicBool` to signal shutdown. I also have doubts abut the `Option<StepService>`: seems a bit much to have an `Option` there and it makes things cumbersome.
* Don't panic if extra_data is longer than VANITY_LENGTH
Seems like `extra_data().len()` can be longer than 32 (was 39 here) so this fixes that panic.
* Update ethcore/src/engines/clique/mod.rs
* Journal for private txs added
* Tests after adding logging to private tx fixed
* Logs getter and tests added
* Time and amount limit for logs added
* RPC method for log retrieving added
* Correct path name and time validation implemented
* References for parameters added, redundant cloning reworked
* References for parameters added, redundant cloning reworked
* Work with json moved to the separate struct
* Serialization test added
* Fixed build after the merge with head
* Documentation for methods fixed, redundant field removed
* Fixed error usages
* Timestamp trait implemented for std struct
* Commented code removed
* Remove timestamp source, rework serialization test
* u64 replaced with SystemTime
* Path made mandatory for logging
* Source of monotonic time added
* into_system_time method renamed
* Initialize time source by max from current system time and max creation time from already saved logs
* Redundant conversions removed, code a little bit reworked according to review comments
* One more redundant conversion removed, rpc call simplified
* Constantinople HF on POA Core
Plan Constantinople/St.Petersfork HF on POA Core network at block 8582254.
Original PR in POA repository: https://github.com/poanetwork/poa-chain-spec/pull/110
* Remove extra empty line