Deploying Static site(React), resulting in this error

Mar 17 02:17:03 PM ==> Installing dependencies with npm…
Mar 17 02:17:12 PM audited 1492 packages in 8.43s
Mar 17 02:17:13 PM
Mar 17 02:17:13 PM 232 packages are looking for funding
Mar 17 02:17:13 PM run npm fund for details
Mar 17 02:17:13 PM
Mar 17 02:17:13 PM found 2 high severity vulnerabilities
Mar 17 02:17:13 PM run npm audit fix to fix them, or npm audit for details
Mar 17 02:17:21 PM audited 1492 packages in 8.049s
Mar 17 02:17:22 PM
Mar 17 02:17:22 PM 232 packages are looking for funding
Mar 17 02:17:22 PM run npm fund for details
Mar 17 02:17:22 PM
Mar 17 02:17:22 PM found 2 high severity vulnerabilities
Mar 17 02:17:22 PM run npm audit fix to fix them, or npm audit for details
Mar 17 02:17:32 PM ==> Using Python version: 3.7.10
Mar 17 02:17:35 PM ==> Running build command ‘npm run build’…
Mar 17 02:17:35 PM
Mar 17 02:17:35 PM > frontend@0.1.0 build /opt/render/project/src/frontend
Mar 17 02:17:35 PM > react-scripts build
Mar 17 02:17:35 PM
Mar 17 02:17:35 PM sh: 1: react-scripts: Permission denied
Mar 17 02:17:35 PM npm ERR! code ELIFECYCLE
Mar 17 02:17:35 PM npm ERR! errno 126
Mar 17 02:17:35 PM npm ERR! frontend@0.1.0 build: react-scripts build
Mar 17 02:17:35 PM npm ERR! Exit status 126
Mar 17 02:17:35 PM npm ERR!
Mar 17 02:17:35 PM npm ERR! Failed at the frontend@0.1.0 build script.
Mar 17 02:17:35 PM npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
Mar 17 02:17:35 PM
Mar 17 02:17:35 PM npm ERR! A complete log of this run can be found in:
Mar 17 02:17:35 PM npm ERR! /opt/render/.cache/_logs/2023-03-17T08_47_35_864Z-debug.log
Mar 17 02:17:35 PM ==> Build failed :disappointed:

package.json
{
“name”: “frontend”,
“version”: “0.1.0”,
“private”: true,
“dependencies”: {
“@testing-library/jest-dom”: “^5.16.5”,
“@testing-library/react”: “^13.4.0”,
“@testing-library/user-event”: “^13.5.0”,
“axios”: “^1.3.4”,
“bootstrap”: “^5.2.3”,
“react”: “^18.2.0”,
“react-dom”: “^18.2.0”,
“react-router-dom”: “^6.8.2”,
“react-scripts”: “5.0.1”,
“web-vitals”: “^2.1.4”
},
“scripts”: {
“start”: “react-scripts start”,
“build”: “react-scripts build”,
“test”: “react-scripts test”,
“eject”: “react-scripts eject”
},
“eslintConfig”: {
“extends”: [
“react-app”,
“react-app/jest”
]
},
“browserslist”: {
“production”: [
“>0.2%”,
“not dead”,
“not op_mini all”
],
“development”: [
“last 1 chrome version”,
“last 1 firefox version”,
“last 1 safari version”
]
}
}

Hi,

We’ve seen this sort of issue before, it usually occurs if you’ve committed your node_modules folder.

Alan

Yeah, you are right!
Thanks

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.