Puppeteer causes "disk full"-related problems


Glitch doesn’t seem to handle “uninstalling” Puppeteer very well and so when I’m typing away into the editor, and Puppeteer’s install keeps getting interrupted due to the auto-save/restart, it seems to leave around some files or something and steadily fill up the disk space.

I first started getting a disk full error and then that turned into this error:

(node:1060) UnhandledPromiseRejectionWarning: Error: Chromium revision is not downloaded. Run "npm install" or "yarn install"
    at Launcher.launch (/app/node_modules/puppeteer/lib/Launcher.js:118:15)

I copied all the code to a new project and then it worked fine again.

Here’s the old project with the errors:


And here’s new new one without the errors:


The fact that it works fine when I copy my code across to a new project makes me think that this is a glitch but, rather than a mistake on my part.


It could be because your not using PNPM. Run enable-pnpm in the console. When using PNPM your node_modules folder doesn’t counts towards disk usage


Thanks! Looks like that solved it - I’ll remember that in the future.


I tried running enable-pnpm and it seemed to fix the issue for a few days, but my project is acting up when trying to install puppeteer:

ERROR: Failed to download Chromium r637110! Set "PUPPETEER_SKIP_CHROMIUM_DOWNLOAD" env variable to skip download.

{ Error: ENOSPC: no space left on device, write

Project: https://glitch.com/~emoji-gender-reveal


Hey @nleigh sorry for the bother! Your project was stuck in a bad install which I fixed on the backend. Things should be looking better now!

1 Like

Thanks! Any tips for how to prevent that problem in the future?


Unfortunately no useful ones; we think this might be caused by a race condition between some steps of the install process, so shorter install times may encounter it less often, but that’s not a particularly valuable mitigation for most projects, unless your package.json has a lot of cruft in it, but that doesn’t appear to be the case in this project.