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

Commit bc89da2

Browse files
Added serde feature to sp-consensus-aura (#14166)
This is followup of #13027. `Aura` need to enable `serde` feature in dependent crates, otherwise test-substrate-runtime compilation fails with the following error if `serde` is enabled: ``` error: cannot find macro `format` in this scope --> /home/miszka/parity/10-genesis-config/substrate-master/primitives/consensus/aura/src/lib.rs:50:3 | 50 | app_crypto!(ed25519, AURA); | ^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: consider importing one of these items: scale_info::prelude::format sp_application_crypto::format = note: this error originates in the macro `$crate::app_crypto_public_common_if_serde` which comes from the expansion of the macro `app_crypto` (in Nightly builds, run with -Z macro-backtrace for more info) ```
1 parent f4a2e84 commit bc89da2

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

primitives/consensus/aura/Cargo.toml

+8
Original file line numberDiff line numberDiff line change
@@ -40,3 +40,11 @@ std = [
4040
"sp-std/std",
4141
"sp-timestamp/std",
4242
]
43+
44+
# Serde support without relying on std features.
45+
serde = [
46+
"scale-info/serde",
47+
"sp-application-crypto/serde",
48+
"sp-consensus-slots/serde",
49+
"sp-runtime/serde",
50+
]

0 commit comments

Comments
 (0)