Jekyll Build Issue

Dear Jekyll expert,

I need your support on resolving this “deploy failed” issue. Detailed information enclosed, few details below.

$ cloudcannon cache pull bundle Calculating hash… not found

$ bundle clean All clean!

$ bundle exec jekyll build Configuration file: vestal-boombox.cloudvent.net/src/_config.yml

jekyll_pages_api_search: checking for Node.js: v10.23.3

jekyll 3.9.0 | Error: undefined local variable or method `page’ for Jekyll:Module

:x: Your build failed, make an update and try again.

Where is that output from? A remote deploy? Or using a local command to deploy?

Run this locally to see more info like which page it is failing on.

bundle exec jekyll build --trace

Do have anything in _plugins dir? Any gems in Gemfile. I see the error happened after use of jekyll_pages_api_search but can’t tell if they are related.

The {{ page }} variable should be available on any markdown or HTML page. Look for all you uses of that to see if you can narrow down the pages which cause the issue.

@michaelcurrin !
Screenshot_2021-02-18 Dashboard - Build Issue|196x500

Many Thanks!!

The output is from online deploy. Not local.

I could find _plugin dir, enclosing a jpeg file of complete error. Kindly see please.

Look forward to your support.
With Kind - Thanks!,

Thanks. Hmm the screenshot is clearer but it doesn’t give a clue.

I’d say run the commands locally.

If you can run these successfully locally, then the problem is on CloudCannon.

bundle install
bundle exec jekyll build

If you can’t run that successfully then your problem is not with CloudCannon but something like your gems or config or pages.

Perhaps Ruby 2.5 is not compatible. See if you can upgrade to 2.6 or 2.7 on CloudCannon

You can also try making a Jekyll site of an index.md page and nothing else and see you can deploy that. I don’t know enough about your project to debug it. So you are going to see if you can get a much simpler project to work locally and then move to CloudCannon and see if that works. And then add pages to the site locally and see if it works and then get that to CloudCannon. When you add a change and then Jekyll errors out, then you know that was what the issue is.

I would recommend removing all plugins from your Gemfile and comment them out in your config. See if your site builds then. You will also have to remove places where you use the now disabled plugin.


Since you are using Jekyll 3.9 I would recommend you put your repo on GitHub and go to settings and enable GitHub Pages and see if that works for you.

If you have any gems not supported by GH Pages you’ll get an error. So Netlify might be good.

You also need Node installed on CloudCannon and locally.

Dear @MichaelCurrin , I would like to thank you for your time and explanation(s). I will follow the steps you suggested, and shall revert with further progress. Many thanks SIR !!!

1 Like

@MichaelCurrin

Few basic questions, I am not using command line and building the site remotely. (Q 1) How do i update my ruby version and (Q 2) I am getting the following error, kindly help me to understand this.

jekyll_pages_api_search: checking for Node.js: v10.23.3

bundler: failed to load command: jekyll (/usr/local/__bundle/ruby/2.5.0/bin/jekyll) /usr/local/__bundle/ruby/2.5.0/gems/jekyll-pwa-plugin-5.1.5/lib/jekyll-pwa-plugin.rb:169:in block in <module:Jekyll>': undefined local variable or method page’ for Jekyll:Module (NameError)

You’re going to have to search Google or CloudCannon docs to update Ruby version and see if you can at all.

Hmm your error tells me Jekyll is missing.

Can you make sure this is in your Gemfile?

gem "jekyll",  "3.9"

Then rerun.

Did you setup this gem or is that part of the CI they do for you?

jekyll-pwa-plugin.rb

If it’s in your Gemfile, you can try upgrading it to a newer version.