From a06e0036f1727db6a81f6de08d15ab7d1e42c020 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Fri, 28 Mar 2014 13:21:57 +0530 Subject: [PATCH] pep8 --- src/calibre/ebooks/mobi/writer8/tbs.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/calibre/ebooks/mobi/writer8/tbs.py b/src/calibre/ebooks/mobi/writer8/tbs.py index 0a522c4301..b338f4be2c 100644 --- a/src/calibre/ebooks/mobi/writer8/tbs.py +++ b/src/calibre/ebooks/mobi/writer8/tbs.py @@ -11,7 +11,7 @@ DOC = ''' Trailing Byte Sequences contain information about which index entries touch a particular text record. Every text records has a set of trailing byte sequences. In order to figure out the sequence for a given text record, you -have to first calculate all the indices that start, end, span and anre +have to first calculate all the indices that start, end, span and are contained within that text record. Then arrange the indices into 'strands', where each strand is a hierarchical progression from the top level index down. For the exact algorithm, see separate_strands(). The strands are then encoded @@ -60,7 +60,7 @@ def populate_strand(parent, entries): children = [c for c in entries if c.parent == entry.index] if children: siblings += populate_strand(entry, entries) - break # Cannot add more siblings, as we have added children + break # Cannot add more siblings, as we have added children else: siblings.append(entry) ans += siblings @@ -176,7 +176,7 @@ def sequences_to_bytes(sequences): flag_size = 3 for val, extra in sequences: ans.append(encode_tbs(val, extra, flag_size)) - flag_size = 4 # only the first sequence has flag size 3 as all + flag_size = 4 # only the first sequence has flag size 3 as all # subsequent sequences could need the 0b1000 flag return b''.join(ans)