def _get_file_version(self, infile):
        """Returns infile version string."""

        # Determine file version
        for line1 in infile:
            if line1.strip() != "[Pyspread save file version]":
                raise ValueError(_("File format unsupported."))
            break

        for line2 in infile:
            return line2.strip()
def _get_file_version ( self , infile ) : for line1 in infile : if line1 . strip ( ) != "[Pyspread save file version]" : raise ValueError ( _ ( "File format unsupported." ) ) break for line2 in infile : return line2 . strip ( )
Returns infile version string.