Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace env_logger with sp_tracing #5065

Merged
merged 29 commits into from
Aug 1, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
81309ff
Use sp_tracing for tests logging
Safrout1 Jul 18, 2024
0efe06b
replace env_logger with sp_tracing in test files
Safrout1 Jul 18, 2024
30daacc
Update substrate/frame/sassafras/src/tests.rs
Safrout1 Jul 25, 2024
7e329e5
Merge branch 'master' into use-sp-tracing
acatangiu Jul 25, 2024
467d69c
omit the let _ for sp-tracing
Safrout1 Jul 28, 2024
60611fb
Use sp_tracing with try_init_simple for substrate/frame/contracts/src…
Safrout1 Jul 28, 2024
8b59993
use sp-tracing in polkadot/node/subsystem-bench/src/cli/subsystem-ben…
Safrout1 Jul 28, 2024
50a54d1
Use sp-tracing in substrate/client/executor/benches/bench.rs and subs…
Safrout1 Jul 28, 2024
8980035
Use sp_tracing in bridges/relays/utils/src/initialize.rs and keep the…
Safrout1 Jul 28, 2024
e041bcd
globally remove the env_logger dependency
Safrout1 Jul 28, 2024
86d2d04
Merge branch 'master' into use-sp-tracing
Safrout1 Jul 28, 2024
9b290ac
Merge branch 'master' into use-sp-tracing
Safrout1 Jul 29, 2024
3fb81ce
Merge branch 'master' into use-sp-tracing
acatangiu Jul 29, 2024
f32c85e
Fix errors related to using filters with and subscribe builders with …
Safrout1 Jul 29, 2024
58f4ecb
try fixing the subscriber import issue
Safrout1 Jul 29, 2024
82c7f73
Revert "try fixing the subscriber import issue"
Safrout1 Jul 29, 2024
e132726
Update substrate/primitives/tracing/src/lib.rs
Safrout1 Jul 30, 2024
816a673
Update bridges/relays/utils/Cargo.toml
Safrout1 Jul 30, 2024
46d96b3
Merge branch 'master' into use-sp-tracing
Safrout1 Jul 30, 2024
6c2ed50
fix clippy errors
Safrout1 Jul 30, 2024
7f25f9e
Merge branch 'master' into use-sp-tracing
Safrout1 Jul 30, 2024
a1ca808
Format the initializers.rs file
Safrout1 Jul 30, 2024
0a405f6
Add a .prdoc file
Safrout1 Jul 30, 2024
d794d1d
use default features of sp-tracing always
Safrout1 Jul 30, 2024
e7ed418
format the tracing cargo.toml
Safrout1 Jul 30, 2024
ebc4ef9
formatting cargo.toml files with taplo
Safrout1 Jul 31, 2024
7b4f321
add the suggestions for the prdoc
Safrout1 Jul 31, 2024
928f882
Merge branch 'master' into use-sp-tracing
Safrout1 Jul 31, 2024
0e4bdf3
format the prdoc file
Safrout1 Jul 31, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ env_logger = { workspace = true }
hex = { workspace = true, default-features = true }
array-bytes = { workspace = true, default-features = true }
sp-crypto-hashing = { workspace = true, default-features = true }
sp-tracing = { workspace = true }
Safrout1 marked this conversation as resolved.
Show resolved Hide resolved

[features]
default = ["std"]
Expand Down
12 changes: 6 additions & 6 deletions bridges/snowbridge/pallets/outbound-queue/merkle-tree/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -335,7 +335,7 @@ mod tests {
#[test]
fn should_generate_empty_root() {
// given
let _ = env_logger::try_init();
let _ = sp_tracing::init_for_tests();
let data = vec![];

// when
Expand All @@ -351,7 +351,7 @@ mod tests {
#[test]
fn should_generate_single_root() {
// given
let _ = env_logger::try_init();
let _ = sp_tracing::init_for_tests();
let data = make_leaves(1);

// when
Expand All @@ -367,7 +367,7 @@ mod tests {
#[test]
fn should_generate_root_pow_2() {
// given
let _ = env_logger::try_init();
let _ = sp_tracing::init_for_tests();
let data = make_leaves(2);

// when
Expand All @@ -382,7 +382,7 @@ mod tests {

#[test]
fn should_generate_root_complex() {
let _ = env_logger::try_init();
let _ = sp_tracing::init_for_tests();
let test = |root, data: Vec<H256>| {
assert_eq!(
array_bytes::bytes2hex("", merkle_root::<Keccak256, _>(data.into_iter()).as_ref()),
Expand All @@ -401,7 +401,7 @@ mod tests {
#[ignore]
fn should_generate_and_verify_proof() {
// given
let _ = env_logger::try_init();
let _ = sp_tracing::init_for_tests();
let data: Vec<H256> = make_leaves(3);

// when
Expand Down Expand Up @@ -458,7 +458,7 @@ mod tests {
#[test]
#[should_panic]
fn should_panic_on_invalid_leaf_index() {
let _ = env_logger::try_init();
let _ = sp_tracing::init_for_tests();
merkle_proof::<Keccak256, _>(make_leaves(1).into_iter(), 5);
}
}