mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-23 10:51:10 +00:00
deps: use polkadot-sdk umbrella crate (#1786)
* deps: unify usage of polkadot-sdk crates * cargo fmt * fix macro crate * make tests compile * fix more nits * fix doc tests * fix more nits * more nits * core: remove polkadot-sdk/std * cargo fmt * remove polkadot-sdk/std by default * Update metadata/Cargo.toml * remove more std * Update Cargo.toml
This commit is contained in:
+2
-4
@@ -18,7 +18,6 @@ keywords = ["parity", "subxt", "extrinsic", "signer"]
|
||||
default = ["sr25519", "ecdsa", "subxt", "std"]
|
||||
std = [
|
||||
"regex/std",
|
||||
"sp-crypto-hashing/std",
|
||||
"pbkdf2/std",
|
||||
"sha2/std",
|
||||
"hmac/std",
|
||||
@@ -60,7 +59,7 @@ cfg-if = { workspace = true }
|
||||
codec = { package = "parity-scale-codec", workspace = true, features = [
|
||||
"derive",
|
||||
] }
|
||||
sp-crypto-hashing = { workspace = true }
|
||||
polkadot-sdk = { workspace = true, features = ["sp-crypto-hashing"] }
|
||||
pbkdf2 = { workspace = true }
|
||||
sha2 = { workspace = true }
|
||||
hmac = { workspace = true }
|
||||
@@ -85,10 +84,9 @@ crypto_secretbox = { workspace = true, optional = true, features = ["alloc", "sa
|
||||
getrandom = { workspace = true, optional = true }
|
||||
|
||||
[dev-dependencies]
|
||||
sp-keyring = { workspace = true }
|
||||
proptest = { workspace = true }
|
||||
hex-literal = { workspace = true }
|
||||
sp-core = { workspace = true }
|
||||
polkadot-sdk = { workspace = true, features = ["sp-core", "sp-keyring"] }
|
||||
|
||||
[package.metadata.cargo-machete]
|
||||
ignored = ["getrandom"]
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
// see LICENSE for license details.
|
||||
|
||||
use codec::{Decode, Encode};
|
||||
use polkadot_sdk::sp_crypto_hashing;
|
||||
|
||||
// This code is taken from sp_core::crypto::DeriveJunction. The logic should be identical,
|
||||
// though the API is tweaked a touch.
|
||||
|
||||
+2
-2
@@ -4,6 +4,7 @@
|
||||
|
||||
//! An ecdsa keypair implementation.
|
||||
use codec::Encode;
|
||||
use polkadot_sdk::sp_crypto_hashing;
|
||||
|
||||
use crate::crypto::{seed_from_entropy, DeriveJunction, SecretUri};
|
||||
use core::{fmt::Display, str::FromStr};
|
||||
@@ -359,8 +360,7 @@ mod test {
|
||||
|
||||
use super::*;
|
||||
|
||||
use sp_core::crypto::Pair as _;
|
||||
use sp_core::ecdsa::Pair as SpPair;
|
||||
use polkadot_sdk::sp_core::{self, crypto::Pair as _, ecdsa::Pair as SpPair};
|
||||
|
||||
#[test]
|
||||
fn check_from_phrase_matches() {
|
||||
|
||||
@@ -344,8 +344,8 @@ mod test {
|
||||
|
||||
use super::*;
|
||||
|
||||
use sp_core::crypto::Pair as _;
|
||||
use sp_core::sr25519::Pair as SpPair;
|
||||
use polkadot_sdk::sp_core::{self, crypto::Pair as _, sr25519::Pair as SpPair};
|
||||
use polkadot_sdk::sp_keyring;
|
||||
|
||||
#[test]
|
||||
fn check_from_phrase_matches() {
|
||||
|
||||
Reference in New Issue
Block a user