teepark / greenhouse

non-blocking IO with coroutines to mimic blocking IO with threads
BSD 3-Clause "New" or "Revised" License
36 stars 5 forks source link

fh.write() emits jumbled data. #14

Closed dsully closed 12 years ago

dsully commented 12 years ago

This feels like a recent regression, I didn't see this say, a week and a half ago.

Part of my process generates some JSON (using simplejson) and then writes it out to an open file handle:

      with open(filename, 'w') as fh:
        fh.write(dm.to_json())

The output of that JSON file now has jumbled data near the end (last write chunk?) that then causes a subsequent JSON decode to fail.

teepark commented 12 years ago

can you check if 6fdb09b fixes this?

dsully commented 12 years ago

Yep!