Skip to content

Commit f7949d5

Browse files
PEP-8 in curtsies repl
1 parent f555a1c commit f7949d5

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

bpython/curtsiesfrontend/repl.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -523,7 +523,7 @@ def process_control_event(self, e):
523523
self.startup()
524524
except IOError as e:
525525
self.status_bar.message(
526-
_('Executing PYTHONSTARTUP failed: %s') % (str(e)))
526+
_('Executing PYTHONSTARTUP failed: %s') % (str(e)))
527527

528528
elif isinstance(e, bpythonevents.UndoEvent):
529529
self.undo(n=e.n)
@@ -621,7 +621,7 @@ def process_key_event(self, e):
621621
# TODO add PAD keys hack as in bpython.cli
622622
elif e in key_dispatch[self.config.edit_current_block_key]:
623623
self.send_current_block_to_external_editor()
624-
elif e in ["<ESC>"]: #ESC
624+
elif e in ["<ESC>"]:
625625
self.incremental_search_mode = None
626626
elif e in ["<SPACE>"]:
627627
self.add_normal_character(' ')
@@ -636,11 +636,11 @@ def last_word(line):
636636
previous_word = last_word(self.rl_history.entry)
637637
word = last_word(self.rl_history.back())
638638
line = self.current_line
639-
self._set_current_line(line[:len(line)-len(previous_word)] + word,
639+
self._set_current_line(line[:len(line) - len(previous_word)] + word,
640640
reset_rl_history=False)
641641
self._set_cursor_offset(
642-
self.cursor_offset-len(previous_word) + len(word),
643-
reset_rl_history=False)
642+
self.cursor_offset-len(previous_word) + len(word),
643+
reset_rl_history=False)
644644

645645
def incremental_search(self, reverse=False, include_current=False):
646646
if self.incremental_search_mode is None:
@@ -870,7 +870,7 @@ def add_to_incremental_search(self, char=None, backspace=False):
870870
elif self.incremental_search_mode == 'incremental_search':
871871
self.incremental_search(include_current=True)
872872
else:
873-
raise ValueError('add_to_incremental_search should only be called in a special mode')
873+
raise ValueError('add_to_incremental_search not in a special mode')
874874

875875
def update_completion(self, tab=False):
876876
"""Update visible docstring and matches, and possibly hide/show completion box"""

0 commit comments

Comments
 (0)