def write_file(self, file_object, filename):

        file_object.seek(0, os.SEEK_END)
        file_size = file_object.tell()
        file_object.seek(0)

        file_path = os.path.join(self.DROPBOX_DIRECTORY, filename)
        file_number = 0

        while file_object.tell() < file_size:

            upload_id = None
            chunk = None
            numbered_file_offset = 0

            numbered_file_size = min(self.DBBACKUP_DROPBOX_FILE_SIZE_LIMIT, file_size - file_object.tell())

            while numbered_file_offset < numbered_file_size:
                chunk_size = min(CHUNK_SIZE, numbered_file_size - numbered_file_offset)
                if chunk is None:
                    chunk = file_object.read(chunk_size)

                for try_number in range(RETRY_COUNT + 1):
                    try:
                        numbered_file_offset, upload_id = self.dropbox.upload_chunk(chunk, chunk_size, numbered_file_offset, upload_id)
                        chunk = None
                    except dropbox.rest.ErrorResponse:
                        print('    Chunk upload failed')
                        if try_number == RETRY_COUNT:
                            raise
                        else:
                            print('    Retry')
                    else:
                        break

                upload_progress = file_object.tell() / file_size * 100
                print('    Uploaded {:4.1f}%'.format(upload_progress))

            numbered_file_path = self.get_numbered_path(file_path, file_number)
            numbered_file_full_path = os.path.join(self.dropbox.session.root, numbered_file_path)

            print('    Commit to {}'.format(numbered_file_path))
            self.dropbox.commit_chunked_upload(numbered_file_full_path, upload_id)

            file_number += 1
Return the keys for the records.
dataset/ETHPy150Open django-dbbackup/django-dbbackup/dbbackup/storage/dropbox_storage.py/Storage.write_file--crossover with--dataset/ETHPy150Open nigelsmall/py2neo/py2neo/packages/neo4j/v1/session.py/StatementResult.keys