Skip to content
This repository was archived by the owner on Nov 6, 2020. It is now read-only.

Commit 3b9b1a8

Browse files
authored
Backports for Beta 2.3.3 (#10333)
* version: bump beta to 2.3.3 * import rpc transactions sequentially (#10051) * import rpc transactions sequentially * use impl trait in argument position, renamed ProspectiveDispatcher to WithPostSign * grouped imports * integrates PostSign with ProspectiveSigner * fix spaces, removed unnecessary type cast and duplicate polling * clean up code style * Apply suggestions from code review * Fix Windows build (#10284) * Don't run the CPP example on CI (#10285) * Don't run the CPP example on CI * Add comment * CI optimizations (#10297) * CI optimizations * fix stripping * new dockerfile * no need n submodule upd * review * moved dockerfile * it becomes large * onchain update depends on s3 * fix dependency * fix cache status * fix cache status * new cache status * fix publish job (#10317) * fix publish job * dashes and colonels * Add Statetest support for Constantinople Fix (#10323) * Update Ethereum tests repo to v6.0.0-beta.3 tag * Add spec for St.Peter's / ConstantinopleFix statetests * Properly handle check_epoch_end_signal errors (#10015) * 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 * cargo: fix compilation * fix(add helper for timestamp overflows) (#10330) * fix(add helper timestamp overflows) * fix(simplify code) * fix(make helper private) * Remove CallContract and RegistryInfo re-exports from `ethcore/client` (#10205) * Remove re-export of `CallContract` and `RegistryInfo` from `ethcore/client` * Remove CallContract and RegistryInfo re-exports again This was missed while fixing merge conflicts * fix(docker): fix not receives SIGINT (#10059) * fix(docker): fix not receives SIGINT * fix: update with reviews * update with review * update * update * snap: official image / test (#10168) * official image / test * fix / test * bit more necromancy * fix paths * add source bin/df /test * add source bin/df /test2 * something w paths /test * something w paths /test * add source-type /test * show paths /test * copy plugin /test * plugin -> nil * install rhash * no questions while installing rhash * publish snap only for release * Don't add discovery initiators to the node table (#10305) * Don't add discovery initiators to the node table * Use enums for tracking state of the nodes in discovery * Dont try to ping ourselves * Fix minor nits * Update timeouts when observing an outdated node * Extracted update_bucket_record from update_node * Fixed typo * Fix two final nits from @todr * Extract CallContract and RegistryInfo traits into their own crate (#10178) * Create call-contract crate * Add license * First attempt at using extracted CallContract trait * Remove unneeded `extern crate` calls * Move RegistryInfo trait into call-contract crate * Move service-transaction-checker from ethcore to ethcore-miner * Update Cargo.lock file * Re-export call_contract * Merge CallContract and RegistryInfo imports * Remove commented code * Add documentation to call_contract crate * Add TODO for removal of re-exports * Update call-contract crate description Co-Authored-By: HCastano <HCastano@users.noreply.github.com> * Rename call-contract crate to ethcore-call-contract * Remove CallContract and RegistryInfo re-exports from `ethcore/client` (#10205) * Remove re-export of `CallContract` and `RegistryInfo` from `ethcore/client` * Remove CallContract and RegistryInfo re-exports again This was missed while fixing merge conflicts * fixed: types::transaction::SignedTransaction; (#10229) * fix daemonize dependency * fix build * change docker image based on debian instead of ubuntu due to the chan… (#10336) * change docker image based on debian instead of ubuntu due to the changes of the build container * role back docker build image and docker deploy image to ubuntu:xenial based (#10338) * perform stripping during build (#10208) * perform stripping during build (#10208) * perform stripping during build * var RUSTFLAGS
1 parent a6c4b17 commit 3b9b1a8

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

60 files changed

+690
-303
lines changed

.gitlab-ci.yml

Lines changed: 66 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,14 @@ stages:
22
- test
33
- build
44
- publish
5+
- publish-onchain
56
- optional
67

78
image: parity/rust:gitlab-ci
89

910
variables:
11+
GIT_STRATEGY: fetch
12+
GIT_SUBMODULE_STRATEGY: recursive
1013
CI_SERVER_NAME: "GitLab CI"
1114
CARGO_HOME: "${CI_PROJECT_DIR}/.cargo"
1215
CARGO_TARGET: x86_64-unknown-linux-gnu
@@ -40,25 +43,29 @@ test-linux:
4043
variables:
4144
RUN_TESTS: all
4245
script:
43-
- scripts/gitlab/test-all.sh stable
46+
- scripts/gitlab/test-all.sh
47+
- sccache -s
4448
tags:
45-
- rust-stable
49+
- linux-docker
4650

4751
test-audit:
4852
stage: test
4953
script:
50-
- scripts/gitlab/cargo-audit.sh
54+
- set -e
55+
- set -u
56+
- cargo audit
5157
tags:
52-
- rust-stable
58+
- linux-docker
5359

5460
build-linux:
5561
stage: build
5662
only: *releaseable_branches
5763
script:
5864
- scripts/gitlab/build-unix.sh
65+
- sccache -s
5966
<<: *collect_artifacts
6067
tags:
61-
- rust-stable
68+
- linux-docker
6269

6370
build-darwin:
6471
stage: build
@@ -96,9 +103,9 @@ publish-docker:
96103
- scripts/gitlab/publish-docker.sh parity
97104

98105
publish-snap:
99-
stage: publish
106+
stage: optional #publish
100107
only: *releaseable_branches
101-
image: parity/snapcraft:gitlab-ci
108+
image: snapcore/snapcraft
102109
variables:
103110
BUILD_ARCH: amd64
104111
cache: {}
@@ -112,19 +119,66 @@ publish-snap:
112119
allow_failure: true
113120
<<: *collect_artifacts
114121

115-
publish-awss3:
116-
stage: publish
122+
publish-onnet-update:
123+
stage: publish-onchain
117124
only: *releaseable_branches
118-
cache: {}
125+
cache: {}
119126
dependencies:
120127
- build-linux
121128
- build-darwin
122129
- build-windows
130+
- publish-awss3-release
123131
before_script: *determine_version
124132
script:
125-
- scripts/gitlab/publish-awss3.sh
133+
- scripts/gitlab/publish-onnet-update.sh
126134
tags:
127-
- shell
135+
- linux-docker
136+
137+
# configures aws for fast uploads/syncs
138+
.s3-before-script: &s3-before-script
139+
before_script:
140+
- mkdir -p ${HOME}/.aws
141+
- |
142+
cat > ${HOME}/.aws/config <<EOC
143+
[default]
144+
s3 =
145+
max_concurrent_requests = 20
146+
max_queue_size = 10000
147+
multipart_threshold = 64MB
148+
multipart_chunksize = 16MB
149+
max_bandwidth = 50MB/s
150+
use_accelerate_endpoint = false
151+
addressing_style = path
152+
EOC
153+
154+
publish-awss3-release:
155+
image: parity/awscli:latest
156+
stage: publish
157+
only: *releaseable_branches
158+
cache: {}
159+
dependencies:
160+
- build-linux
161+
- build-darwin
162+
- build-windows
163+
variables:
164+
GIT_STRATEGY: none
165+
<<: *s3-before-script
166+
script:
167+
- echo "__________Push binaries to AWS S3____________"
168+
- case "${SCHEDULE_TAG:-${CI_COMMIT_REF_NAME}}" in
169+
(beta|stable|nightly)
170+
export BUCKET=releases.parity.io/ethereum;
171+
;;
172+
(*)
173+
export BUCKET=builds-parity;
174+
;;
175+
esac
176+
- aws s3 sync ./artifacts s3://${BUCKET}/${SCHEDULE_TAG:-${CI_COMMIT_REF_NAME}}/
177+
after_script:
178+
- aws s3 ls s3://${BUCKET}/${SCHEDULE_TAG:-${CI_COMMIT_REF_NAME}}/
179+
--recursive --human-readable --summarize
180+
tags:
181+
- linux-docker
128182

129183
publish-docs:
130184
stage: publish
@@ -150,22 +204,3 @@ build-android:
150204
allow_failure: true
151205
<<: *collect_artifacts
152206

153-
test-beta:
154-
stage: optional
155-
variables:
156-
RUN_TESTS: cargo
157-
script:
158-
- scripts/gitlab/test-all.sh beta
159-
tags:
160-
- rust-beta
161-
allow_failure: true
162-
163-
test-nightly:
164-
stage: optional
165-
variables:
166-
RUN_TESTS: all
167-
script:
168-
- scripts/gitlab/test-all.sh nightly
169-
tags:
170-
- rust-nightly
171-
allow_failure: true

Cargo.lock

Lines changed: 25 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
description = "Parity Ethereum client"
33
name = "parity-ethereum"
44
# NOTE Make sure to update util/version/Cargo.toml as well
5-
version = "2.3.2"
5+
version = "2.3.3"
66
license = "GPL-3.0"
77
authors = ["Parity Technologies <admin@parity.io>"]
88

@@ -34,6 +34,7 @@ ethcore = { path = "ethcore", features = ["parity"] }
3434
parity-bytes = "0.1"
3535
common-types = { path = "ethcore/types" }
3636
ethcore-blockchain = { path = "ethcore/blockchain" }
37+
ethcore-call-contract = { path = "ethcore/call-contract"}
3738
ethcore-db = { path = "ethcore/db" }
3839
ethcore-io = { path = "util/io" }
3940
ethcore-light = { path = "ethcore/light" }
@@ -79,12 +80,12 @@ ipnetwork = "0.12.6"
7980
tempdir = "0.3"
8081
fake-fetch = { path = "util/fake-fetch" }
8182

82-
[target.'cfg(windows)'.dependencies]
83-
winapi = { version = "0.3.4", features = ["winsock2", "winuser", "shellapi"] }
84-
8583
[target.'cfg(not(windows))'.dependencies]
8684
daemonize = "0.3"
8785

86+
[target.'cfg(windows)'.dependencies]
87+
winapi = { version = "0.3.4", features = ["winsock2", "winuser", "shellapi"] }
88+
8889
[features]
8990
miner-debug = ["ethcore/miner-debug"]
9091
json-tests = ["ethcore/json-tests"]
@@ -132,6 +133,10 @@ members = [
132133
"evmbin",
133134
"parity-clib",
134135
"whisper/cli",
136+
"util/triehash-ethereum",
137+
"util/keccak-hasher",
138+
"util/patricia-trie-ethereum",
139+
"util/fastmap"
135140
]
136141

137142
[patch.crates-io]

ethcore/Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ ethabi-derive = "6.0"
2121
ethash = { path = "../ethash" }
2222
ethcore-blockchain = { path = "./blockchain" }
2323
ethcore-bloom-journal = { path = "../util/bloom" }
24+
ethcore-call-contract = { path = "./call-contract" }
2425
ethcore-db = { path = "./db" }
2526
ethcore-io = { path = "../util/io" }
2627
ethcore-miner = { path = "../miner" }

ethcore/call-contract/Cargo.toml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
[package]
2+
name = "ethcore-call-contract"
3+
version = "0.1.0"
4+
license = "GPL-3.0"
5+
authors = ["Parity Technologies <admin@parity.io>"]
6+
edition = "2018"
7+
8+
[dependencies]
9+
types = { path = "../types", package = "common-types" }
10+
ethereum-types = "0.4"
11+
bytes = { version = "0.1", package = "parity-bytes" }
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
// Copyright 2015-2019 Parity Technologies (UK) Ltd.
2+
// This file is part of Parity Ethereum.
3+
4+
// Parity Ethereum is free software: you can redistribute it and/or modify
5+
// it under the terms of the GNU General Public License as published by
6+
// the Free Software Foundation, either version 3 of the License, or
7+
// (at your option) any later version.
8+
9+
// Parity Ethereum is distributed in the hope that it will be useful,
10+
// but WITHOUT ANY WARRANTY; without even the implied warranty of
11+
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12+
// GNU General Public License for more details.
13+
14+
// You should have received a copy of the GNU General Public License
15+
// along with Parity Ethereum. If not, see <http://www.gnu.org/licenses/>.
16+
17+
//! Provides CallContract and RegistryInfo traits
18+
19+
use bytes::Bytes;
20+
use ethereum_types::Address;
21+
use types::ids::BlockId;
22+
23+
/// Provides `call_contract` method
24+
pub trait CallContract {
25+
/// Like `call`, but with various defaults. Designed to be used for calling contracts.
26+
fn call_contract(&self, id: BlockId, address: Address, data: Bytes) -> Result<Bytes, String>;
27+
}
28+
29+
/// Provides information on a blockchain service and it's registry
30+
pub trait RegistryInfo {
31+
/// Get the address of a particular blockchain service, if available.
32+
fn registry_address(&self, name: String, block: BlockId) -> Option<Address>;
33+
}

0 commit comments

Comments
 (0)