Closed NithinBiliya closed 5 years ago
Same issue; folder with 2016 items:
❯ imageoptim --imagealpha ~/Projects/[...]/uploads/2015/04/
i Running ImageAlpha...
i Running ImageOptim...
! stderr maxBuffer exceeded
! Please raise an issue at https://github.com/JamieMason/ImageOptim-CLI/issues
MaxBufferError: stderr maxBuffer exceeded
at PassThrough.stream.on (/usr/local/Cellar/imageoptim-cli/2.0.4/libexec/dist/imageoptim:15882:19)
at PassThrough.emit (events.js:187:15)
at addChunk (_stream_readable.js:283:12)
at readableAddChunk (_stream_readable.js:260:13)
at PassThrough.Readable.push (_stream_readable.js:219:10)
at PassThrough.Transform.push (_stream_transform.js:151:32)
at PassThrough.afterTransform (_stream_transform.js:92:10)
at PassThrough._transform (_stream_passthrough.js:42:3)
at PassThrough.Transform._read (_stream_transform.js:190:10)
at PassThrough.Transform._write (_stream_transform.js:178:12)
macOS 10.14.3 imageoptim-cli 2.0.4 ImageOptim 1.8.8 ImageAlpha 1.5.1
Same issue with 500 files.
macOS 10.14.4 imageoptim-cli 2.0.4 ImageOptim 1.8.8 ImageAlpha 1.5.1
Same issue with 1365 files.
macOS 10.14.4 imageoptim-cli 2.0.4 ImageOptim 1.8.8 ImageAlpha 1.5.1
Same issue. Any workaround?
My work around is just don’t use it for batch processing itself. Example will be using find ... -exec ....
which is single threaded (imageoptim cannot be run in multiple instances.) A bit better is to use find ... -print0 xargs -0 -n ...
to pass multiple paths to imageoptim for multithreading.
Steps To Reproduce The Error
Run imageoptim-cli on a large number of files (eg - 3409)
Expected Behaviour
optimizes all the files
Actual Behaviour
exception thrown - MaxBufferError: stderr maxBuffer exceeded
Version Numbers or N/A
imageoptim-cli version - 2.3.5
Error stack -