Fix the external_doc CI error, make the examples no_run#365
Merged
afilini merged 2 commits intobitcoindevkit:masterfrom Jun 9, 2021
Merged
Fix the external_doc CI error, make the examples no_run#365afilini merged 2 commits intobitcoindevkit:masterfrom
external_doc CI error, make the examples no_run#365afilini merged 2 commits intobitcoindevkit:masterfrom
Conversation
It looks like this is now enabled by default as of `cargo 1.54.0-nightly (0cecbd673 2021-06-01)`
We have an attribute `no_run` that builds but does not run example code in Rustdocs, this keeps the examples building as the codebase evolves. use `no_run` and fix example code so it builds cleanly during test run. Some examples that require the `electrum` feature to be available have been feature-gated to make sure they aren't accidentally compiled when that feature is not enabled. Co-authored-by: Alekos Filini <alekos.filini@gmail.com>
RCasatta
approved these changes
Jun 9, 2021
Member
RCasatta
left a comment
There was a problem hiding this comment.
LGTM
just a note, I've seen crates using a generic unstable feature for nightly-only features that may be more generic than test-md-docs if we have other situations where it's useful to avoid features proliferations
Member
Author
|
Yeah we can consider that in the future if we start adding more and more nightly-only features. I think right now this is the only one we have |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR fixes the issue we've been having with our CI on nightly runs, since the
feature(external_doc)has been removed.This also finishes the work started in #340 to make sure the CI compiles the examples we have in
src/lib.rs.Notes to the reviewers
This needs to go in before we can make the
v0.8.0release, because otherwise we can't use the CI to test our changes before publishing to crates.io like we do normally.Checklists
All Submissions:
cargo fmtandcargo clippybefore committing