Went to deploy my site, it worked fine earlier today, but has now brought up this error. Anyone have any pointers? New to dealing with websites. I use the blogdown package in R and the theme LoveIt. The repository is on Git, and deploys via Netlify.
9:46:35 PM: ────────────────────────────────────────────────────────────────
9:46:35 PM: 1. build.command from netlify.toml
9:46:35 PM: ────────────────────────────────────────────────────────────────
9:46:35 PM:
9:46:35 PM: $ hugo
9:46:35 PM: Start building sites …
9:46:35 PM: hugo v0.101.0-466fa43c16709b4483689930a4f9ac8add5c9f66+extended linux/amd64 BuildDate=2022-06-16T07:09:16Z VendorInfo=gohugoio
9:46:35 PM: ERROR 2022/08/22 02:46:35 render of "page" failed: "/opt/build/repo/themes/LoveIt/layouts/posts/single.html:41:33": execute of template failed: template: posts/single.html:41:33: executing "content" at <.Params.categories>: range can't iterate over Research
Error: Error building site: failed to render pages: render of "home" failed: "/opt/build/repo/themes/LoveIt/layouts/index.html:36:20": execute of template failed: template: index.html:36:20: executing "content" at <.Render>: error calling Render: "/opt/build/repo/content/posts/mosquito-activity-and-weather/index.en.md:1:1": failed to execute template _default/summary.html: "/opt/build/repo/themes/LoveIt/layouts/_default/summary.html:41:25": execute of template failed: template: _default/summary.html:41:25: executing "_default/summary.html" at <.Params.categories>: range can't iterate over Research
Total in 236 ms
9:46:35 PM:
9:46:35 PM: ────────────────────────────────────────────────────────────────
9:46:35 PM: "build.command" failed
9:46:35 PM: ────────────────────────────────────────────────────────────────
9:46:35 PM:
9:46:35 PM: Error message
9:46:35 PM: Command failed with exit code 255: hugo (https://ntl.fyi/exit-code-255)
9:46:35 PM:
9:46:35 PM: Error location
9:46:35 PM: In build.command from netlify.toml:
9:46:35 PM: hugo
9:46:35 PM:
9:46:35 PM: Resolved config
9:46:35 PM: build:
9:46:35 PM: command: hugo
9:46:35 PM: commandOrigin: config
9:46:35 PM: environment:
9:46:35 PM: - HUGO_VERSION
9:46:35 PM: - NETLIFY_GRAPH_TOKEN
9:46:35 PM: - ONEGRAPH_AUTHLIFY_TOKEN
9:46:35 PM: - HUGO_ENV
9:46:35 PM: publish: /opt/build/repo/public
9:46:35 PM: publishOrigin: config
9:46:36 PM: Caching artifacts
9:46:36 PM: Started saving build plugins
9:46:36 PM: Finished saving build plugins
9:46:36 PM: Started saving pip cache
9:46:36 PM: Finished saving pip cache
9:46:36 PM: Started saving emacs cask dependencies
9:46:36 PM: Finished saving emacs cask dependencies
9:46:36 PM: Started saving maven dependencies
9:46:36 PM: Finished saving maven dependencies
9:46:36 PM: Started saving boot dependencies
9:46:36 PM: Finished saving boot dependencies
9:46:36 PM: Started saving rust rustup cache
9:46:36 PM: Finished saving rust rustup cache
9:46:36 PM: Started saving go dependencies
9:46:36 PM: Finished saving go dependencies
9:46:37 PM: Build failed due to a user error: Build script returned non-zero exit code: 2
9:46:37 PM: Creating deploy upload records
9:46:37 PM: Failing build: Failed to build site
9:46:37 PM: Failed during stage 'building site': Build script returned non-zero exit code: 2 (https://ntl.fyi/exit-code-2)
9:46:37 PM: Finished processing build request in 13.962789296s
In R, when I try to deploy the site locally, I get this error:
Launching the server via the command:
C:/Users/12045/AppData/Roaming/Hugo/0.101.0/hugo.exe server --bind 127.0.0.1 -p 4321 --themesDir themes -t LoveIt -D -F --navigateToChanged
Error: Error building site: failed to render pages: render of "home" failed: "C:\Projects\Website\themes\LoveIt\layouts\index.html:36:20": execute of template failed: template: index.html:36:20: executing "content" at <.Render>: error calling Render: "C:\Projects\Website\content\posts\mosquito-activity-and-weather\index.en.md:1:1": failed to execute template _default/summary.html: "C:\Projects\Website\themes\LoveIt\layouts\_default\summary.html:41:25": execute of template failed: template: _default/summary.html:41:25: executing "_default/summary.html" at <.Params.categories>: range can't iterate over Research
In addition: Warning message:
In if (is.na(c3)) vars = c(vars, HUGO_IGNOREERRORS = "error-remote-getjson") :
the condition has length > 1 and only the first element will be used
Related
Never had a problem uploading a website on Netlify before not sure why it is not letting me deploy. Changed the build setting under my server and public so i have it as "/server/public" but don't know if netlify is reading that. When i try to visit my site i get a 404 url not found.
7:21:00 PM: build-image version: d7b3813f01c06610bc1723ff1b22446513ee7941 (focal)
7:21:00 PM: build-image tag: v4.14.3
7:21:00 PM: buildbot version: be0925a1b4e8f8d2c5a767f3e0decf8856cad273
7:21:00 PM: Fetching cached dependencies
7:21:00 PM: Failed to fetch cache, continuing with build
7:21:00 PM: Starting to prepare the repo for build
7:21:00 PM: No cached dependencies found. Cloning fresh repo
7:21:00 PM: git clone https://github.com/roycejwilliams/kimiee_kreates
7:21:02 PM: Preparing Git Reference refs/heads/main
7:21:03 PM: Parsing package.json dependencies
7:21:04 PM: Different build dir detected, going to use the one specified in the Netlify configuration file: 'server' versus '/server' in the Netlify UI
7:21:04 PM: Different publish path detected, going to use the one specified in the Netlify configuration file: 'server/public' versus 'public' in the Netlify UI
7:21:04 PM: Starting build script
7:21:04 PM: Installing dependencies
7:21:04 PM: Python version set to 2.7
7:21:04 PM: Downloading and installing node v16.18.1...
7:21:04 PM: Downloading https://nodejs.org/dist/v16.18.1/node-v16.18.1-linux-x64.tar.xz...
7:21:05 PM: Computing checksum with sha256sum
7:21:05 PM: Checksums matched!
7:21:07 PM: Now using node v16.18.1 (npm v8.19.2)
7:21:07 PM: Enabling node corepack
7:21:07 PM: Started restoring cached build plugins
7:21:07 PM: Finished restoring cached build plugins
7:21:07 PM: Attempting ruby version 2.7.2, read from environment
7:21:08 PM: Using ruby version 2.7.2
7:21:08 PM: Using PHP version 8.0
7:21:08 PM: No npm workspaces detected
7:21:08 PM: Started restoring cached node modules
7:21:08 PM: Finished restoring cached node modules
7:21:09 PM: Installing NPM modules using NPM version 8.19.2
7:21:09 PM: added 59 packages, and audited 60 packages in 632ms
7:21:09 PM: 7 packages are looking for funding
7:21:09 PM: run `npm fund` for details
7:21:10 PM: found 0 vulnerabilities
7:21:10 PM: NPM modules installed
7:21:10 PM: Creating package sha
7:21:10 PM: Started restoring cached go cache
7:21:10 PM: Finished restoring cached go cache
7:21:10 PM: Installing Go version 1.17 (requested 1.17)
7:21:14 PM: unset GOOS;
7:21:14 PM: unset GOARCH;
7:21:14 PM: export GOROOT='/opt/buildhome/.gimme/versions/go1.17.linux.amd64';
7:21:14 PM: export 2
This is the what the log files are showing on netlify
────────────────────────────────────────────────────────────────
5:26:11 PM: 1. #netlify/plugin-nextjs (onPreBuild event)
5:26:11 PM: ────────────────────────────────────────────────────────────────
5:26:11 PM:
5:26:11 PM: No Next.js cache to restore.
5:26:11 PM: Netlify configuration property "build.environment.NEXT_PRIVATE_TARGET" value changed.
5:26:11 PM:
5:26:11 PM: (#netlify/plugin-nextjs onPreBuild completed in 28ms)
5:26:11 PM:
5:26:11 PM: ────────────────────────────────────────────────────────────────
5:26:11 PM: 2. Build command from Netlify app
5:26:11 PM: ────────────────────────────────────────────────────────────────
5:26:11 PM:
5:26:11 PM: $ yarn build
5:26:11 PM: yarn run v1.22.17
5:26:12 PM: $ next build
5:26:12 PM: warn - No build cache found. Please configure build caching for faster rebuilds. Read more: https://nextjs.org/docs/messages/no-cache
5:26:12 PM: info - Checking validity of types...
5:26:17 PM: Failed to compile.
5:26:17 PM:
5:26:17 PM: ./node_modules/mongoose/types/cursor.ts:1:1
5:26:17 PM: Type error: Import assignment cannot be used when targeting ECMAScript modules. Consider using 'import * as ns from "mod"', 'import {a} from "mod"', 'import d from "mod"', or another module format instead.
5:26:17 PM: > 1 | import stream = require('stream');
5:26:17 PM: | ^
5:26:17 PM: 2 |
5:26:17 PM: 3 | declare module 'mongoose' {
5:26:17 PM: 4 | type CursorFlag = 'tailable' | 'oplogReplay' | 'noCursorTimeout' | 'awaitData' | 'partial';
5:26:17 PM: error Command failed with exit code 1.
5:26:17 PM: info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
5:26:17 PM:
5:26:17 PM: ────────────────────────────────────────────────────────────────
5:26:17 PM: "build.command" failed
5:26:17 PM: ────────────────────────────────────────────────────────────────
5:26:17 PM:
Locally the build is successful. I added environment variables on netlify to ensure versions of node and yarn are the same as those local and it stil fails.
I tried the solution of replacing module on tsconfi.json from
"module": "esnext"
to
"module": "commonjs"
The only time the build on netlify works is when typescript errors are set to be ignored.
Any ideas on how to build successfully if i don't want to ignore typescript errors?
I'd try using import or require syntax here
import stream from "steam"
// Or
const stream = require ('stream')
I'm trying to deploy my nuxt js project to netlify. The installation part works fine, But it returns an error in the build process.
I tried to search google but I can't find any solution to this problem.
I also tried this command CI= npm run generate
3:16:42 PM: $ npm run generate
3:16:43 PM: > portfolio#1.0.0 generate
3:16:43 PM: > nuxt generate
3:16:50 PM: node: ../src/coroutine.cc:134: void* find_thread_id_key(void*): Assertion `thread_id_key != 0x7777' failed.
Aborted
3:16:50 PM:
3:16:50 PM: ────────────────────────────────────────────────────────────────
3:16:50 PM: "build.command" failed
3:16:50 PM: ────────────────────────────────────────────────────────────────
3:16:50 PM:
3:16:50 PM: Error message
3:16:50 PM: Command failed with exit code 134: npm run generate
3:16:50 PM:
3:16:50 PM: Error location
3:16:50 PM: In Build command from Netlify app:
3:16:50 PM: npm run generate
3:16:50 PM:
3:16:50 PM: Resolved config
3:16:50 PM: build:
3:16:50 PM: command: npm run generate
3:16:50 PM: commandOrigin: ui
3:16:50 PM: publish: /opt/build/repo/dist
3:16:50 PM: publishOrigin: ui
3:16:50 PM: Caching artifacts
3:16:50 PM: Started saving node modules
3:16:50 PM: Finished saving node modules
3:16:50 PM: Started saving build plugins
3:16:50 PM: Finished saving build plugins
3:16:50 PM: Started saving pip cache
3:16:50 PM: Finished saving pip cache
3:16:50 PM: Started saving emacs cask dependencies
3:16:50 PM: Finished saving emacs cask dependencies
3:16:50 PM: Started saving maven dependencies
3:16:50 PM: Finished saving maven dependencies
3:16:50 PM: Started saving boot dependencies
3:16:50 PM: Finished saving boot dependencies
3:16:50 PM: Started saving rust rustup cache
3:16:50 PM: Finished saving rust rustup cache
3:16:50 PM: Started saving go dependencies
3:16:50 PM: Finished saving go dependencies
3:16:52 PM: Build failed due to a user error: Build script returned non-zero exit code: 2
3:16:52 PM: Creating deploy upload records
3:16:52 PM: Failing build: Failed to build site
3:16:52 PM: Failed during stage 'building site': Build script returned non-zero exit code: 2
3:16:52 PM: Finished processing build request in 1m34.230804646s
Here is the Nuxt Config -
My target is to build a static site. You may guess this is my portfolio site. I'm working on my portfolio to get a better job.
nuxt.config.js
export default {
// Target: https://go.nuxtjs.dev/config-target
target: 'static',
// Global page headers: https://go.nuxtjs.dev/config-head
head: {
title: 'Hasibur',
htmlAttrs: {
lang: 'en'
},
meta: [
{ charset: 'utf-8' },
{ name: 'viewport', content: 'width=device-width, initial-scale=1' },
{ hid: 'description', name: 'description', content: '' },
{ name: 'format-detection', content: 'telephone=no' }
],
link: [
{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' }
]
},
// Global CSS: https://go.nuxtjs.dev/config-css
css: [
'#/assets/scss/main.scss'
],
// Plugins to run before rendering page: https://go.nuxtjs.dev/config-plugins
plugins: [
{ src: '~/plugins/components.js', mode: 'client' },
{ src: '~/plugins/fontawesome.js', mode: 'client' },
],
// Auto import components: https://go.nuxtjs.dev/config-components
components: true,
// Modules for dev and build (recommended): https://go.nuxtjs.dev/config-modules
buildModules: [
// https://go.nuxtjs.dev/tailwindcss
'#nuxtjs/tailwindcss',
],
// Modules: https://go.nuxtjs.dev/config-modules
modules: [
// https://go.nuxtjs.dev/axios
'#nuxtjs/axios',
],
// Axios module configuration: https://go.nuxtjs.dev/config-axios
axios: {},
// Build Configuration: https://go.nuxtjs.dev/config-build
build: {
}
}
I just had the same problem and solved it thanks to this question. The problem seems to be fibers.
The steps I took to fix it:
uninstall fibers: npm uninstall fibers
delete package-lock.json & node_modules/
install packages again: npm install
Simply removing fibers from package.json isn't enough as Netlify seems to still find the package in package-lock.json.
Github repo [https://github.com/NaveenJc10/Naveen]
Could someone please help me to solve this issue. Thank you
12:07:21 PM: Build ready to start
12:07:23 PM: build-image version: 0582042f4fc261adc7bd8333f34884959c577302
12:07:23 PM: build-image tag: v3.7.6
12:07:23 PM: buildbot version: cb3d235979bae64f617d34524cb2e8a9de68153f
12:07:23 PM: Fetching cached dependencies
12:07:23 PM: Failed to fetch cache, continuing with build
12:07:23 PM: Starting to prepare the repo for build
12:07:24 PM: No cached dependencies found. Cloning fresh repo
12:07:24 PM: git clone https://github.com/NaveenJc10/Naveen
12:07:25 PM: Preparing Git Reference refs/heads/main
12:07:25 PM: Parsing package.json dependencies
12:07:27 PM: Starting build script
12:07:27 PM: Installing dependencies
12:07:27 PM: Python version set to 2.7
12:07:28 PM: v12.18.0 is already installed.
12:07:29 PM: Now using node v12.18.0 (npm v6.14.4)
12:07:29 PM: Started restoring cached build plugins
12:07:29 PM: Finished restoring cached build plugins
12:07:29 PM: Attempting ruby version 2.7.1, read from environment
12:07:31 PM: Using ruby version 2.7.1
12:07:31 PM: Using PHP version 5.6
12:07:31 PM: Started restoring cached node modules
12:07:31 PM: Finished restoring cached node modules
12:07:31 PM: Installing NPM modules using NPM version 6.14.4
12:07:47 PM: > deasync#0.1.21 install /opt/build/repo/node_modules/deasync
12:07:47 PM: > node ./build.js
12:07:47 PM: linux-x64-node-12 exists; testing
12:07:47 PM: Binary is fine; exiting
12:07:47 PM: > core-js#2.6.12 postinstall /opt/build/repo/node_modules/core-js
12:07:47 PM: > node -e “try{require(’./postinstall’)}catch(e){}”
12:07:47 PM: > parcel-bundler#1.12.4 postinstall /opt/build/repo/node_modules/parcel-bundler
12:07:47 PM: > node -e “console.log(’\u001b[35m\u001b[1mLove Parcel? You can now donate to our open collective:\u001b[22m\u001b[39m\n > \u001b[34mhttps://opencollective.com/parcel/donate\u001b[0m’)”
12:07:47 PM: Love Parcel? You can now donate to our open collective:
12:07:47 PM: > Contribute to Parcel - Open Collective
12:07:48 PM: npm WARN Naveen#1.0.0 No description
12:07:48 PM: npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents#1.2.13 (node_modules/fsevents):
12:07:48 PM: npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents#1.2.13: wanted {“os”:“darwin”,“arch”:“any”} (current: {“os”:“linux”,“arch”:“x64”})
12:07:48 PM: added 766 packages from 461 contributors and audited 768 packages in 15.721s
12:07:48 PM: 46 packages are looking for funding
12:07:48 PM: run npm fund for details
12:07:48 PM: found 68 vulnerabilities (67 moderate, 1 high)
12:07:48 PM: run npm audit fix to fix them, or npm audit for details
12:07:48 PM: NPM modules installed
12:07:49 PM: Started restoring cached go cache
12:07:49 PM: Finished restoring cached go cache
12:07:49 PM: go version go1.14.4 linux/amd64
12:07:49 PM: go version go1.14.4 linux/amd64
12:07:49 PM: Installing missing commands
12:07:49 PM: Verify run directory
12:07:51 PM:
12:07:51 PM: ────────────────────────────────────────────────────────────────
12:07:51 PM: Netlify Build
12:07:51 PM: ────────────────────────────────────────────────────────────────
12:07:51 PM:
12:07:51 PM: ❯ Version
12:07:51 PM: #netlify/build 11.18.1
12:07:51 PM:
12:07:51 PM: ❯ Flags
12:07:51 PM: deployId: 60ac77f9aa712200a9963afb
12:07:51 PM:
12:07:51 PM: ❯ Current directory
12:07:51 PM: /opt/build/repo
12:07:51 PM:
12:07:51 PM: ❯ Config file
12:07:51 PM: No config file was defined: using default values.
12:07:51 PM:
12:07:51 PM: ❯ Context
12:07:51 PM: production
12:07:51 PM:
12:07:51 PM: ────────────────────────────────────────────────────────────────
12:07:51 PM: 1. Build command from Netlify app
12:07:51 PM: ────────────────────────────────────────────────────────────────
12:07:51 PM:
12:07:51 PM: $ parcel build --no-minify index.html
12:07:53 PM: :rotating_light: /opt/build/repo/images/logo.svg: Invalid Version: undefined
12:07:53 PM: at new SemVer (/opt/build/repo/node_modules/#babel/preset-env/node_modules/semver/semver.js:314:11)
12:07:53 PM: at compare (/opt/build/repo/node_modules/#babel/preset-env/node_modules/semver/semver.js:647:10)
12:07:53 PM: at lt (/opt/build/repo/node_modules/#babel/preset-env/node_modules/semver/semver.js:688:10)
12:07:53 PM: at /opt/build/repo/node_modules/#babel/preset-env/lib/index.js:274:22
12:07:53 PM: at Object.default (/opt/build/repo/node_modules/#babel/helper-plugin-utils/lib/index.js:22:12)
12:07:53 PM: at getEnvPlugins (/opt/build/repo/node_modules/parcel-bundler/src/transforms/babel/env.js:62:34)
12:07:53 PM: at getEnvConfig (/opt/build/repo/node_modules/parcel-bundler/src/transforms/babel/env.js:12:25)
12:07:53 PM: at async getBabelConfig (/opt/build/repo/node_modules/parcel-bundler/src/transforms/babel/config.js:32:19)
12:07:53 PM: at async babelTransform (/opt/build/repo/node_modules/parcel-bundler/src/transforms/babel/transform.js:6:16)
12:07:53 PM: at async JSAsset.pretransform (/opt/build/repo/node_modules/parcel-bundler/src/assets/JSAsset.js:83:5)
12:07:54 PM:
12:07:54 PM: ────────────────────────────────────────────────────────────────
12:07:54 PM: “build.command” failed
12:07:54 PM: ────────────────────────────────────────────────────────────────
12:07:54 PM:
12:07:54 PM: Error message
12:07:54 PM: Command failed with exit code 1: parcel build --no-minify index.html
12:07:54 PM:
12:07:54 PM: Error location
12:07:54 PM: In Build command from Netlify app:
12:07:54 PM: parcel build --no-minify index.html
12:07:54 PM:
12:07:54 PM: Resolved config
12:07:54 PM: build:
12:07:54 PM: command: parcel build --no-minify index.html
12:07:54 PM: commandOrigin: ui
12:07:54 PM: publish: /opt/build/repo/dist
12:07:54 PM: functions:
12:07:54 PM: ‘*’: {}
12:07:54 PM: Caching artifacts
12:07:54 PM: Started saving node modules
12:07:54 PM: Finished saving node modules
12:07:54 PM: Started saving build plugins
12:07:54 PM: Finished saving build plugins
12:07:54 PM: Started saving pip cache
12:07:54 PM: Finished saving pip cache
12:07:54 PM: Started saving emacs cask dependencies
12:07:54 PM: Finished saving emacs cask dependencies
12:07:54 PM: Started saving maven dependencies
12:07:54 PM: Finished saving maven dependencies
12:07:54 PM: Started saving boot dependencies
12:07:54 PM: Finished saving boot dependencies
12:07:54 PM: Started saving rust rustup cache
12:07:54 PM: Finished saving rust rustup cache
12:07:54 PM: Started saving go dependencies
12:07:54 PM: Finished saving go dependencies
12:07:57 PM: Build failed due to a user error: Build script returned non-zero exit code: 2
12:07:57 PM: Creating deploy upload records
12:07:57 PM: Failing build: Failed to build site
12:07:57 PM: Failed during stage ‘building site’: Build script returned non-zero exit code: 2
12:07:57 PM: Finished processing build request in 33.980133128s
Your html file should be index.html. The second reason, if your app is builded with react you should create also built file
I can't figure out why I can deploy perfectly locally but not working when I manually dropped the build folder online or add my repo with Github method. I got the error like below:
10:21:21 PM: Build ready to start 10:21:22 PM: build-image version:
d84c79427e8f83c1ba17bcdd7b3fe38059376b68 10:21:22 PM: build-image tag:
v3.6.1 10:21:22 PM: buildbot version:
44655717ddf0e7bd7f856f5b1154254de54b1d80 10:21:23 PM: Building without
cache 10:21:23 PM: Starting to prepare the repo for build 10:21:23 PM:
No cached dependencies found. Cloning fresh repo 10:21:23 PM: git
clone https://github.com/celinevalentine/Games 10:21:24 PM: Preparing
Git Reference refs/heads/celinev 10:21:26 PM: Different publish path
detected, going to use the one specified in the Netlify configuration
file: 'build' versus 'build/' in the Netlify UI 10:21:26 PM: Starting
build script 10:21:26 PM: Installing dependencies 10:21:26 PM: Python
version set to 2.7 10:21:27 PM: v12.18.0 is already installed.
10:21:28 PM: Now using node v12.18.0 (npm v6.14.4) 10:21:28 PM:
Started restoring cached build plugins 10:21:28 PM: Finished restoring
cached build plugins 10:21:28 PM: Attempting ruby version 2.7.1, read
from environment 10:21:29 PM: Using ruby version 2.7.1 10:21:29 PM:
Using PHP version 5.6 10:21:29 PM: Started restoring cached go cache
10:21:29 PM: Finished restoring cached go cache 10:21:29 PM: go
version go1.14.4 linux/amd64 10:21:29 PM: go version go1.14.4
linux/amd64 10:21:29 PM: Installing missing commands 10:21:29 PM:
Verify run directory 10:21:31 PM: 10:21:31 PM:
────────────────────────────────────────────────────────────────
10:21:31 PM: Netlify Build
10:21:31 PM:
────────────────────────────────────────────────────────────────
10:21:31 PM: 10:21:31 PM: ❯ Version 10:21:31 PM: #netlify/build
8.3.0 10:21:31 PM: 10:21:31 PM: ❯ Flags 10:21:31 PM: deployId: 6014fae1970bcf9dcb4a28eb 10:21:31 PM: mode: buildbot 10:21:31 PM:
10:21:31 PM: ❯ Current directory 10:21:31 PM: /opt/build/repo
10:21:31 PM: 10:21:31 PM: ❯ Config file 10:21:31 PM: No config
file was defined: using default values. 10:21:31 PM: 10:21:31 PM: ❯
Context 10:21:31 PM: production 10:21:31 PM: 10:21:31 PM:
────────────────────────────────────────────────────────────────
10:21:31 PM: 1. Build command from Netlify app
10:21:31 PM:
────────────────────────────────────────────────────────────────
10:21:31 PM: 10:21:31 PM: $ npm run build 10:21:31 PM: npm ERR! code
ENOENT 10:21:31 PM: npm ERR! syscall open 10:21:31 PM: npm ERR! path
/opt/build/repo/package.json 10:21:31 PM: npm ERR! errno -2 10:21:31
PM: npm ERR! enoent ENOENT: no such file or directory, open
'/opt/build/repo/package.json' 10:21:31 PM: npm ERR! enoent This is
related to npm not being able to find a file. 10:21:31 PM: npm ERR!
enoent 10:21:31 PM: npm ERR! A complete log of this run can be found
in: 10:21:31 PM: npm ERR!
/opt/buildhome/.npm/_logs/2021-01-30T06_21_31_988Z-debug.log 10:21:32
PM: 10:21:32 PM:
────────────────────────────────────────────────────────────────
10:21:32 PM: "build.command" failed
10:21:32 PM:
────────────────────────────────────────────────────────────────
10:21:32 PM: 10:21:32 PM: Error message 10:21:32 PM: Command
failed with exit code 254: npm run build 10:21:32 PM: 10:21:32 PM:
Error location 10:21:32 PM: In Build command from Netlify app:
10:21:32 PM: npm run build 10:21:32 PM: 10:21:32 PM: Resolved
config 10:21:32 PM: build: 10:21:32 PM: command: npm run build
10:21:32 PM: commandOrigin: ui 10:21:32 PM: publish:
/opt/build/repo/build 10:21:32 PM: Caching artifacts 10:21:32 PM:
Started saving build plugins 10:21:32 PM: Finished saving build
plugins 10:21:32 PM: Started saving pip cache 10:21:32 PM: Finished
saving pip cache 10:21:32 PM: Started saving emacs cask dependencies
10:21:32 PM: Finished saving emacs cask dependencies 10:21:32 PM:
Started saving maven dependencies 10:21:32 PM: Finished saving maven
dependencies 10:21:32 PM: Started saving boot dependencies 10:21:32
PM: Finished saving boot dependencies 10:21:32 PM: Started saving rust
rustup cache 10:21:32 PM: Finished saving rust rustup cache 10:21:32
PM: Started saving go dependencies 10:21:32 PM: Finished saving go
dependencies 10:21:35 PM: Build failed due to a user error: Build
script returned non-zero exit code: 2 10:21:35 PM: Failing build:
Failed to build site 10:21:35 PM: Failed during stage 'building site':
Build script returned non-zero exit code: 2 10:21:35 PM: Finished
processing build request in 12.138963808s
Please try
CI= npm run build
instead of the
-> npm run build