Deploy failed during building site

*Site name: profound-kulfi-b755df ( Site has not yet been deployed)

*My DNS: www.andyengineer.dev

  • Build problems :frowning:

9:49:54 PM: build-image version: 5b0ab77c5e46895703390c45e86a907d4b78547b (focal)
9:49:54 PM: buildbot version: 5b0ab77c5e46895703390c45e86a907d4b78547b
9:49:54 PM: Building without cache
9:49:54 PM: Starting to prepare the repo for build
9:49:54 PM: No cached dependencies found. Cloning fresh repo
9:49:54 PM: git clone --filter=blob:none https://github.com/Andy-Aranda/andysite
9:49:55 PM: Preparing Git Reference refs/heads/main
9:49:57 PM: Parsing package.json dependencies
9:49:57 PM: Starting build script
9:49:57 PM: Installing dependencies
9:49:57 PM: Python version set to 2.7
9:49:58 PM: Downloading and installing node v16.19.1…
9:49:58 PM: Downloading https://nodejs.org/dist/v16.19.1/node-v16.19.1-linux-x64.tar.xz…
9:49:58 PM: Computing checksum with sha256sum
9:49:58 PM: Checksums matched!
9:50:00 PM: Now using node v16.19.1 (npm v8.19.3)
9:50:00 PM: Enabling Node.js Corepack
9:50:00 PM: Started restoring cached build plugins
9:50:00 PM: Finished restoring cached build plugins
9:50:00 PM: Attempting Ruby version 2.7.2, read from environment
9:50:01 PM: Using Ruby version 2.7.2
9:50:01 PM: Using PHP version 8.0
9:50:01 PM: Started restoring cached go cache
9:50:01 PM: Finished restoring cached go cache
9:50:01 PM: go version go1.19.6 linux/amd64
9:50:01 PM: Detected 1 framework(s)
9:50:01 PM: β€œhugo” at version β€œunknown”
9:50:01 PM: Installing missing commands
9:50:01 PM: Verify run directory
9:50:01 PM: Section completed: initializing
9:50:03 PM: ​
9:50:03 PM: Netlify Build
9:50:03 PM: ────────────────────────────────────────────────────────────────
9:50:03 PM: ​
9:50:03 PM: ❯ Version
9:50:03 PM: @netlify/build 29.5.7
9:50:03 PM: ​
9:50:03 PM: ❯ Flags
9:50:03 PM: baseRelDir: true
9:50:03 PM: buildId: 63eef95dd0713217bf80cc2f
9:50:03 PM: deployId: 63eef95dd0713217bf80cc31
9:50:03 PM: ​
9:50:03 PM: ❯ Current directory
9:50:03 PM: /opt/build/repo
9:50:03 PM: ​
9:50:03 PM: ❯ Config file
9:50:03 PM: No config file was defined: using default values.
9:50:03 PM: ​
9:50:03 PM: ❯ Context
9:50:03 PM: production
9:50:03 PM: ​
9:50:03 PM: 1. Build command from Netlify app
9:50:03 PM: ────────────────────────────────────────────────────────────────
9:50:03 PM: ​
9:50:03 PM: $ hugo
9:50:03 PM: Start building sites …
9:50:03 PM: hugo v0.85.0-724D5DB5+extended linux/amd64 BuildDate=2021-07-05T10:46:28Z VendorInfo=gohugoio
9:50:03 PM: ERROR 2023/02/17 03:50:03 Failed to get JSON resource β€œhttps://api.twitter.com/1/statuses/oembed.json?id=GoHugoIO&dnt=false”: Failed to retrieve remote file: Bad Request, body: β€œ{"errors":[{"code":358,"message":"Unable to parse id parameter."}]}”
9:50:03 PM: If you feel that this should not be logged as an ERROR, you can ignore it by adding this to your site config:
9:50:03 PM: ignoreErrors = [β€œerror-remote-getjson”]
9:50:03 PM: Error: Error building site: logged 1 error(s)
9:50:03 PM: Total in 321 ms
9:50:03 PM: ​
9:50:03 PM: β€œbuild.command” failed
9:50:03 PM: ────────────────────────────────────────────────────────────────
9:50:03 PM: ​
9:50:03 PM: Error message
9:50:03 PM: Command failed with exit code 255: hugo (Search results for '"non-zero exit code: 255"' - Netlify Support Forums)
9:50:03 PM: ​
9:50:03 PM: Error location
9:50:03 PM: In Build command from Netlify app:
9:50:03 PM: hugo
9:50:03 PM: ​
9:50:03 PM: Resolved config
9:50:03 PM: build:
9:50:03 PM: command: hugo
9:50:03 PM: commandOrigin: ui
9:50:03 PM: publish: /opt/build/repo/public
9:50:03 PM: publishOrigin: ui
9:50:04 PM: Caching artifacts
9:50:04 PM: Started saving build plugins
9:50:04 PM: Finished saving build plugins
9:50:04 PM: Started saving pip cache
9:50:04 PM: Finished saving pip cache
9:50:04 PM: Started saving emacs cask dependencies
9:50:04 PM: Finished saving emacs cask dependencies
9:50:04 PM: Started saving maven dependencies
9:50:05 PM: Failed during stage β€˜building site’: Build script returned non-zero exit code: 2 (Search results for '"non-zero exit code: 2"' - Netlify Support Forums)
9:50:04 PM: Finished saving maven dependencies
9:50:04 PM: Started saving boot dependencies
9:50:04 PM: Finished saving boot dependencies
9:50:04 PM: Started saving rust rustup cache
9:50:04 PM: Finished saving rust rustup cache
9:50:04 PM: Started saving go dependencies
9:50:04 PM: Finished saving go dependencies
9:50:05 PM: Build failed due to a user error: Build script returned non-zero exit code: 2
9:50:05 PM: Failing build: Failed to build site
9:50:05 PM: Finished processing build request in 11.168s

The error you’re experiencing and a way to resolve it are all shown in the log here:

It’s failed to load a file from api.twitter.com and it throws an error.

Errors cause your build to fail.

It indicates if you want it to be ignored you can add ignoreErrors = [β€œerror-remote-getjson”] to your site config.

Thank you Nathan for sharing this. @andydev please let us know if this helps with your issue. (: