Home
Support Forums

Build problems Failed to compile

hi, i have a problems to Deploy

I already tried CI= npm run build

I searched on google, but without success. I can deploy from my terminal, but recently, my updates have not been deployed (I specify that this is not a problem linked to github )
thank you

my website : https://distracted-wescoff-ed6f52.netlify.app/

my netifly.toml = [build]
command = β€œCI= npm run build”
publish = β€œ/build”
base = β€œ.”

────────────────────────────────────────────────────────────────
6:29:15 PM: β€œbuild.command” failed
6:29:15 PM: ────────────────────────────────────────────────────────────────
6:29:15 PM: ​
6:29:15 PM: Error message
6:29:15 PM: Command failed with exit code 1: CI= npm run build
6:29:15 PM: ​
6:29:15 PM: Error location
6:29:15 PM: In build.command from netlify.toml:
6:29:15 PM: CI= npm run build
6:29:15 PM: ​
6:29:15 PM: Resolved config
6:29:15 PM: build:
6:29:15 PM: base: /opt/build/repo
6:29:15 PM: command: CI= npm run build
6:29:15 PM: commandOrigin: config
6:29:15 PM: publish: /opt/build/repo/build
6:29:15 PM: redirects:
6:29:16 PM: - from: /* status: 200 to: /index.htmlCaching artifacts
6:29:16 PM: Started saving node modules
6:29:16 PM: Finished saving node modules
6:29:16 PM: Started saving build plugins
6:29:16 PM: Finished saving build plugins
6:29:16 PM: Started saving pip cache
6:29:16 PM: Finished saving pip cache
6:29:16 PM: Started saving emacs cask dependencies
6:29:16 PM: Finished saving emacs cask dependencies
6:29:16 PM: Started saving maven dependencies
6:29:16 PM: Finished saving maven dependencies
6:29:16 PM: Started saving boot dependencies
6:29:16 PM: Finished saving boot dependencies
6:29:16 PM: Started saving rust rustup cache
6:29:16 PM: Finished saving rust rustup cache
6:29:16 PM: Started saving rust cargo bin cache
6:29:16 PM: Finished saving rust cargo bin cache
6:29:16 PM: Started saving go dependencies
6:29:16 PM: Finished saving go dependencies
6:29:19 PM: Build failed due to a user error: Build script returned non-zero exit code: 2
6:29:19 PM: Failing build: Failed to build site
6:29:19 PM: Failed during stage β€˜building site’: Build script returned non-zero exit code: 2
6:29:19 PM: Finished processing build request in 1m55.914905902s

Hiya, sorry you are having trouble with your build.

This Support Guide contains a ton of useful debugging tips that can likely help you solve your problem :slight_smile:

We also recommend trying to search the forums with the build error you encountered - it’s likely your question was already asked by someone else!

If you are still having problems, please provide as much information as you can on what you have already tried, what your build settings are, your package.json, etc. Thanks!

here is my package.json, ( I searched on all your forums )

{

β€œname”: β€œtemplate”,

β€œversion”: β€œ0.1.0”,

β€œprivate”: true,

β€œdependencies”: {

"@firebase/app": "^0.6.13",

"@firebase/auth": "^0.16.1",

"@fortawesome/fontawesome-svg-core": "^1.2.32",

"@fortawesome/free-brands-svg-icons": "^5.15.1",

"@fortawesome/free-regular-svg-icons": "^5.15.1",

"@fortawesome/free-solid-svg-icons": "^5.15.1",

"@fortawesome/react-fontawesome": "^0.1.11",

"@material-ui/core": "^4.11.0",

"@material-ui/icons": "^4.9.1",

"@testing-library/jest-dom": "^4.2.4",

"@testing-library/react": "^9.5.0",

"@testing-library/user-event": "^7.2.1",

"@types/react-transition-group": "^4.4.0",

"bootstrap": "^4.5.2",

"bootstrap-icons": "^1.1.0",

"express": "^4.17.1",

"firebase": "^8.0.2",

"firebase-admin": "^9.4.1",

"i18next": "^17.0.14",

"i18next-browser-languagedetector": "^3.0.3",

"i18next-xhr-backend": "^3.1.2",

"netlify": "^6.0.9",

"netlify-cli": "^3.0.0",

"react": "^16.13.1",

"react-axios": "^2.0.3",

"react-bootstrap": "^1.3.0",

"react-cookie-consent": "^6.1.0",

"react-dom": "^16.13.1",

"react-external-link": "^1.1.1",

"react-i18next": "^10.12.4",

"react-image-filter": "^0.1.2",

"react-image-lightbox": "^5.1.1",

"react-multi-carousel": "^2.5.5",

"react-particles-js": "^3.3.0",

"react-router-dom": "^5.2.0",

"react-router-external": "^1.0.2",

"react-scripts": "3.4.3",

"react-slideshow-image": "^1.5.3",

"react-transition-group": "^4.4.1",

"react-typical": "^0.1.3",

"react-unity-webgl": "^7.1.10",

"request": "^2.88.2",

"styled-components": "^5.2.1",

"uuid": "^8.3.0",

"web-vitals": "^0.2.4"

},

β€œscripts”: {

"start": "react-scripts start",

"build": "react-scripts build",

"test": "react-scripts test",

"eject": "react-scripts eject"

},

β€œeslintConfig”: {

"extends": "react-app"

},

β€œbrowserslist”: {

"production": [

  ">0.2%",

  "not dead",

  "not op_mini all"

],

"development": [

  "last 1 chrome version",

  "last 1 firefox version",

  "last 1 safari version"

]

},

β€œdevDependencies”: {

"gh-pages": "^3.1.0"

}

}

Hey @spirithacodesh,

Sorry it’s taken us a while! I can see that, in the meantime, you have managed to deploy your site :tada:!

I did take a look at your most recent failure, in this deploy, I could see the following:

6:48:43 PM: Cannot find file './components/ArtistesDecors/ArtistesDecors' in './src'.

It looks like you were trying to build something that wasn’t available in your repo. If you’re still having issues, could you check to make sure that this is available in the repo?