Error: Cannot find module 'puppeteer'

For some reason, when I deploy my API, it seems to fail installing puppeteer. The deployment log shows a

Error: Cannot find module 'puppeteer'

even though the package is clearly listed in package.json

{
	"name": "base-api",
	"version": "1.0.0",
	"description": "",
	"scripts": { ... },
	"author": "",
	"license": "ISC",
	"dependencies": {
		"@prisma/client": "^5.8.1",
		"@sendgrid/mail": "^8.1.0",
		"bcrypt": "^5.1.1",
		"cookie-parser": "^1.4.6",
		"cors": "^2.8.5",
		"crypto": "^1.0.1",
		"dotenv": "^16.3.1",
		"express": "^4.18.2",
		"express-rate-limit": "^7.1.5",
		"express-validator": "^7.0.1",
		"helmet": "^7.1.0",
		"jsonwebtoken": "^9.0.2",
		"morgan": "^1.10.0",
		"nodemailer": "^6.9.8",
		"nodemon": "^3.0.2",
		"pg": "^8.11.3",
		"prisma": "^5.8.1",
		"puppeteer": "^21.10.0",
		"sqlite3": "^5.1.6"
	},
	"devDependencies": {
		"@faker-js/faker": "^8.3.1",
		"eslint": "^8.56.0",
		"jest": "^29.7.0",
		"supertest": "^6.3.4"
	},
	"jest": {
		"setupFiles": [
			"<rootDir>/jest.setup.js"
		]
	}
}

Why is this??

Hi there Enrique,

What is your build command set to?

John B
Render Support, UTC :uk:

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