More debugging information ? - Jekyll site deploy

answered
#1

Hi

I’m trying to deploy a github hosted, Jekyll (static site generator) site. I am not running into any of the well documented bundler errors. This is the only meaningful line of the stack trace (to me at least)

failed during stage 'building site': Build script returned non-zero exit code: 1

I can find no errors or problems before then. How can I find more information ? Here is the complete stack trace from the deploy logs:

11:05:12 AM: Build ready to start
11:05:15 AM: build-image version: 715dae5ab5df6309bfdeeb97d2fca1d0f581125a
11:05:15 AM: build-image tag: v3.1.2
11:05:15 AM: buildbot version: 90661b463409e3c86b8a140e387b181ebc36804b
11:05:15 AM: Fetching cached dependencies
11:05:15 AM: Failed to fetch cache, continuing with build
11:05:15 AM: Starting to prepare the repo for build
11:05:16 AM: No cached dependencies found. Cloning fresh repo
11:05:16 AM: git clone https://github.com/bwanicur/middlepathdevelopment
11:05:16 AM: Preparing Git Reference refs/heads/master
11:05:17 AM: Starting build script
11:05:17 AM: Installing dependencies
11:05:18 AM: v10.15.3 is already installed.
11:05:19 AM: Now using node v10.15.3 (npm v6.4.1)
11:05:19 AM: Attempting ruby version ruby-2.6.2, read from .ruby-version file
11:05:20 AM: Using ruby version 2.6.2
11:05:21 AM: Using PHP version 5.6
11:05:21 AM: Started restoring cached ruby gems
11:05:21 AM: Finished restoring cached ruby gems
11:05:21 AM: Installing gem bundle
11:05:23 AM: Fetching gem metadata from https://rubygems.org/
11:05:23 AM: .
11:05:23 AM: .
11:05:23 AM: .
11:05:24 AM: .
11:05:24 AM: .
11:05:24 AM: .
11:05:24 AM: .
11:05:24 AM: .
11:05:24 AM: .
11:05:25 AM: Fetching concurrent-ruby 1.1.5
11:05:25 AM: Installing concurrent-ruby 1.1.5
11:05:25 AM: Fetching i18n 0.9.5
11:05:25 AM: Installing i18n 0.9.5
11:05:26 AM: Fetching minitest 5.11.3
11:05:26 AM: Installing minitest 5.11.3
11:05:27 AM: Fetching thread_safe 0.3.6
11:05:27 AM: Installing thread_safe 0.3.6
11:05:27 AM: Fetching tzinfo 1.2.5
11:05:27 AM: Installing tzinfo 1.2.5
11:05:27 AM: Fetching activesupport 4.2.10
11:05:28 AM: Installing activesupport 4.2.10
11:05:28 AM: Fetching public_suffix 3.0.3
11:05:28 AM: Installing public_suffix 3.0.3
11:05:28 AM: Fetching addressable 2.5.2
11:05:28 AM: Installing addressable 2.5.2
11:05:28 AM: Using bundler 2.0.1
11:05:28 AM: Fetching coffee-script-source 1.11.1
11:05:28 AM: Installing coffee-script-source 1.11.1
11:05:28 AM: Fetching execjs 2.7.0
11:05:28 AM: Installing execjs 2.7.0
11:05:28 AM: Fetching coffee-script 2.4.1
11:05:28 AM: Installing coffee-script 2.4.1
11:05:28 AM: Fetching colorator 1.1.0
11:05:28 AM: Installing colorator 1.1.0
11:05:28 AM: Fetching ruby-enum 0.7.2
11:05:29 AM: Installing ruby-enum 0.7.2
11:05:29 AM: Fetching commonmarker 0.17.13
11:05:29 AM: Installing commonmarker 0.17.13 with native extensions
11:05:39 AM: Fetching dnsruby 1.61.2
11:05:39 AM: Installing dnsruby 1.61.2
11:05:39 AM: Fetching eventmachine 1.2.7
11:05:39 AM: Installing eventmachine 1.2.7 with native extensions
11:05:56 AM: Fetching http_parser.rb 0.6.0
11:05:56 AM: Installing http_parser.rb 0.6.0 with native extensions
11:05:57 AM: Fetching em-websocket 0.5.1
11:05:57 AM: Installing em-websocket 0.5.1
11:05:57 AM: Fetching ffi 1.10.0
11:05:58 AM: Installing ffi 1.10.0 with native extensions
11:06:09 AM: Fetching ethon 0.12.0
11:06:09 AM: Installing ethon 0.12.0
11:06:10 AM: Fetching multipart-post 2.0.0
11:06:10 AM: Installing multipart-post 2.0.0
11:06:10 AM: Fetching faraday 0.15.4
11:06:10 AM: Installing faraday 0.15.4
11:06:10 AM: Fetching forwardable-extended 2.6.0
11:06:10 AM: Installing forwardable-extended 2.6.0
11:06:10 AM: Fetching gemoji 3.0.0
11:06:10 AM: Installing gemoji 3.0.0
11:06:10 AM: Fetching sawyer 0.8.1
11:06:10 AM: Installing sawyer 0.8.1
11:06:10 AM: Fetching octokit 4.14.0
11:06:10 AM: Installing octokit 4.14.0
11:06:10 AM: Fetching typhoeus 1.3.1
11:06:11 AM: Installing typhoeus 1.3.1
11:06:11 AM: Fetching github-pages-health-check 1.16.1
11:06:11 AM: Installing github-pages-health-check 1.16.1
11:06:11 AM: Fetching rb-fsevent 0.10.3
11:06:11 AM: Installing rb-fsevent 0.10.3
11:06:11 AM: Fetching rb-inotify 0.10.0
11:06:11 AM: Installing rb-inotify 0.10.0
11:06:11 AM: Fetching sass-listen 4.0.0
11:06:11 AM: Installing sass-listen 4.0.0
11:06:11 AM: Fetching sass 3.7.4
11:06:11 AM: Installing sass 3.7.4
11:06:12 AM: Fetching jekyll-sass-converter 1.5.2
11:06:12 AM: Installing jekyll-sass-converter 1.5.2
11:06:12 AM: Fetching ruby_dep 1.5.0
11:06:12 AM: Installing ruby_dep 1.5.0
11:06:12 AM: Fetching listen 3.1.5
11:06:12 AM: Installing listen 3.1.5
11:06:12 AM: Fetching jekyll-watch 2.2.1
11:06:12 AM: Installing jekyll-watch 2.2.1
11:06:12 AM: Fetching kramdown 1.17.0
11:06:12 AM: Installing kramdown 1.17.0
11:06:13 AM: Fetching liquid 4.0.0
11:06:13 AM: Installing liquid 4.0.0
11:06:13 AM: Fetching mercenary 0.3.6
11:06:13 AM: Installing mercenary 0.3.6
11:06:13 AM: Fetching pathutil 0.16.2
11:06:13 AM: Installing pathutil 0.16.2
11:06:13 AM: Fetching rouge 2.2.1
11:06:13 AM: Installing rouge 2.2.1
11:06:13 AM: Fetching safe_yaml 1.0.5
11:06:13 AM: Installing safe_yaml 1.0.5
11:06:13 AM: Fetching jekyll 3.7.4
11:06:13 AM: Installing jekyll 3.7.4
11:06:14 AM: Fetching jekyll-avatar 0.6.0
11:06:14 AM: Installing jekyll-avatar 0.6.0
11:06:14 AM: Fetching jekyll-coffeescript 1.1.1
11:06:14 AM: Installing jekyll-coffeescript 1.1.1
11:06:14 AM: Fetching jekyll-commonmark 1.3.1
11:06:14 AM: Installing jekyll-commonmark 1.3.1
11:06:14 AM: Fetching jekyll-commonmark-ghpages 0.1.5
11:06:14 AM: Installing jekyll-commonmark-ghpages 0.1.5
11:06:14 AM: Fetching jekyll-default-layout 0.1.4
11:06:14 AM: Installing jekyll-default-layout 0.1.4
11:06:14 AM: Fetching jekyll-feed 0.11.0
11:06:14 AM: Installing jekyll-feed 0.11.0
11:06:14 AM: Fetching jekyll-gist 1.5.0
11:06:14 AM: Installing jekyll-gist 1.5.0
11:06:14 AM: Fetching jekyll-github-metadata 2.12.1
11:06:14 AM: Installing jekyll-github-metadata 2.12.1
11:06:14 AM: Fetching mini_portile2 2.4.0
11:06:14 AM: Installing mini_portile2 2.4.0
11:06:15 AM: Fetching nokogiri 1.10.2
11:06:15 AM: Installing nokogiri 1.10.2 with native extensions
11:07:16 AM: Fetching html-pipeline 2.11.0
11:07:16 AM: Installing html-pipeline 2.11.0
11:07:16 AM: Fetching jekyll-mentions 1.4.1
11:07:16 AM: Installing jekyll-mentions 1.4.1
11:07:16 AM: Fetching jekyll-optional-front-matter 0.3.0
11:07:16 AM: Installing jekyll-optional-front-matter 0.3.0
11:07:16 AM: Fetching jekyll-paginate 1.1.0
11:07:16 AM: Installing jekyll-paginate 1.1.0
11:07:16 AM: Fetching jekyll-readme-index 0.2.0
11:07:16 AM: Installing jekyll-readme-index 0.2.0
11:07:16 AM: Fetching jekyll-redirect-from 0.14.0
11:07:16 AM: Installing jekyll-redirect-from 0.14.0
11:07:17 AM: Fetching jekyll-relative-links 0.6.0
11:07:17 AM: Installing jekyll-relative-links 0.6.0
11:07:17 AM: Fetching rubyzip 1.2.2
11:07:17 AM: Installing rubyzip 1.2.2
11:07:17 AM: Fetching jekyll-remote-theme 0.3.1
11:07:17 AM: Installing jekyll-remote-theme 0.3.1
11:07:17 AM: Fetching jekyll-seo-tag 2.5.0
11:07:17 AM: Installing jekyll-seo-tag 2.5.0
11:07:17 AM: Fetching jekyll-sitemap 1.2.0
11:07:17 AM: Installing jekyll-sitemap 1.2.0
11:07:17 AM: Fetching jekyll-swiss 0.4.0
11:07:17 AM: Installing jekyll-swiss 0.4.0
11:07:17 AM: Fetching jekyll-theme-architect 0.1.1
11:07:17 AM: Installing jekyll-theme-architect 0.1.1
11:07:17 AM: Fetching jekyll-theme-cayman 0.1.1
11:07:18 AM: Installing jekyll-theme-cayman 0.1.1
11:07:18 AM: Fetching jekyll-theme-dinky 0.1.1
11:07:18 AM: Installing jekyll-theme-dinky 0.1.1
11:07:18 AM: Fetching jekyll-theme-hacker 0.1.1
11:07:18 AM: Installing jekyll-theme-hacker 0.1.1
11:07:18 AM: Fetching jekyll-theme-leap-day 0.1.1
11:07:18 AM: Installing jekyll-theme-leap-day 0.1.1
11:07:18 AM: Fetching jekyll-theme-merlot 0.1.1
11:07:18 AM: Installing jekyll-theme-merlot 0.1.1
11:07:18 AM: Fetching jekyll-theme-midnight 0.1.1
11:07:18 AM: Installing jekyll-theme-midnight 0.1.1
11:07:19 AM: Fetching jekyll-theme-minimal 0.1.1
11:07:19 AM: Installing jekyll-theme-minimal 0.1.1
11:07:19 AM: Fetching jekyll-theme-modernist 0.1.1
11:07:19 AM: Installing jekyll-theme-modernist 0.1.1
11:07:19 AM: Fetching jekyll-theme-primer 0.5.3
11:07:19 AM: Installing jekyll-theme-primer 0.5.3
11:07:19 AM: Fetching jekyll-theme-slate 0.1.1
11:07:19 AM: Installing jekyll-theme-slate 0.1.1
11:07:19 AM: Fetching jekyll-theme-tactile 0.1.1
11:07:19 AM: Installing jekyll-theme-tactile 0.1.1
11:07:19 AM: Fetching jekyll-theme-time-machine 0.1.1
11:07:19 AM: Installing jekyll-theme-time-machine 0.1.1
11:07:19 AM: Fetching jekyll-titles-from-headings 0.5.1
11:07:20 AM: Installing jekyll-titles-from-headings 0.5.1
11:07:20 AM: Fetching jemoji 0.10.2
11:07:20 AM: Installing jemoji 0.10.2
11:07:20 AM: Fetching minima 2.5.0
11:07:20 AM: Installing minima 2.5.0
11:07:20 AM: Fetching unicode-display_width 1.5.0
11:07:20 AM: Installing unicode-display_width 1.5.0
11:07:20 AM: Fetching terminal-table 1.8.0
11:07:20 AM: Installing terminal-table 1.8.0
11:07:20 AM: Fetching github-pages 197
11:07:20 AM: Installing github-pages 197
11:07:20 AM: Bundle complete! 2 Gemfile dependencies, 85 gems now installed.
11:07:20 AM: Bundled gems are installed into `/opt/build/cache/bundle`
11:07:20 AM: Post-install message from dnsruby:
11:07:20 AM: Installing dnsruby...
11:07:20 AM:   For issues and source code: https://github.com/alexdalitz/dnsruby
11:07:20 AM:   For general discussion (please tell us how you use dnsruby): https://groups.google.com/forum/#!forum/dnsruby
11:07:20 AM: Post-install message from sass:
11:07:20 AM: Ruby Sass has reached end-of-life and should no longer be used.
11:07:20 AM: * If you use Sass as a command-line tool, we recommend using Dart Sass, the new
11:07:20 AM:   primary implementation: https://sass-lang.com/install
11:07:20 AM: * If you use Sass as a plug-in for a Ruby web framework, we recommend using the
11:07:20 AM:   sassc gem: https://github.com/sass/sassc-ruby#readme
11:07:20 AM: * For more details, please refer to the Sass blog:
11:07:20 AM:   https://sass-lang.com/blog/posts/7828841
11:07:20 AM: Post-install message from html-pipeline:
11:07:20 AM: -------------------------------------------------
11:07:20 AM: Thank you for installing html-pipeline!
11:07:20 AM: You must bundle Filter gem dependencies.
11:07:20 AM: See html-pipeline README.md for more details.
11:07:20 AM: https://github.com/jch/html-pipeline#dependencies
11:07:20 AM: -------------------------------------------------
11:07:20 AM: Gem bundle installed
11:07:20 AM: Started restoring cached go cache
11:07:20 AM: Finished restoring cached go cache
11:07:22 AM: failed during stage 'building site': Build script returned non-zero exit code: 1
11:07:20 AM: unset GOOS;
11:07:20 AM: unset GOARCH;
11:07:22 AM: Shutting down logging, 22 messages pending
#2

Hi, @bwanicur! I think the error itself might be hidden. This is the log line which make me suspect this:

11:07:22 AM: Shutting down logging, 22 messages pending

This means the build image shut down before all logs were uploaded.

The recommended way to get the full logs is to add two commands to the end of the existing build command:

  • sleep (with a number of seconds as an argument)
  • false

We add sleep (with a # of seconds) to keep the build image running while the logs upload. The false command is added to make sure we don’t publish the failing build.

To clarify, false is needed because sleep will exit with a zero (0) exit code. Zero exit code indicate a success. False returns one (1) and will cause the build to fail.

If false isn’t added, just adding sleep by itself will cause the build bot to publish the failing build (and that is not ideal).

So, lets say you current build command is this:

jekyll build

The new command would be this:

jekyll build ; sleep 120 ; false

This means: run the build, wait two minutes, then fail.

Would you please try this and see if the full log do contain an error (currently hidden)?