Commit Graph

11729 Commits

Author SHA1 Message Date
Wei Tang
ac3a706f0d Preserve the current abort behavior (#8995) 2018-06-27 22:31:20 +02:00
Jim Posen
9b5483a71b Improve should_replace on NonceAndGasPrice (#8980)
* Additional tests for NonceAndGasPrice::should_replace.

* Fix should_replace in the distinct sender case.

* Use natural priority ordering to simplify should_replace.
2018-06-27 15:59:36 -04:00
David
38c31c880f Tentative fix for missing dependency error (#8973)
* Tentative fix for missing dependency error

* Better fix

* Ignore build artifacts from parit-clib
2018-06-27 20:25:49 +02:00
Wei Tang
0bed5976e3 Refactor evm Instruction to be a c-like enum (#8914)
* Add a basic instruction c-like enum

* Fix all compiling errors

* Fix tests

* Access instruction info as a Instruction impl

* Use macro to avoid duplication in from_u8

* Use single space instead of multiple tabs to avoid formatting issue

* Fix evmbin compile

* typo: indentation

* Use if let to remove an expect

* Address grumbles
2018-06-27 13:33:32 +02:00
Tomasz Drwięga
19a6725430 Fix deadlock in blockchain. (#8977) 2018-06-26 20:49:06 +02:00
Afri Schoedon
48a54efcb2 snap: downgrade rust to revision 1.26.2, ref snapcraft/+bug/1778530 (#8984)
* snap: downgrade rust to revision 1.26.2, ref snapcraft/+bug/1778530

* snap: use plugin rust
2018-06-26 19:17:14 +02:00
Wei Tang
c0b0dc5219 Use local parity-dapps-glue instead of crate published at crates.io (#8983)
* Use local parity-dapps-glue instead of crate published at crates.io

* Disable panic=abort and enable lto optimization
2018-06-26 17:37:51 +02:00
Afri Schoedon
683a26c830 parity: omit redundant last imported block number in light sync informant (#8962) 2018-06-26 11:31:22 +02:00
Niklas Adolfsson
1a16f335fa Disable hardware-wallets on platforms that don't support libusb (#8464)
* 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
2018-06-26 09:03:38 +02:00
David
4145be863b Bump error-chain and quick_error versions (#8972)
* Update error-chain to 0.12 to silence warnings

* Bump quick_error crate to 1.2.2  to silence linter warnings
2018-06-25 14:20:44 +02:00
Wei Tang
e9f1b38984 EVM benchmark utilities (#8944)
* 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
2018-06-25 11:21:45 +02:00
Afri Schoedon
edd90f153c
parity: hide legacy options from cli --help (#8967)
* parity: hide legacy options from cli --help

* parity: run a spellchecker over --help

* parity: fix casing in cli usage
2018-06-25 10:19:29 +02:00
Afri Schoedon
dec390a89f scripts: fix docker build tag on latest using master (#8952) 2018-06-22 18:48:36 +03:00
Toralf Wittner
41348dead4 Add type for passwords. (#8920)
* Add type for passwords.

* Fix test.

* Simplify `Drop` impls of `Password` and `Memzero`.

* Spaces to tabs.

* Custom `Drop` impl for `Password`.
2018-06-22 15:09:15 +02:00
Afri Schoedon
c473ab97c7 deps: bump fs-swap (#8953) 2018-06-22 12:57:59 +01:00
Niklas Adolfsson
0cd1de769b Eliminate some more transmute() (#8879)
* eliminate some more transmute()

* Address `review comments`

* Make unsafe block smaller
* Use different byte-order than `std`, read words as big endian instead
of little endian!

* Fix IpAddresses nits

* Use `from_be` to work both for big and little endian
* Ipv6 addresses were incorrectly `transmuted`

* remove needless lifetime annotation
2018-06-22 12:51:53 +01:00
Wei Tang
5ae8e8a9ca Restrict vault.json permssion to owner and using random suffix for temp vault.json file (#8932)
* Move dedup retry logic to a separate function

* Use random suffix temp vault filename and restrict permissions to owner
2018-06-22 12:30:48 +01:00
Svyatoslav Nikolsky
796d72f48e print SS.self_public when starting SS node (#8949) 2018-06-22 12:50:06 +02:00
Afri Schoedon
86a8584252
scripts: minor improvements (#8930)
* CI: enable 'latest' docker tag on master pipeline

* CI: mark both beta and stable as stable snap.

* CI: sign all windows binaries
2018-06-22 11:56:06 +02:00
André Silva
6509e90c36 rpc: cap gas limit of local calls (#8943) 2018-06-22 11:12:57 +02:00
Afri Schoedon
09ecd0c583
docs: update changelogs (#8931)
* docs: add changelog for 1.10.7

* docs: add changelog for 1.11.4
2018-06-22 11:06:31 +02:00
André Silva
a6d6adc57f ethcore: fix compilation when using slow-blocks or evm-debug features (#8936)
* ethcore: fix compilation when slow-blocks feature is enabled

* ethcore: fix compilation when evm-debug feature is enabled
2018-06-22 11:00:19 +02:00
Svyatoslav Nikolsky
6be5744be4 fixed blooms dir creation (#8941) 2018-06-22 10:52:01 +02:00
Thibaut S
31b4437b93 Update hardcoded headers (#8925)
* Update kovan.json

Update Kovan to block 7693549

* Update foundation.json

Updated to block #5812225

* Update ropsten.json

Update to 3465217

* Update ropsten.json

use tabs

* Update foundation.json

use tabs

* Update kovan.json

use tabs
2018-06-22 10:49:10 +02:00
Marek Kotewicz
458afcd230 new blooms database (#8712)
* 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
2018-06-20 15:13:07 +02:00
André Silva
cf5ae81ced ethstore: retry deduplication of wallet file names until success (#8910) 2018-06-20 17:30:41 +08:00
Thibaut S
08e46432c5 Update ropsten.json (#8926) 2018-06-20 08:49:26 +02:00
Jim Posen
6f11621734 Include node identity in the P2P advertised client version. (#8830) 2018-06-18 15:50:17 +02:00
Max Kaye
6004c394d6 Allow disabling local-by-default for transactions with new config entry (#8882)
* 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
2018-06-18 15:32:18 +02:00
Benjamin Kampmann
609d83f92c Allow Poll Lifetime to be configured via CLI (#8885)
... rather than it being a hard-coded constant. fixes #5484 .
2018-06-18 13:42:54 +02:00
Marek Kotewicz
4ef71f8a82 cleanup nibbleslice (#8915) 2018-06-18 12:13:11 +02:00
Niklas Adolfsson
b47218521f Hardware-wallets Clean up things I missed in the latest PR (#8890)
* Clean up things that I missed

* Address grumbles

* &Arc<Manager> -> &Manager
* Rustdoc -> Crate doc
2018-06-18 11:55:23 +02:00
Afri Schoedon
c9cee8fd52
Remove debian/.deb and centos/.rpm packaging scripts (#8887)
* scripts: remove rpm packages

* scripts: remove deb packages

* scripts: remove unused zip archives

* scripts: remove unused ssl references

* scripts: remove debian and centos pipelines

* scripts: rename ubuntu to generic linux

* scripts: restore archives used in gitlab artifacts

* scripts: init submodules for full test suite

* scripts: do not publish master builds, only nightly, stable, beta
2018-06-18 11:49:15 +02:00
Wei Tang
75e779029f Remove a weird emoji in new_social docs (#8913) 2018-06-18 11:11:41 +02:00
André Silva
3016d54f13 Minor fix in chain supplier and light provider (#8906)
* fix chain supplier increment

* fix light provider block_headers
2018-06-15 17:30:34 +02:00
David
05e7c133fb Block 0 is valid in queries (#8891)
Early exit for block nr 0 leads to spurious error about pruning: `…your node is running with state pruning…`.

Fixes #7547, #8762
2018-06-14 19:56:27 +01:00
Marek Kotewicz
fd57100190 fixed osx permissions (#8901) 2018-06-14 22:17:40 +08:00
Wei Tang
fc86b1799a Atomic create new files with permissions to owner in ethstore (#8896)
* Atomic create new files with permissions to owner in ethstore

* Allow replacing existing files

We have two behaviors for `insert_with_filename` depending on whether `dedup` is true.  Add
`replace_file_with_permissions_to_owner` which use `OpenOptions::create(true)` instead of `create_new`.
2018-06-14 13:54:12 +02:00
Anthony
9546e0c8c2 Add ETC Cooperative-run load balanced parity node (#8892) 2018-06-14 13:47:19 +02:00
Maciej Hirsz
4fe6c148ef
Add support for --chain tobalaba (#8870)
* Add support for --chain tobalaba
2018-06-14 11:03:22 +02:00
Niklas Adolfsson
9e872788c7 fix some warns on nightly (#8889) 2018-06-14 10:58:46 +02:00
David Dorgan
da95f77996 Add new ovh bootnodes and fix port for foundation bootnode 3.2 (#8886)
* Add new ovh bootnodes and fix port for foundation bootnode 3.2

* Remove old bootnodes.

* Remove duplicate 1118980bf48b0a3640bdba04e0fe78b1add18e1cd99bf22d53daac1fd9972ad650df52176e7c7d89d1114cfef2bc23a2959aa54998a46afcf7d91809f0855082
2018-06-14 10:46:00 +02:00
Svyatoslav Nikolsky
6f758bc7b1
SecretStore: service pack 1 (#8435)
* 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

* SecretStore: unified SS contract config options && read

* SecretStore: service pack

SecretStore: service pack (continue)

* fixed grumbles
2018-06-14 10:01:52 +03:00
Wei Tang
b37b3cd1fc Handle removed logs in filter changes and add geth compatibility field (#8796)
* Add removed geth compatibility field in log

* Fix mocked tests

* Add field block hash in PollFilter

* Store last block hash info for log filters

* Implement canon route

* Use canon logs for fetching reorg logs

Light client removed logs fetching is disabled. It looks expensive.

* Make sure removed flag is set

* Address grumbles
2018-06-13 13:39:27 +02:00
Marek Kotewicz
e81069ab3d
fixed ipc leak, closes #8774 (#8876) 2018-06-13 13:02:16 +02:00
Afri Schoedon
bf25f17880
scripts: remove md5 checksums (#8884) 2018-06-13 11:26:35 +02:00
Niklas Adolfsson
6201532c64 hardware_wallet/Ledger Sign messages + some refactoring (#8868)
* 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
2018-06-13 11:01:56 +02:00
Wei Tang
3094ae9df9 Check whether we need resealing in miner and unwrap has_account in account_provider (#8853)
* 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
2018-06-13 09:58:52 +02:00
André Silva
59f6931e06 docker: Fix alpine build (#8878)
- Switch to alpine edge for recent rustc version
- Remove openssl libs
- Add perl (needed for building ring)
2018-06-13 09:29:23 +02:00
Andrew Jones
95a601d053 Remove mac os installers etc (#8875) 2018-06-13 09:15:40 +02:00