src/dirbs/importer/abstract_importer.py
def _file_to_split(self):
        """Function to return file handle for the file to split."""
        file_to_split = None
        if self._extract:
            try:
                file_to_split = extract_csv_from_zip(self._filename)
                self._perform_filename_checks(file_to_split.name)
            except zipfile.BadZipFile as e:
                raise exceptions.ZipFileCheckException(str(e),
                                                       statsd=self._statsd,
                                                       metrics_failures_root=self._metrics_failures_root)
        else:
            self._perform_filename_checks(self._filename)
            file_to_split = open(self._filename, 'rb')

        return file_to_split
Function to return file handle for the file to split.
Function to return file handle for the file to split.
Function to return file handle for the file to split .
def _file_to_split(self):
        file_to_split = None
        if self._extract:
            try:
                file_to_split = extract_csv_from_zip(self._filename)
                self._perform_filename_checks(file_to_split.name)
            except zipfile.BadZipFile as e:
                raise exceptions.ZipFileCheckException(str(e),
                                                       statsd=self._statsd,
                                                       metrics_failures_root=self._metrics_failures_root)
        else:
            self._perform_filename_checks(self._filename)
            file_to_split = open(self._filename, 'rb')
        return file_to_split
def _file_to_split ( self ) : file_to_split = None if self . _extract : try : file_to_split = extract_csv_from_zip ( self . _filename ) self . _perform_filename_checks ( file_to_split . name ) except zipfile . BadZipFile as e : raise exceptions . ZipFileCheckException ( str ( e ) , statsd = self . _statsd , metrics_failures_root = self . _metrics_failures_root ) else : self . _perform_filename_checks ( self . _filename ) file_to_split = open ( self . _filename , 'rb' ) return file_to_split
Function to return file handle for the file to split.
Function to return file handle for the file to split .
"""Function to return file handle for the file to split."""
self