ENH: raise a more a useful exception on empty files