Wait for compute stats to finish before closing the cursor
Merge pull request #1 from stripe/fix-compute-stats

Wait for compute stats to finish before closing the cursor