Closed
Description
cargo 1.35.0-nightly (0e35bd8af 2019-03-13)
When running cargo doc --no-deps
, dependencies docs are still being checked even if not linked into the resulting documentation. This makes it impossible to generate documentation for my crate if I have deny( warnings )
on. I suppose it would also make it impossible for people depending on my crate to generate documentation if I had deny( warnings )
on.
In other words, it makes it impossible to use deny( warnings )
in published code.
Metadata
Metadata
Assignees
Labels
Type
Projects
Milestone
Relationships
Development
No branches or pull requests
Activity
GuillaumeGomez commentedon Mar 25, 2019
Fix the dependencies? Joke aside, it needs to be fixed. I'll take a look.
najamelan commentedon Apr 20, 2019
From this output it clearly happens also if the deny_warnings is in the dependency, but it looks like rustdoc makes a difference in behavior depending on whether it's a path dependency or a crates dependency:
I should still verify this, but it looks like a crates version of tokio gets build just before and works, but in the path version it breaks.
ehuss commentedon Apr 20, 2019
@najamelan Cargo builds dependencies with
--cap-lints=allow
unless it is a path dependency. This is done with the intent that these are crates under your control.I would avoid
deny(warnings)
for reasons like this.najamelan commentedon Apr 30, 2019
to follow up on this a bit the deny_warnings issue aside, it still spawns the terminal with warnings from other crates which makes it hard to fix just the warnings in the current crate. I'm trying to fix the warnings in futures-rs if you want to get a feel of what I mean.
Still from running
cargo doc --no-deps
on futures-rs, master branch with today's nightly. I noticed something else. If it's more appropriate in a different issue, let me know:A whole bunch of these, with no indication of where they come from. Note the line:
= note: the link appears in this line:
. The actual line information is missing, so it's not even known in which crate these are. Maybe instd
? Note that I have componentrust-src
installed.najamelan commentedon Apr 30, 2019
Looks more like the false positives need to be fixed...
Attempt to fix all documentation warnings from rustdoc.
Attempt to fix all documentation warnings from rustdoc.
Attempt to fix all documentation warnings from rustdoc.
bkchr commentedon May 11, 2020
@GuillaumeGomez any progress on this?
4 remaining items