astropy/astropy — pull request #2470 by embray (2014-05-12 21:41:33+00:00)
Title: Follup to #2463...

which fixes a regression I noticed only Python 2.7.3 down to 2.7.0. This provides a slightly reworked fix to single out StringIO.StringIO for special treatment and leave writing to interfaces that support the modern buffer interface.

This should be included in 3.2. It should be the last thing holding up release at this point.