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

Fix the external_doc CI error, make the examples no_run #365

Merged
merged 2 commits into from
Jun 9, 2021

Conversation

afilini
Copy link
Member

@afilini afilini commented Jun 9, 2021

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.0 release, because otherwise we can't use the CI to test our changes before publishing to crates.io like we do normally.

Checklists

All Submissions:

  • I've signed all my commits
  • I followed the contribution guidelines
  • I ran cargo fmt and cargo clippy before committing

afilini and others added 2 commits June 9, 2021 11:27
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 <[email protected]>
Copy link
Member

@RCasatta RCasatta left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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

@afilini
Copy link
Member Author

afilini commented Jun 9, 2021

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

@afilini afilini merged commit 3b446c9 into bitcoindevkit:master Jun 9, 2021
@afilini afilini deleted the fix/external-doc-feature branch June 9, 2021 14:06
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 this pull request may close these issues.

3 participants