votinginfoproject/Metis — pull request #219 by cap10morgan (2014-07-28 19:07:14+00:00)
Title: [WM CS TH] eliminate buggy external unfolding state var

This pauses and resumes the incoming CSV stream instead. You have to
throttle the incoming CSV data or you will overwhelm Node.js's event
queue and crash the process with any real-world-sized CSV files that
also triggered a very-easy-to-trigger bug in the original unfolding boolean
var code. In the MD data we've been testing with, it was triggered by an
error in the source.txt file that didn't crash the whole process (b/c it
was a Mongo save error) but it did cause the feed processing code to
lose the plot as to whether it was unfolding or not. Keeping that state
in an external var was a bad design.