Jupyter-book: Unable to deploy a book in Netlify

Created on 12 Jun 2020  ยท  2Comments  ยท  Source: executablebooks/jupyter-book

Describe the bug
Once and again, after many tries, with different combinations of the requirements.txt and the build command, I am not able to deploy a book to Netlify. The book runs perfectly locally.
(For sure, the bug is on my side; I mean, I would not say it is a bug, but I can not go ahead...so, this is more a help-issue than an issue.)

I have been following the instructions, with no result. The following is one of the results I have received:

10:51:46 AM: Build ready to start
10:51:48 AM: build-image version: 30f629161c0736b1a3ecd8b418e5eeffab5c0faf
10:51:48 AM: build-image tag: v3.3.14
10:51:48 AM: buildbot version: 960d989224ecbd0e01be03c5f7dffe3d8f543e02
10:51:48 AM: Fetching cached dependencies
10:51:48 AM: Failed to fetch cache, continuing with build
10:51:48 AM: Starting to prepare the repo for build
10:51:49 AM: No cached dependencies found. Cloning fresh repo
10:51:49 AM: git clone https://github.com/jmigartua/perovskitesMorocco_web
10:51:50 AM: Preparing Git Reference refs/heads/master
10:51:52 AM: Starting build script
10:51:52 AM: Installing dependencies
10:51:53 AM: Downloading and installing node v10.21.0...
10:51:53 AM: Downloading https://nodejs.org/dist/v10.21.0/node-v10.21.0-linux-x64.tar.xz...
10:51:54 AM: Computing checksum with sha256sum
10:51:54 AM: Checksums matched!
10:51:56 AM: Now using node v10.21.0 (npm v6.14.4)
10:51:56 AM: Started restoring cached build plugins
10:51:56 AM: Finished restoring cached build plugins
10:51:56 AM: Attempting ruby version 2.6.2, read from environment
10:51:58 AM: Using ruby version 2.6.2
10:51:58 AM: Using PHP version 5.6
10:51:58 AM: Installing pip dependencies
10:51:58 AM: Started restoring cached pip cache
10:51:58 AM: Finished restoring cached pip cache
10:51:59 AM: DEPRECATION: Python 2.7 reached the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 is no longer maintained. pip 21.0 will drop support for Python 2.7 in January 2021. More details about Python 2 support in pip, can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support
10:51:59 AM: Collecting jupyter-book
10:51:59 AM:   Downloading jupyter_book-0.3-py2.py3-none-any.whl (4.4 MB)
10:52:00 AM: Installing collected packages: jupyter-book
10:52:00 AM: Successfully installed jupyter-book-0.3
10:52:00 AM: Pip dependencies installed
10:52:00 AM: 5.2 is already installed.
10:52:00 AM: Using Swift version 5.2
10:52:00 AM: Started restoring cached go cache
10:52:00 AM: Finished restoring cached go cache
10:52:00 AM: go version go1.12 linux/amd64
10:52:00 AM: go version go1.12 linux/amd64
10:52:00 AM: Installing missing commands
10:52:00 AM: Verify run directory
10:52:02 AM: 
10:52:02 AM: โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
10:52:02 AM: โ”‚        Netlify Build        โ”‚
10:52:02 AM: โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
10:52:02 AM: 
10:52:02 AM: โฏ Version
10:52:02 AM:   @netlify/build 1.0.14
10:52:02 AM: 
10:52:02 AM: โฏ Flags
10:52:02 AM:   mode: buildbot
10:52:02 AM: 
10:52:02 AM: โฏ Current directory
10:52:02 AM:   /opt/build/repo
10:52:02 AM: 
10:52:02 AM: โฏ Config file
10:52:02 AM:   No config file was defined: using default values.
10:52:02 AM: 
10:52:02 AM: โฏ Context
10:52:02 AM:   production
10:52:02 AM: 
10:52:02 AM: โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
10:52:02 AM: โ”‚ 1. Build command from settings โ”‚
10:52:02 AM: โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
10:52:02 AM: 
10:52:02 AM: $ jupyter-book build .
10:52:02 AM: bash: jupyter-book: command not found
10:52:02 AM: 
10:52:02 AM: โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
10:52:02 AM: โ”‚   "build.command" failed    โ”‚
10:52:02 AM: โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
10:52:02 AM: 
10:52:02 AM:   Error message
10:52:02 AM:   Command failed with exit code 127: jupyter-book build .
10:52:02 AM: 
10:52:02 AM:   Error location
10:52:02 AM:   In Build command from settings:
10:52:02 AM:   jupyter-book build .
10:52:02 AM: 
10:52:02 AM:   Resolved config
10:52:02 AM:   build:
10:52:02 AM:     command: jupyter-book build .
10:52:02 AM:     publish: /opt/build/repo/_build/html
10:52:02 AM: Caching artifacts
10:52:02 AM: Started saving build plugins
10:52:02 AM: Finished saving build plugins
10:52:02 AM: Started saving pip cache
10:52:02 AM: Finished saving pip cache
10:52:02 AM: Started saving emacs cask dependencies
10:52:02 AM: Finished saving emacs cask dependencies
10:52:02 AM: Started saving maven dependencies
10:52:02 AM: Finished saving maven dependencies
10:52:02 AM: Started saving boot dependencies
10:52:02 AM: Finished saving boot dependencies
10:52:02 AM: Started saving go dependencies
10:52:02 AM: Finished saving go dependencies
10:52:06 AM: Error running command: Build script returned non-zero exit code: 1
10:52:06 AM: Failing build: Failed to build site
10:52:06 AM: Failed during stage 'building site': Build script returned non-zero exit code: 1
10:52:06 AM: Finished processing build request in 17.554461641s

Additional context
I do not know if there is something else needed.

bug

Most helpful comment

Ahhh, sorry! I have included it now (very sorry for this) and it works perfectly!!
Thanks!!

All 2 comments

I can see that your traceback includes a warning about using Python 2.7 (which jupyter book doesn't support, and which would explain why jupyter book isn't being successfully called in the image).

Just to confirm: are you including a runtime.txt file in your repository, as detailed here ?

Ahhh, sorry! I have included it now (very sorry for this) and it works perfectly!!
Thanks!!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

choldgraf picture choldgraf  ยท  5Comments

spring-haru picture spring-haru  ยท  5Comments

cedeerwe picture cedeerwe  ยท  3Comments

mmcky picture mmcky  ยท  5Comments

sidneymbell picture sidneymbell  ยท  5Comments