-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
404 on js and css locally #1105
Comments
Which version of mdbook do you have? Make sure it’s the same one as in travis.yml
… On Sep 23, 2018, at 10:07 AM, Khalid Jebbari ***@***.***> wrote:
Hello,
I've followed to the letter the simple instructions to read the book locally, but when I visit localhost:3000 I get no styles and no javascripts: 404 on both. Browsers devtools say:
GET http://localhost:3000/book.css net::ERR_ABORTED 404 (Not Found)
GET http://localhost:3000/store.js net::ERR_ABORTED 404 (Not Found)
I know almost nothing about Rust or mdbook, maybe some instructions are missing? Or something's broken?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or mute the thread.
|
See the update of the message directly on GitHub ( I should have posted it
as a comment, sorry)
On Sun, Sep 23, 2018, 6:16 PM Steve Klabnik <[email protected]>
wrote:
… Which version of mdbook do you have? Make sure it’s the same one as in
travis.yml
> On Sep 23, 2018, at 10:07 AM, Khalid Jebbari ***@***.***>
wrote:
>
> Hello,
>
> I've followed to the letter the simple instructions to read the book
locally, but when I visit localhost:3000 I get no styles and no
javascripts: 404 on both. Browsers devtools say:
>
> GET http://localhost:3000/book.css net::ERR_ABORTED 404 (Not Found)
> GET http://localhost:3000/store.js net::ERR_ABORTED 404 (Not Found)
> I know almost nothing about Rust or mdbook, maybe some instructions are
missing? Or something's broken?
>
> —
> You are receiving this because you are subscribed to this thread.
> Reply to this email directly, view it on GitHub, or mute the thread.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#1105 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAEt3i7hK9qZbJvSJKy93BjfUjzOPwhHks5ud7O_gaJpZM4W1tvj>
.
|
After looking at the generated I also verified that the version of mdbook I have (0.2.1) is the same than in travis.yml (it's searching for the |
Ah, so I think that's a bug in Travis. mdbook 0.2 changed some stuff, and so we actually depend on 0.1.8. I bet that's it? |
I'll try tomorrow to install mdbook 0.1.8 and see how it goes
…On Mon, Sep 24, 2018, 10:55 PM Steve Klabnik ***@***.***> wrote:
Ah, so I think that's a bug in Travis. mdbook 0.2 changed some stuff, and
so we actually depend on 0.1.8. I bet that's it?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#1105 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAEt3maBGVLk5hDqO78md9H_7yc4CTKTks5ueUazgaJpZM4W1tvj>
.
|
Not much better with 0.1.8, |
Hm, that seems bad. |
Those two things are hardcoded in rust-by-example's theme(and OP is using a newer than expected mdBook, which doesn't "generate" rust-by-example/theme/index.hbs Line 12 in bc342a4
rust-by-example/theme/index.hbs Line 52 in bc342a4
Lines 1 to 22 in bc342a4
|
Does anyone know what script is (re)generating this: https://doc.rust-lang.org/stable/rust-by-example/ ? EDIT: one thing's for sure: it's not even referencing/fetching a Because, since that one works, we can look at what mdbook version it's using... guessing 0.1.7 ? (EDIT: it works with 0.1.7 (not with 0.1.8, as already mentioned)!) |
… On Thu, Oct 25, 2018 at 12:24 PM xftroxgpx ***@***.***> wrote:
Does anyone know what script is (re)generating this:
https://doc.rust-lang.org/stable/rust-by-example/ ?
Because, since that one works, we can look at what mdbook version it's
using... guessing 0.1.7 ? (will edit this after I try that)
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#1105 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AABsiof_R1d8YW3_PwEZesdcoQKkA0Mvks5uoeWzgaJpZM4W1tvj>
.
|
Ah. Thanks so much! My 0.1.7 just finished compiling when you said that and I can confirm that rust-by-example now works locally with it! (no errors about ie. EDIT: I just noticed that this is already mentioned in |
Thank you, will try that tomorrow and report.
…On Thu, Oct 25, 2018, 6:49 PM xftroxgpx ***@***.***> wrote:
https://github.com/rust-lang/rust/blob/master/src/tools/rustbook/Cargo.toml#L11
Ah. Thanks so much! My 0.1.7 just finished compiling when you said that
and I can confirm that rust-by-example now works locally with it! (no
errors about store.js missing, like in 0.1.8 for example)
ie. $ cargo install mdbook --force --vers 0.1.7
Finished release [optimized] target(s) in 9m 51s
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#1105 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAEt3rhwadkOILg9HNC2oS3NDJ_LeCFZks5uoeuWgaJpZM4W1tvj>
.
|
@DjebbZ did it work for you? |
It works fine, with both the version of Below's a complete run down of my tests. > pwd
/home/djebbz/code/etc/learn-rust-with-rust-examples/rust-by-example
> git log --oneline -n 1
92f47db96e (HEAD -> master, origin/master, origin/HEAD) Merge pull request #1103 from vks/patch-2
> cargo install mdbook --force --version 0.1.7
... downloading and compiling ...
> mdbook build
... building ...
> mdbook serve
... works fine with version 0.1.7
> git pull
... pulling ...
> git log --oneline -n 1
506b3754c7 (HEAD -> master, origin/master, origin/HEAD) Merge pull request #1108 from maccoda/master
> mdbook build
... building ...
> mdbook serve
... works fine with too |
Unless I'm missing something, it seems that the current HEAD of the book works without problems while having So, maybe this issue can be closed?
mdbook test that failed: |
found this after trying myself with |
Hello,
I've followed to the letter the simple instructions to read the book locally, but when I visit
localhost:3000
I get no styles and no javascripts: 404 on both. Browsers devtools say:I know almost nothing about Rust or mdbook, maybe some instructions are missing? Or something's broken?
--Edit: more info about my setup
The text was updated successfully, but these errors were encountered: