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

Remove "substrate-compat" default feature flag #1077

Closed
jsdw opened this issue Jul 19, 2023 · 0 comments · Fixed by #1078
Closed

Remove "substrate-compat" default feature flag #1077

jsdw opened this issue Jul 19, 2023 · 0 comments · Fixed by #1078
Assignees

Comments

@jsdw
Copy link
Collaborator

jsdw commented Jul 19, 2023

The flags we have enabled by default are ["jsonrpsee", "native", "substrate-compat"].

I'd very much like to remove "substrate-compat" from this default list; it leads to various issues when substrate crates are out of date (common atm since they aren't being published again yet), and pulls in a load of dependencies that aren't needed so much now we have subxt-signer.

So, can we remove it, and feature flag the code/examples that depend on it (and make sure we still do test those in CI)?

I recently found a handy trick for doc examples; you can add eg this around an example to make compiling it conditional on a feature flag:

//! ```rust
//! # // don't compile when feature flag not present:
//! # #[cfg(not(feature = "foo"))]
//! # fn main() {}
//! #
//! # #[cfg(feature = "foo")]
//! # fn main() {
//! 
//! // example requiring feature goes here
//!
//! # }

Not super pretty but I think there's only one/two doc examples using "substrate-compat" :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants