mattdesl / canvas-sketch

[beta] A framework for making generative artwork in JavaScript and the browser.
MIT License
5.01k stars 393 forks source link

Export-Error: TypeError: Cannot read properties of null (reading 'encoding') #141

Closed SHrdrDesign closed 2 years ago

SHrdrDesign commented 2 years ago

Hi everybody! Canvas Sketch doesn't let me export animations anymore. I always get the following error code:

TypeError: Cannot read properties of null (reading 'encoding') at C:\Users\zBook 15G7\AppData\Roaming\npm\node_modules\canvas-sketch-cli\src\middleware.js:189:56 at C:\Users\zBook 15G7\AppData\Roaming\npm\node_modules\canvas-sketch-cli\node_modules\mkdirp\index.js:49:26 at FSReqCallback.oncomplete (node:fs:199:5)

It has worked with the same installation before. Any ideas what might be the problem and how to solve it? (I'm quite new to coding, so I don't know if this question is completely stupid :D)

PavelMelnyk commented 2 years ago

same issues here maybe some trouble with @ffmpeg-installer/ffmpeg on mac m1

lancesnider commented 2 years ago

I'm on a pre-m1 laptop and am having the same issue. I also get the same error when I try to record as a series of images, which doesn't use @ffmpeg-installer/ffmpeg

lancesnider commented 2 years ago

It looks like there's another issue about this same problem: https://github.com/mattdesl/canvas-sketch/issues/133. That one has a little more discussion and a potential solution (though I haven't gotten it to work yet).

mattdesl commented 2 years ago

Should be fixed, please update and try again: https://github.com/mattdesl/canvas-sketch/issues/133#issuecomment-1231560638