Sh: 1: react-scripts: not found Build error 2

I tried all the suggestions above (fixing warnings, CI= npm…) when i build it locally it build successfully,
i tried changing to yarn command, i tried deleting json-lock like warning suggested.

Build failed due to a user error: Build script returned non-zero exit code: 2
8:40:17 PM: > netlify-react-express-client@1.0.0 build /opt/build/repo/client
8:40:17 PM: > react-scripts build
8:40:17 PM: sh: 1: react-scripts: not found
8:40:17 PM: npm ERR! code ELIFECYCLE
8:40:17 PM: npm ERR! syscall spawn
8:40:17 PM: npm ERR! file sh
8:40:17 PM: npm ERR! errno ENOENT
8:40:17 PM: npm ERR! netlify-react-express-client@1.0.0 build: `react-scripts build`
8:40:17 PM: npm ERR! spawn ENOENT

git repo:
Netlify deploy path:
full log: /opt/buildhome/.npm/_logs/2020-12-20T18_52_01_586Z-debug.log

please advise…

hi there, i moved this thread from its original location, as it is a different error.

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!