Hello, I’m trying to test deploying a new app and getting this. It’s a super simple React application:
App name: https://superb-faloodeh-62e896.netlify.app/
Github Repo: https://github.com/david-chua/findMyWager/tree/main/findmywager
I changed the npm buld to npm run build and the build says it compiled successfully. No errors on my terminal as well.
Changed the CI value to false as what I have seen in other discussions and still no luck.
4:18:51 PM: build-image version: 6cae66f783f2b7ff8e3a9cdbb5031761f0b47719 (focal)
4:18:51 PM: buildbot version: cb74d097ea8f76bcaa16d435b6bf29d5a1715ede
4:18:51 PM: Building without cache
4:18:51 PM: Starting to prepare the repo for build
4:18:51 PM: No cached dependencies found. Cloning fresh repo
4:18:51 PM: git clone --filter=blob:none GitHub - david-chua/findMyWager
4:18:51 PM: Preparing Git Reference refs/heads/main
4:18:52 PM: Custom build path detected. Proceeding with the specified path: ‘findmywager’
4:18:52 PM: Custom publish path detected. Proceeding with the specified path: ‘findmywager/findmywager/build’
4:18:53 PM: Starting to install dependencies
4:18:53 PM: Python version set to 3.8
4:18:53 PM: Attempting Ruby version 2.7.2, read from environment
4:18:53 PM: Using Ruby version 2.7.2
4:18:54 PM: Started restoring cached go cache
4:18:54 PM: Finished restoring cached go cache
4:18:56 PM: go version go1.19.12 linux/amd64
4:18:56 PM: Using PHP version 8.0
4:18:57 PM: v18.17.1 is already installed.
4:18:57 PM: Now using node v18.17.1 (npm v9.6.7)
4:18:57 PM: Enabling Node.js Corepack
4:18:57 PM: Started restoring cached build plugins
4:18:58 PM: Finished restoring cached build plugins
4:18:58 PM: Started restoring cached corepack dependencies
4:18:58 PM: Finished restoring cached corepack dependencies
4:18:58 PM: No npm workspaces detected
4:18:58 PM: Started restoring cached node modules
4:18:58 PM: Finished restoring cached node modules
4:18:58 PM: Installing npm packages using npm version 9.6.7
4:18:59 PM: npm WARN old lockfile
4:18:59 PM: npm WARN old lockfile The package-lock.json file was created with an old version of npm,
4:18:59 PM: npm WARN old lockfile so supplemental metadata must be fetched from the registry.
4:18:59 PM: npm WARN old lockfile
4:18:59 PM: npm WARN old lockfile This is a one-time fix-up, please be patient…
4:18:59 PM: npm WARN old lockfile
4:19:06 PM: npm WARN deprecated w3c-hr-time@ 1.0.2: Use your platform’s native performance.now() and performance.timeOrigin.
npm WARN deprecated stable@ 0.1.8: Modern JS already guarantees Array#sort() is a stable sort, so this library is deprecated. See the compatibility table on MDN: Array.prototype.sort() - JavaScript | MDN
4:19:06 PM: npm WARN deprecated rollup-plugin-terser@ 7.0.2: This package has been deprecated and is no longer maintained. Please use @ rollup/plugin-terser
4:19:07 PM: npm WARN deprecated sourcemap-codec@ 1.4.8: Please use @jridgewell/sourcemap-codec instead
4:19:07 PM: npm WARN deprecated workbox-cacheable-response@ 6.6.0: workbox-background-sync@6.6.0
4:19:09 PM: npm WARN deprecated svgo@ 1.3.2: This SVGO version is no longer supported. Upgrade to v2.x.x.
4:19:14 PM: added 1515 packages, and audited 1516 packages in 16s
4:19:14 PM: 245 packages are looking for funding
4:19:14 PM: run npm fund
for details
4:19:14 PM: 6 high severity vulnerabilities
4:19:14 PM: To address all issues (including breaking changes), run:
4:19:14 PM: npm audit fix --force
4:19:14 PM: Run npm audit
for details.
4:19:14 PM: npm packages installed
4:19:15 PM: Install dependencies script success
4:19:15 PM: Starting build script
4:19:16 PM: Detected 1 framework(s)
4:19:16 PM: create-react-app at version 5.0.1
4:19:16 PM: Section completed: initializing
4:19:17 PM:
4:19:17 PM: Netlify Build
4:19:17 PM: ────────────────────────────────────────────────────────────────
4:19:17 PM:
4:19:17 PM: ❯ Version
4:19:17 PM: @ netlify/build 29.20.6
4:19:17 PM:
4:19:17 PM: ❯ Flags
4:19:17 PM: baseRelDir: true
4:19:17 PM: buildId: 64ee5297683a793001f3269a
4:19:17 PM: deployId: 64ee5297683a793001f3269c
4:19:17 PM:
4:19:17 PM: ❯ Current directory
4:19:17 PM: /opt/build/repo/findmywager
4:19:17 PM:
4:19:17 PM: ❯ Config file
4:19:17 PM: /opt/build/repo/netlify.toml
4:19:17 PM:
4:19:17 PM: ❯ Context
4:19:17 PM: production
4:19:17 PM:
4:19:17 PM: build.command from netlify.toml
4:19:17 PM: ────────────────────────────────────────────────────────────────
4:19:17 PM:
4:19:17 PM: $ npm run build
4:19:18 PM: > findmywager@ 0.1.0 build
4:19:18 PM: > react-scripts build
4:19:19 PM: Creating an optimized production build…
4:19:24 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)
4:19:22 PM: Compiled successfully.
4:19:22 PM:
4:19:22 PM: File sizes after gzip:
4:19:22 PM: 47.71 kB build/static/js/main.d83c19fd.js
4:19:22 PM: 1.78 kB build/static/js/787.b7d4e0ac.chunk.js
4:19:22 PM: 577 B build/static/css/main.82857dcd.css
4:19:22 PM: The project was built assuming it is hosted at /.
4:19:22 PM: You can control this with the homepage field in your package.json.
4:19:22 PM: The build folder is ready to be deployed.
4:19:22 PM: You may serve it with a static server:
4:19:22 PM: npm install -g serve
4:19:22 PM: serve -s build
4:19:22 PM: Find out more about deployment here:
4:19:22 PM: Deployment | Create React App
4:19:23 PM:
4:19:23 PM: (build.command completed in 5s)
4:19:23 PM:
4:19:23 PM: Deploy site
4:19:23 PM: ────────────────────────────────────────────────────────────────
4:19:23 PM:
4:19:23 PM: Section completed: deploying
4:19:23 PM:
4:19:23 PM: Configuration error
4:19:23 PM: ────────────────────────────────────────────────────────────────
4:19:23 PM:
4:19:23 PM: Error message
4:19:23 PM: Deploy did not succeed: Deploy directory ‘findmywager/findmywager/build’ does not exist
4:19:23 PM:
4:19:23 PM: Resolved config
4:19:23 PM: build:
4:19:23 PM: base: /opt/build/repo/findmywager
4:19:23 PM: command: npm run build
4:19:23 PM: commandOrigin: config
4:19:23 PM: environment:
4:19:23 PM: - CI
4:19:23 PM: - DEPRECATED
4:19:23 PM: publish: /opt/build/repo/findmywager/findmywager/build
4:19:23 PM: publishOrigin: config
4:19:23 PM: headers:
4:19:23 PM: - for: /*
values:
Access-Control-Allow-Origin: ‘*’
headersOrigin: config
redirects:
- from: /
status: 200
to: /index.html
redirectsOrigin: config
Caching artifacts
4:19:23 PM: Started saving node modules
4:19:23 PM: Finished saving node modules
4:19:23 PM: Started saving build plugins
4:19:23 PM: Finished saving build plugins
4:19:23 PM: Started saving corepack cache
4:19:23 PM: Finished saving corepack cache
4:19:23 PM: Started saving pip cache
4:19:23 PM: Finished saving pip cache
4:19:23 PM: Started saving emacs cask dependencies
4:19:23 PM: Finished saving emacs cask dependencies
4:19:23 PM: Started saving maven dependencies
4:19:23 PM: Finished saving maven dependencies
4:19:23 PM: Started saving boot dependencies
4:19:23 PM: Finished saving boot dependencies
4:19:23 PM: Started saving rust rustup cache
4:19:23 PM: Finished saving rust rustup cache
4:19:23 PM: Started saving go dependencies
4:19:23 PM: Finished saving go dependencies
4:19:24 PM: Build failed due to a user error: Build script returned non-zero exit code: 2
4:19:24 PM: Failing build: Failed to build site
4:19:24 PM: Finished processing build request in 33.882s