Skip to content

Commit

Permalink
Use released substrate dependencies (paritytech#375)
Browse files Browse the repository at this point in the history
* WIP update dependencies to crates versions

* Use released versions of sp-version and sp-arithmetic

* Attempt to align version of sp-keyring used to correspond to 4.0.0 releases. No luck but closer

* sp-keyring 4.0.0

* also sp-keyring 4.0.0 for macro crate

* simplify cargo.tomls

Co-authored-by: James Wilson <james@jsdw.me>
  • Loading branch information
2 people authored and 0623forbidden committed Feb 15, 2022
1 parent 415b018 commit 1fcd43f
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 14 deletions.
11 changes: 5 additions & 6 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -34,21 +34,20 @@ url = "2.2.1"

subxt-macro = { version = "0.1.0", path = "macro" }

sp-core = { git = "https://github.com/paritytech/substrate/", branch = "master", default-features = false }
sp-runtime = { git = "https://github.com/paritytech/substrate/", branch = "master", default-features = false }
sp-version = { package = "sp-version", git = "https://github.com/paritytech/substrate/", branch = "master" }
sp-core = { version = "4.0.0", default-features = false }
sp-runtime = { version = "4.0.0", default-features = false }
sp-version = "4.0.0"

frame-metadata = "14.0.0"
derivative = "2.2.0"

[dev-dependencies]
sp-arithmetic = { git = "https://github.com/paritytech/substrate/", branch = "master", default-features = false }
sp-arithmetic = { version = "4.0.0", default-features = false }
assert_matches = "1.5.0"
async-std = { version = "1.9.0", features = ["attributes", "tokio1"] }
env_logger = "0.8.3"
tempdir = "0.3.7"
wabt = "0.10.0"
which = "4.0.2"
test-runtime = { path = "test-runtime" }

sp-keyring = { package = "sp-keyring", git = "https://github.com/paritytech/substrate/", branch = "master" }
sp-keyring = "4.0.0"
3 changes: 1 addition & 2 deletions macro/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -33,5 +33,4 @@ subxt-codegen = { version = "0.2.0", path = "../codegen" }
pretty_assertions = "0.6.1"
subxt = { path = ".." }
trybuild = "1.0.38"

sp-keyring = { git = "https://github.com/paritytech/substrate/", branch = "master" }
sp-keyring = "4.0.0"
4 changes: 0 additions & 4 deletions src/error.rs
Original file line number Diff line number Diff line change
Expand Up @@ -107,9 +107,6 @@ pub enum RuntimeError {
/// There are no providers so the account cannot be created.
#[error("There are no providers so the account cannot be created.")]
NoProviders,
/// There are too many consumers so the account cannot be created.
#[error("There are too many consumers so the account cannot be created.")]
TooManyConsumers,
/// Bad origin.
#[error("Bad origin: throw by ensure_signed, ensure_root or ensure_none.")]
BadOrigin,
Expand Down Expand Up @@ -144,7 +141,6 @@ impl RuntimeError {
DispatchError::CannotLookup => Ok(Self::CannotLookup),
DispatchError::ConsumerRemaining => Ok(Self::ConsumerRemaining),
DispatchError::NoProviders => Ok(Self::NoProviders),
DispatchError::TooManyConsumers => Ok(Self::TooManyConsumers),
DispatchError::Arithmetic(_math_error) => {
Ok(Self::Other("math_error".into()))
}
Expand Down
4 changes: 2 additions & 2 deletions test-runtime/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@ edition = "2021"

[dependencies]
subxt = { path = ".." }
sp-runtime = { package = "sp-runtime", git = "https://github.com/paritytech/substrate/", branch = "master" }
sp-runtime = "4.0.0"
codec = { package = "parity-scale-codec", version = "2", default-features = false, features = ["derive", "full", "bit-vec"] }

[build-dependencies]
subxt = { path = ".." }
sp-core = { package = "sp-core", git = "https://github.com/paritytech/substrate/", branch = "master" }
sp-core = "4.0.0"
async-std = { version = "1.9.0", features = ["attributes", "tokio1"] }
which = "4.2.2"

0 comments on commit 1fcd43f

Please sign in to comment.