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

Rustdoc search fails when navigating directly to search url: crateSearchDropDown is null #82986

Closed
Darksonn opened this issue Mar 10, 2021 · 5 comments
Labels
C-bug Category: This is a bug. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.

Comments

@Darksonn
Copy link
Contributor

Darksonn commented Mar 10, 2021

Navigating directly to the following url:

https://docs.rs/tokio/1.3.0/tokio/index.html?search=Sleep

will fail to show any results and emit the following Javascript error:

Uncaught TypeError: crateSearchDropDown is null
    setupSearchLoader https://docs.rs/main-20210308-1.52.0-nightly-8f349be27.js:8
    <anonymous> https://docs.rs/main-20210308-1.52.0-nightly-8f349be27.js:8
    <anonymous> https://docs.rs/main-20210308-1.52.0-nightly-8f349be27.js:8
main-20210308-1.52.0-nightly-8f349be27.js:8:1189
    setupSearchLoader https://docs.rs/main-20210308-1.52.0-nightly-8f349be27.js:8
    <anonymous> https://docs.rs/main-20210308-1.52.0-nightly-8f349be27.js:8
    <anonymous> https://docs.rs/main-20210308-1.52.0-nightly-8f349be27.js:8

This is using firefox.

@Darksonn Darksonn added the C-bug Category: This is a bug. label Mar 10, 2021
@jonas-schievink jonas-schievink added the T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. label Mar 10, 2021
@Nemo157
Copy link
Member

Nemo157 commented Mar 12, 2021

Probably related to #82310; seems to be docs.rs specific though, https://doc.rust-lang.org/nightly/std/?search=vec works

@Nemo157
Copy link
Member

Nemo157 commented Mar 12, 2021

Ohh, docs.rs passes --disable-per-crate-search, it probably reproduces with that locally.

@GuillaumeGomez
Copy link
Member

The problem is on docs.rs side: there is a missing file (crates.js).

@GuillaumeGomez
Copy link
Member

But even without crates.js, it should work. Sending a fix.

@GuillaumeGomez
Copy link
Member

The problem doesn't occur on the new tokio version so I think we can now close this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Category: This is a bug. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.
Projects
None yet
Development

No branches or pull requests

4 participants