Open LinusU opened 7 years ago
I should also not that piping to a fs.createWriteStream('test.mp3')
works perfectly 🤔
Having the same issue where it hangs for a bit when encoding and then after an arbitrary amount of time it resumes and flushes. For me it happens right before flush. It randomly will decide to either flush immediately or wait about a minute or so and then flush.
Is this basically the issue you're having?
Oh, actually, I never tried waiting more than a few seconds, will do that and see if it starts pushing data again...
I can confirm that your
setInterval(() => encoder.resume(), 1000)
Works as a workaround. It works for me, too! Both decoding and encoding. What is the issue that it gets clogged?
I'm using node v6.9.4 on Gentoo and v6.10.2 on Ubuntu and the problem happens on both.
For some reason the stream cuts out after just a few kilobytes, it seems like something is wrong with flowing/paused mode and back pressure buffering... just guessing here...
Minimal test case:
The behaviour could then be observed with e.g.
curl
:Here it hanged after receiving 9113 bytes.
For some strange reason the following code works:
@TooTallNate if you have any ideas that would be greatly appreciated! If you have time, would you mind just trying to run this on your computer and see if it works?