Skip to content

Commit

Permalink
pep8
Browse files Browse the repository at this point in the history
  • Loading branch information
bcolsen committed Jun 25, 2018
1 parent 9379600 commit 4b0a2d6
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
6 changes: 3 additions & 3 deletions spyder/plugins/ipythonconsole.py
Original file line number Diff line number Diff line change
Expand Up @@ -1025,11 +1025,11 @@ def run_cell(self, code, cell_name, filename):
is_internal_kernal = False
if client is not None:
# Internal kernels, use runcell
if True:#client.get_kernel() is not None:
if True: # client.get_kernel() is not None:
line = "{}('{}','{}')".format('runcell', norm(cell_name),
norm(filename))
is_internal_kernal = True
else: # External kernels, just execute the code
else: # External kernels, just execute the code
line = code.strip()

try:
Expand All @@ -1056,7 +1056,7 @@ def run_cell(self, code, cell_name, filename):
self.visibility_changed(True)
self.raise_()
else:
#XXX: not sure it can really happen
# XXX: not sure it can really happen
QMessageBox.warning(self, _('Warning'),
_("No IPython console is currently available to run <b>%s</b>."
"<br><br>Please open a new one and try again."
Expand Down
5 changes: 3 additions & 2 deletions spyder/widgets/editor.py
Original file line number Diff line number Diff line change
Expand Up @@ -2460,12 +2460,13 @@ def advance_cell(self, reverse=False):
term.setFocus()

def re_run_last_cell(self):
text, line = self.get_current_editor().get_last_cell_as_executable_code()
text, line = self.get_current_editor().\
get_last_cell_as_executable_code()
self._run_cell_text(text, line)

def _run_cell_text(self, text, line):
"""Run a cell text in the console
text(str): the text in the cell
line(int): the cell starting line
"""
Expand Down

0 comments on commit 4b0a2d6

Please sign in to comment.