Netlify build failed after setting `gatsby-source-airtable`

My previous version of my blog was working fine and I was able to deploy it with Netlify very easily and no errors.

After implementing gatsby-source-airtable and submitting to my repo, Netlify was not able to build my blog presenting the following message.

10:17:43 PM: Build ready to start
10:17:51 PM: build-image version: 9e0f207a27642d0115b1ca97cd5e8cebbe492f63
10:17:51 PM: build-image tag: v3.3.2
10:17:51 PM: buildbot version: a989558813e71e809c732e73f8044218fb8c2868
10:17:51 PM: Fetching cached dependencies
10:17:51 PM: Starting to download cache of 163.7MB
10:17:52 PM: Finished downloading cache in 1.212801851s
10:17:52 PM: Starting to extract cache
10:17:58 PM: Finished extracting cache in 5.704282332s
10:17:58 PM: Finished fetching cache in 6.992646677s
10:17:58 PM: Starting to prepare the repo for build
10:17:58 PM: Preparing Git Reference refs/heads/master
10:17:59 PM: Creating functions prep folder
10:17:59 PM: Starting build script
10:17:59 PM: Installing dependencies
10:18:00 PM: Started restoring cached node version
10:18:02 PM: Finished restoring cached node version
10:18:03 PM: v10.16.3 is already installed.
10:18:04 PM: Now using node v10.16.3 (npm v6.9.0)
10:18:04 PM: Attempting ruby version 2.6.2, read from environment
10:18:05 PM: Using ruby version 2.6.2
10:18:05 PM: Using PHP version 5.6
10:18:05 PM: Started restoring cached node modules
10:18:05 PM: Finished restoring cached node modules
10:18:06 PM: Installing NPM modules using NPM version 6.9.0
10:18:21 PM: npm
10:18:21 PM: WARN eslint-config-react-app@4.0.1 requires a peer of eslint-plugin-flowtype@2.x but none is installed. You must install peer dependencies yourself.
10:18:21 PM: npm
10:18:21 PM:  WARN ts-pnp@1.1.4 requires a peer of typescript@* but none is installed. You must install peer dependencies yourself.
10:18:21 PM: npm
10:18:21 PM:  WARN tsutils@3.17.1 requires a peer of typescript@>=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta but none is installed. You must install peer dependencies yourself.
10:18:21 PM: npm WARN optional
10:18:21 PM:  SKIPPING OPTIONAL DEPENDENCY: fsevents@2.0.7 (node_modules/chokidar/node_modules/fsevents):
10:18:21 PM: npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@2.0.7: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
10:18:21 PM: npm
10:18:21 PM:  WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/fsevents):
10:18:21 PM: npm
10:18:21 PM: WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
10:18:21 PM: added 6 packages from 7 contributors and audited 28090 packages in 14.844s
10:18:21 PM: found 0 vulnerabilities
10:18:21 PM: NPM modules installed
10:18:22 PM: Started restoring cached go cache
10:18:22 PM: Finished restoring cached go cache
10:18:22 PM: unset GOOS;
10:18:22 PM: unset GOARCH;
10:18:22 PM: export GOROOT='/opt/buildhome/.gimme/versions/go1.12.linux.amd64';
10:18:22 PM: export PATH="/opt/buildhome/.gimme/versions/go1.12.linux.amd64/bin:${PATH}";
10:18:22 PM: go version >&2;
10:18:22 PM: export GIMME_ENV='/opt/buildhome/.gimme/env/go1.12.linux.amd64.env';
10:18:22 PM: go version go1.12 linux/amd64
10:18:22 PM: Installing missing commands
10:18:22 PM: Verify run directory
10:18:22 PM: Executing user command: gatsby build
10:18:24 PM: success open and validate gatsby-configs — 0.107
10:18:26 PM: success load plugins — 1.260
10:18:27 PM: failed during stage 'building site': Build script returned non-zero exit code: 1
10:18:26 PM: success onPreInit — 0.013
10:18:26 PM: success delete html and css files from previous builds — 0.019
10:18:26 PM: success initialize cache — 0.016
10:18:27 PM: Shutting down logging, 25 messages pending

Any pointers to why this is happening?
Thank you very much.

Cheers,
Tiago

Hi @tiagofsanchez!

I see this at the end of your log:

10:18:27 PM: Shutting down logging, 25 messages pending

There’s a cool debugging trick that you can use for cases like this to see the rest of the messages. Its described in the post [Support Guide] Deploy logs truncated or showing “Shutting down logging, [number] messages pending”

Let us know if that doesn’t help you solve it!

Hi,

My thinkink is your gatsy failed in an earlier stage:
10:18:27 PM: failed during stage 'building site': Build script returned non-zero exit code: 1

Gatsby lists the error messages after the build phase is completed and that caused the build-image to terminate before the logging could actually happen

A Couple of things you should try out:

  1. You should run gatsby build in your machine
  2. If you the build was successful, check your node version, i suspect on netlify.toml you have set it to v10.16.3 this needs to match with your node version (i had a similar issue with fsevents and this fixed it)
  3. You should commit your yarn.lock (if you’re using yarn) or ‘package-lock.json’ (if you are using npm) files committed to the repository that will ensure that the package version you have locally will be respected during the build phase on netlify

if nothing helps you should also check out what @laura suggested!

Good luck!