#94·gifify

Maximum call stack size exceeded.

Author: ghostCreated Jun 10, 2017Updated Jul 7, 2023

OS: Debian 8 x64 Node: v8.1.0 NPM: v5.0.3

Receiving this error:

RangeError: Maximum call stack size exceeded
    at emitOne (events.js:113:17)
    at ChildProcess.emit (events.js:210:7)
    at emitOne (events.js:115:13)
    at ChildProcess.emit (events.js:210:7)
    at emitOne (events.js:115:13)
    at ChildProcess.emit (events.js:210:7)
    at emitOne (events.js:115:13)
    at ChildProcess.emit (events.js:210:7)
    at emitOne (events.js:115:13)
    at ChildProcess.emit (events.js:210:7)

With this code:

const express = require('express');
const ydl = require('youtube-dl');
const gifify = require('gifify');
const fs = require('fs');

const app = express();
app.listen(80);

const video = ydl('https://www.youtube.com/watch?v=o-qK3u97iB0');

app.get('/', (req, res) => {
	gifify(video, { fps: 29.97 }).pipe(res);
});