-
Notifications
You must be signed in to change notification settings - Fork 198
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
docs.rs reuses crate-specific resources from empty_library
for other crates
#1313
Comments
Not specific to |
More specifically it appears to have changed between
and
(from comparing https://docs.rs/syn/1.0.62/syn/ and https://docs.rs/syn/1.0.61/syn/) docs.rs changes: da1f362...918ee5d |
To confirm I went back through the release pages and found the exact builds which changed behaviour, https://docs.rs/near-runtime/4.0.0-pre.1/near_runtime/ was the last build that didn't show |
empty_library
dependency.empty_library
dependency.
Would this then be a I am not getting this behaviour, when just normally compiling documentation on my local machine. It could be that there are some flags of |
It seems like it's a change in
|
I'd expect this to be a regression from rust-lang/rust#80845, cc @GuillaumeGomez. Do we maybe keep the artifacts from the |
Huh, weird that that PR doesn't appear in the compare view though? Looks like that would be in the 2021-03-06/07 nightly, not the 2021-03-05 one. |
Oh oops I was looking at the wrong dates. These are the changes between the toolchains:
It would be helpful if someone could bisect them. |
Checking what's wrong. |
It's an interesting "bug" from rustdoc indeed. Sending a fix. |
Actually no, it's not a bug from rustdoc. Here how it works for rustdoc: |
So here, I see two possibilities:
Which solution do you prefer? |
I precise that the second option seems unreliable considering that |
I can't find where you clean/remove the |
When serving 'essential files', we can either serve the global one, created when building `empty_library`, or the local one, created when building the local crate. Currently we default to the global one, but this causes issues when the file should never have been global in the first place (such as recently for `crates.js`: see rust-lang#1313). This gives precedence to the local file so that the bug will be fixed when rustdoc fixes it, even if we forget to update `ESSENTIAL_FILES_UNVERSIONED`.
When serving 'essential files', we can either serve the global one, created when building `empty_library`, or the local one, created when building the local crate. Currently we default to the global one, but this causes issues when the file should never have been global in the first place (such as recently for `crates.js`: see rust-lang#1313). This gives precedence to the local file so that the bug will be fixed when rustdoc fixes it, even if we forget to update `ESSENTIAL_FILES_UNVERSIONED`.
empty_library
dependency.empty_library
for other crates
Docs.rs shows 'empty_library' in the sidebar and has no search results other than
empty_library
.Original bug report
When publishing a no_std crate without dependencies, it will add an
empty_library
to the crates on [docs.rs].Reproduction steps:
empty_library
in the crates.This seems like a rather awkward way to tell the reader the crate has no dependencies. Now if you click any deeper into the documentation, on the left (under the crates header) the empty_library will be a clickable link that leads to a dead link.
This is what I mean: Link to CRC8-RS Docs
The text was updated successfully, but these errors were encountered: