'Generates course blocks for the given course_keys per the given options.'

def _generate_course_blocks(self, options, course_keys):

    if options.get('with_storage'):
        waffle().override_for_request(STORAGE_BACKING_FOR_CACHE)
    for course_key in course_keys:
        try:
            self._generate_for_course(options, course_key)
        except Exception as ex:
            log.exception(u'BlockStructure:    An    error    occurred    while    generating    course    blocks    for    %s:    %s', unicode(course_key), ex.message)
