-
Notifications
You must be signed in to change notification settings - Fork 53
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
[Code Quality]: Remove unused #[cfg]
attibutes and fix all clippy warnings
#358
Comments
Hello @Davidson-Souza , can i give it a try to this. Upon looking at the code base i found- #[cfg(feature = "metrics")]
#[cfg(not(feature = <FEATURE>))]. eg - #[cfg(not(feature = "bitcoinconsensus"))]
#[cfg(feature = "cli-blockchain")]
#[error("Json-Rpc error")]
JsonRpcError(#[from] UtreexodError),
#[cfg(feature = "zmq-server")]
#[cfg(target_env = "gnu")]
}
For Clippy warning :
I will give it a try if this sound good. |
Hi @siddheshzz. Thanks for taking a look at this. Most of those |
Hi @Davidson-Souza , Thank you for your time. I am trying to understand few things, please bare with me
serde = { version = "1.0", features = ["derive"], optional = true }
strict_encoding = { version = "1.0", optional = true }
.
.
serde = ["dep:serde"]
default = ["experimental-p2p", "json-rpc", "serde"]
Ran Now the clippy wont show any Is this sound ok or we need some other approach |
For 1, the code can be massively simplified, and we can assume that For 2. This module can be removed as whole, we don't use it any more. If you want, you can make one pr for each, and another one fixing the last few warnings |
Clippy gives warnings about unused features, most of them are either related to the
cli-blockchain
or theslip132
code. The former can be removed altogether, while the latter can be simplified a lot.The text was updated successfully, but these errors were encountered: