Closed liufuyang closed 3 years ago
I added a master-test-build
branch for you, also let me know if you need anything else (I can also grant more access to the repository if you need) you can find the bib2xhtml script here
Thanks. I tried to add that bib2xhtml.pl
file and now I see error like this: perhaps means I need some gnuplot or?
/github/workspace # mdbook build
2021-04-01 10:00:57 [INFO] (mdbook::book): Book building has started
Block empty, but file `hyperplane` was not found!
Error in chapter 1. BinaryNotFound(Error { inner: CannotFindBinaryPath })
2021-04-01 10:00:57 [ERROR] (mdbook::utils): Error: The preprocessor exited unsuccessfully
About more access, if I later I can push some changes directly to master-test-build
to test the build then it would be nice. Let's see, maybe the first build can work out of the box :P
I tried to locally install gnuplot
and running a build, it also not working and showing the same error above. What is that hyperlane
file about?
Tried to install texlive
package in the alpine image now I see this error:
2021-04-01 10:18:00 [INFO] (mdbook::book): Book building has started
InvalidBibliography("This is BibTeX, Version 0.99d (TeX Live 2020/Alpine Linux)\nThe top-level auxiliary file: bib10.aux\nI couldn\'t open style file html-a.bst\n---line 2 of file bib10.aux\n : \\bibstyle{html-a\n : }\nI\'m skipping whatever remains of this command\nI found no style file---while reading file bib10.aux\n(There were 2 error messages)\n")
2021-04-01 10:18:00 [ERROR] (mdbook::utils): Error: The preprocessor exited unsuccessfully
No I have no clue what to do :)
Now I could get a bit further by doing that ./gen-bst.pl
operation from bib2xhtml repo, and using a ubuntu image and installing texlive-latex-extra
solves some other issue.
But now I get back this hyperplane problem... Not sure why. Seem it was gone previously with alpine linux and gnuplot + texlive
installed
2021-04-01 13:35:20 [INFO] (mdbook::book): Book building has started
Block empty, but file `hyperplane` was not found!
Block empty, but file `hyperplane` was not found!
Error in chapter : InvalidReference("could not find reference to `hyperplane` in line 5")
2021-04-01 13:35:20 [ERROR] (mdbook::utils): Error: The preprocessor exited unsuccessfully
it seems that the hyperplane.tex
file is missing, a statement without any body, e.g. $ref:fig:hyperplane$
means that he should look for a file called hyperplane.tex
Thanks. I tried to add that
bib2xhtml.pl
file and now I see error like this: perhaps means I need some gnuplot or?/github/workspace # mdbook build 2021-04-01 10:00:57 [INFO] (mdbook::book): Book building has started Block empty, but file `hyperplane` was not found! Error in chapter 1. BinaryNotFound(Error { inner: CannotFindBinaryPath }) 2021-04-01 10:00:57 [ERROR] (mdbook::utils): Error: The preprocessor exited unsuccessfully
About more access, if I later I can push some changes directly to
master-test-build
to test the build then it would be nice. Let's see, maybe the first build can work out of the box :P
I will grant you access then to the branch
@bytesnake interesting, I can see there is a hyperplane.tex
in the src file. Are you sure the mdbook-scientific currently can working correctly or it is still some unstable version? I tried to remove all the parts that related to hyperplane
in chapter_1.md
then it can build the equations and plots.
I guess we can merge this and give it a try to see whether the gh-pages
branch got build.
One issue or bug is that when I run mdbook serve
(actually via docker run --rm -v $(pwd):/github/workspace --name mdbook -p 3000:3000 liufuyang/mdbook-scientific:0.3.7 serve -n 0.0.0.0
) then after updating some equations, the CPU usage is high and it keeps on reporting log:
2021-04-01 16:10:31 [INFO] (mdbook::cmd::serve): Files changed: ["/github/workspace/src/assets/439706c949677821f5e69104.svg", "/github/workspace/src/assets/d36d2f91a62a9e32d4bdb7d7.svg", "/github/workspace/src/assets/e9ea986c569b3a41be529169.svg", "/github/workspace/src/assets/de566924d07db43d343b3454.svg"]
2021-04-01 16:10:31 [INFO] (mdbook::cmd::serve): Building book...
2021-04-01 16:10:31 [INFO] (mdbook::book): Book building has started
2021-04-01 16:10:31 [INFO] (mdbook::book): Running the html backend
2021-04-01 16:10:32 [INFO] (mdbook::cmd::serve): Files changed: ["/github/workspace/src/assets/439706c949677821f5e69104.svg", "/github/workspace/src/assets/d36d2f91a62a9e32d4bdb7d7.svg", "/github/workspace/src/assets/e9ea986c569b3a41be529169.svg", "/github/workspace/src/assets/de566924d07db43d343b3454.svg"]
2021-04-01 16:10:32 [INFO] (mdbook::cmd::serve): Building book...
Maybe this can be fixed later on...
Note that I made this PR to merge into rust-ml:master-test-build
so it's okay to merge now for test purpose. Otherwise if you have some hints on how to fix the hyperplane issue, please let me know.
Basically right now you can try to build the site via the docker image I prepared from the Dockerfile here.
So if you are at a master branch locally, you can try setting bib2xhtml = "/github/bib2xhtml"
in the book.toml
and use this command to make a build
docker run --rm -v $(pwd):/github/workspace liufuyang/mdbook-scientific:0.3.7 build
Then you will see the hyperplane error...
@bytesnake have you seen some of my questions above? I think I encountered some error while building the book with the scientific plugins. Are we sure the current master of this book can be build by the mdbook with scientific plugin on your side? Sorry I missed an invitation for you to invite to join as a collaborator. It could be nice if you can help send again? :)
sorry bit busy atm :sweat_smile:
@bytesnake interesting, I can see there is a
hyperplane.tex
in the src file. Are you sure the mdbook-scientific currently can working correctly or it is still some unstable version? I tried to remove all the parts that related tohyperplane
inchapter_1.md
then it can build the equations and plots.
it worked on my side, it should be able to locate the hyperplane.tex
in src/
. If you want, I can try to run the docker integration, but have to install docker first to my computer and this will take some time
I guess we can merge this and give it a try to see whether the
gh-pages
branch got build.One issue or bug is that when I run
mdbook serve
(actually viadocker run --rm -v $(pwd):/github/workspace --name mdbook -p 3000:3000 liufuyang/mdbook-scientific:0.3.7 serve -n 0.0.0.0
) then after updating some equations, the CPU usage is high and it keeps on reporting log:2021-04-01 16:10:31 [INFO] (mdbook::cmd::serve): Files changed: ["/github/workspace/src/assets/439706c949677821f5e69104.svg", "/github/workspace/src/assets/d36d2f91a62a9e32d4bdb7d7.svg", "/github/workspace/src/assets/e9ea986c569b3a41be529169.svg", "/github/workspace/src/assets/de566924d07db43d343b3454.svg"] 2021-04-01 16:10:31 [INFO] (mdbook::cmd::serve): Building book... 2021-04-01 16:10:31 [INFO] (mdbook::book): Book building has started 2021-04-01 16:10:31 [INFO] (mdbook::book): Running the html backend 2021-04-01 16:10:32 [INFO] (mdbook::cmd::serve): Files changed: ["/github/workspace/src/assets/439706c949677821f5e69104.svg", "/github/workspace/src/assets/d36d2f91a62a9e32d4bdb7d7.svg", "/github/workspace/src/assets/e9ea986c569b3a41be529169.svg", "/github/workspace/src/assets/de566924d07db43d343b3454.svg"] 2021-04-01 16:10:32 [INFO] (mdbook::cmd::serve): Building book...
Maybe this can be fixed later on...
yeah there is a bug in the serve mode, which will automatically retrigger itself. I didn't continued working on that because building works.
Note that I made this PR to merge into
rust-ml:master-test-build
so it's okay to merge now for test purpose. Otherwise if you have some hints on how to fix the hyperplane issue, please let me know.
perfect :+1:
@bytesnake have you seen some of my questions above? I think I encountered some error while building the book with the scientific plugins. Are we sure the current master of this book can be build by the mdbook with scientific plugin on your side? Sorry I missed an invitation for you to invite to join as a collaborator. It could be nice if you can help send again? :)
have re-sent the invitation
I see. Thanks for the info. I will firstly test whether the github action thing works or not. If that can work, then the left over is to somehow make the docker image can build the current master code.
I will merge this now and see weather this triggers a build for us or not :)
related to https://github.com/rust-ml/book/issues/5#issuecomment-801730275
Basic idea is to have a docker image that contains working programs such as
mdbook
andmdbook-scientific
.WIP, need to install
bib2xhtml
in the build image (alpine linux)For now at least
mdbook
andmdbook-scientific
are packed into the docker image.We can switch the docker image to your organization's image base, and perhaps move docker file to another repo, if that is what you think a better thing to do. Now I would like to illustrate the CI idea via this PR and perhaps you can comment on it.
Also, in order for me to test this, do you mind create a
master-test-build
branch from current master? Thank you :)