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

frost-rerandomized: warnings when building documentation #808

Closed
StackOverflowExcept1on opened this issue Dec 12, 2024 · 1 comment
Closed

Comments

@StackOverflowExcept1on
Copy link
Contributor

I use the main branch of frost as dependency and get this kind of warning because of some things being under feature flags.

impl<C> RandomizedParams<C>
where
C: RandomizedCiphersuite,
{
/// Create a new [`RandomizedParams`] for the given [`VerifyingKey`] and
/// the given `participants`.
#[cfg(feature = "serialization")]
pub fn new<R: RngCore + CryptoRng>(

$ cargo doc -p frost-rerandomized --no-default-features --release

warning: unresolved link to `RandomizedParams::new`
 --> frost-rerandomized/src/lib.rs:6:37
  |
6 | //! - The Coordinator should call [`RandomizedParams::new()`] and send
  |                                     ^^^^^^^^^^^^^^^^^^^^^^^ the struct `RandomizedParams` has no function named `new`
  |
  = note: `#[warn(rustdoc::broken_intra_doc_links)]` on by default

warning: unresolved link to `Randomizer::new`
   --> frost-rerandomized/src/lib.rs:225:11
    |
225 |     /// [`Randomizer::new()`] instead.
    |           ^^^^^^^^^^^^^^^^^ the struct `Randomizer` has no function named `new`

warning: unresolved link to `RandomizedParams::new`
   --> frost-rerandomized/src/lib.rs:289:49
    |
289 |     /// be generated uniformly at random! Use [`RandomizedParams::new()`] which
    |                                                 ^^^^^^^^^^^^^^^^^^^^^^^ the struct `RandomizedParams` has no function named `new`

warning: `frost-rerandomized` (lib doc) generated 3 warnings
@mpguerra mpguerra moved this to New in FROST Dec 12, 2024
@conradoplg
Copy link
Contributor

I'm not sure we want to support --no-default-features for cargo doc. We use doc_cfg to label functions which are available only for some features (though we did forget to do that in frost-rerandomized, but I think there is no point fixing it because it will vanish with #762), and that only works with --all-features.

You can likely get rid of the warning by using --no-deps with cargo doc - usually there is no reason to generate the documentation for the dependencies.

Thanks for reporting this though, it reminded me of creating #809

@conradoplg conradoplg closed this as not planned Won't fix, can't repro, duplicate, stale Dec 12, 2024
@github-project-automation github-project-automation bot moved this from New to Done in FROST Dec 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

No branches or pull requests

2 participants