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

Error while trying to build sphinx docs with make.bat html and make.bat serve #12119

Closed
kingsamurai123 opened this issue May 5, 2022 · 6 comments

Comments

@kingsamurai123
Copy link
Contributor

kingsamurai123 commented May 5, 2022

Software versions

Python version : 3.10.4 | packaged by conda-forge | (main, Mar 24 2022, 17:34:17) [MSC v.1929 64 bit (AMD64)]
IPython version : 8.3.0
Tornado version : 6.1
Bokeh version : 3.0.0dev6+7.g79a9a7ce6
BokehJS static path : c:\users\autobot\desktop\gitproject\bokeh\bokeh\server\static
node.js version : v16.14.2
npm version : 8.9.0
Operating system : Windows-10-10.0.22000-SP0

Browser name and version

Firefox-99.0.1 (64-bit)

Jupyter notebook / Jupyter Lab version

No response

Expected behavior

The docs should be shown in the browser.

Observed behavior

The browser throws 404 not found error and showing this on terminal:
image

Installed the bkdev environment using the documentation guide, small change made during the build. I installed npm using npm install -g npm@8, because the npm ci requires npm version to be greater than 8. Everything went smooth after that until I came to make.bat html step. I got the below error in middle, but the build continued and when I try make.bat serve I see the observed behavior.

Example code

Stack traceback or browser console output

No response

Screenshots

image

EDIT: Cleaned the issue for neat viewing

@bryevdv
Copy link
Member

bryevdv commented May 5, 2022

@kingsamurai123 gentle ask: please always post actual text snippets of text, and not images of text, in bug reports, support requests, etc. Images of text are not accessible in a variety of ways.

My speculation is that that is something amiss in your local environment, in which case this would be better moved to the Discourse site where support discussions happen. I don't typically have a windows system at hand to use @tcmetzger are you currently able to build docs on windows? If so, we should close this issue and move to Discourse.

The other alternative is to try the recently added Docker container for development so that the standard Makefile can be used for docs building, rather than the windows .bat` files. But note: the docker setup is still very new and has not been put through many paces, ymmv.

@kingsamurai123
Copy link
Contributor Author

Hi @bryevdv , sorry for the screenshots. Will never do it again.

I have rebuilt the documentation in my linux machine. I got the server started and can see the documentation without any errors.

The only change I made from what documentation shows is, I installed npm version 8 instead of version 7. This is because, I get the below error when I run npm ci. This change, I made in windows machine too. But in the previous comment, I didn't provide the error. So, posting it here.

(bkdev) megatron@megatron:~/bokeh/bokehjs$ npm ci
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE   package: '@bokeh/bokehjs@3.0.0-dev.6',
npm WARN EBADENGINE   required: { node: '>=16.0', npm: '>=8.0' },
npm WARN EBADENGINE   current: { node: 'v16.14.2', npm: '7.24.2' }
npm WARN EBADENGINE }
npm WARN deprecated source-map-resolve@0.6.0: See https://github.com/lydell/source-map-resolve#deprecated

@tcmetzger
Copy link
Member

tcmetzger commented May 10, 2022

@kingsamurai123 @bryevdv I cloned the repo to a win10 machine and set up the dev environment following the instructions on https://docs.bokeh.org/en/latest/docs/dev_guide/setup.html and https://docs.bokeh.org/en/latest/docs/dev_guide/setup.html, replacing npm install -g npm@7 with npm install -g npm@7. I ran .\make.bat html and got the same error, towards the very end of the build process:

Sphinx error:
Error generating bokeh-content-5f2bbb73ae5948c9860507bd87212453-docs-user_guide-extensions.js:

c:\temp\bokeh\bokeh\server\static\js\compiler.js:91
          throw err;
          ^

Error: Cannot find module 'eslint/use-at-your-own-risk'
    at require (c:\temp\bokeh\bokeh\server\static\js\compiler.js:89:23)
    at c:\temp\bokeh\bokeh\server\static\js\compiler.js:339399:9
    at Object._ (c:\temp\bokeh\bokeh\server\static\js\compiler.js:339273:64)
    at require (c:\temp\bokeh\bokeh\server\static\js\compiler.js:107:21)
    at Object._ (c:\temp\bokeh\bokeh\server\static\js\compiler.js:324503:43)
    at require (c:\temp\bokeh\bokeh\server\static\js\compiler.js:107:21)
    at Object._ (c:\temp\bokeh\bokeh\server\static\js\compiler.js:324475:37)
    at require (c:\temp\bokeh\bokeh\server\static\js\compiler.js:107:21)
    at Object._ (c:\temp\bokeh\bokeh\server\static\js\compiler.js:174228:5)
    at require (c:\temp\bokeh\bokeh\server\static\js\compiler.js:107:21) {
  code: 'MODULE_NOT_FOUND'
}

The .bat script keeps running and tries to copy the files, it even prints Build finished. The HTML pages are in build/html. However, the HTML files are missing and Tornado can't find them when running .\make.bat serve.

(I usually use a Ubuntu VM or WSL on Windows to work on Bokeh, so I haven't build docs on Windows directly in quite some time)

@kingsamurai123
Copy link
Contributor Author

yes @tcmetzger Even I got the same error in windows. Since, I got this compiled on my linux machine. I don't have any problem with the docs anymore. So, can I close this issue or it should be closed after someone resolves the issue in windows?

@tcmetzger
Copy link
Member

Some of those issues should be resolved with Bokeh 3.0 now, but there are still some issues that I have made #12480 for. I'll close this issue in favor of #12480.

@chinmaychahar
Copy link
Contributor

chinmaychahar commented Mar 8, 2023

Hello, @tcmetzger I'm trying to setup local documentation and am getting the same error. Apologies for commenting on a closed issue but is there any fix available for this now?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants