<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def get_books_for_schedule(self, schedule):
 """ Returns a dictionary of data. SLNs are the keys, an array of Book objects are the values. """

        slns = self._get_slns(schedule)

        books = {}

        for sln in slns:
            try:
                section_books = self.get_books_by_quarter_sln(
                    schedule.term.quarter, sln
                )
                books[sln] = section_books
            except DataFailureException:
                # do nothing if bookstore doesn't have sln
                pass
        return books