2

Question: Why is Heroku stuck on installing node modules on the initial build?

Summary: I have tested this with both Heroku and Netlifty. Both encounter the same issue. I am able to run npm run build locally and it builds fine. I don't have a paid account on either site and both sites only allow posting the question on the forms for free users. I have looked over all the dependencies in the package.json file and there are not any obvious problems. I updated my npm version to the latest 7.21.1 and no difference. So any further help or guidance of what I should check would greatly help.

Deployment on: Heroku

Node version: 16.4.2

NPM version: 7.18.1

Project type: Reactjs

Screenshots to describe terminal build: note to get out of this Heroku stop build has to be performed

terminal showing stuck installing

Package.json file:

{ "name": "hookahsite", "version": "0.1.0", "private": true, "engines": { "node": "16.4" }, "homepage": "https://github.com/bholsinger09/Hookahhouse", "dependencies": { "@react-google-maps/api": "^2.2.0", "@testing-library/jest-dom": "^5.11.4", "@testing-library/react": "^11.1.0", "@testing-library/user-event": "^12.1.10", "axios": "^0.21.1", "react": "^17.0.2", "react-dom": "^17.0.2", "react-router-dom": "^5.2.0", "react-scripts": "4.0.3", "web-vitals": "^1.0.1" }, "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" ] } }


enter image description here

0
2

It normally shouldn't be stuck in the deployment process. if you deploy your code to another instance and it works, the issue might be localized to the instance where your app is located.

Either way, you should probably open a support ticket.

1
  • Thanks for an answer. Yes, normally it shouldn't get stuck in the deployment process. I have tested this with both Heroku and Netlifty. Both encounter the same issue. I am able to run npm run build locally and it builds fine. I don't have a paid account on either site and both sites only allow posting the question on the forms for free users. I have looked over all the dependencies in the package.json file and there are not any obvious problems. I updated my npm version to the latest 7.21.1 and no difference. So any further help or guidance of what I should check would greatly help. Sep 2 at 21:11

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.