From 6f06dd97b30ba2bed40d580f3dc966dc9be103fd Mon Sep 17 00:00:00 2001 From: Todd Leonhardt Date: Sat, 9 Jun 2018 18:57:13 -0400 Subject: Working on improving type hinting Also: - Refactored perror() to remove a rarely used optional argument which was unecessary --- cmd2/pyscript_bridge.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'cmd2/pyscript_bridge.py') diff --git a/cmd2/pyscript_bridge.py b/cmd2/pyscript_bridge.py index 196be82b..7e7b940d 100644 --- a/cmd2/pyscript_bridge.py +++ b/cmd2/pyscript_bridge.py @@ -10,7 +10,7 @@ Released under MIT license, see LICENSE file import argparse import functools import sys -from typing import List, Tuple, Callable +from typing import List, Callable # Python 3.4 require contextlib2 for temporarily redirecting stderr and stdout if sys.version_info < (3, 5): @@ -298,4 +298,5 @@ class PyscriptBridge(object): return commands def __call__(self, args: str): - return _exec_cmd(self._cmd2_app, functools.partial(self._cmd2_app.onecmd_plus_hooks, args + '\n'), self.cmd_echo) + return _exec_cmd(self._cmd2_app, functools.partial(self._cmd2_app.onecmd_plus_hooks, args + '\n'), + self.cmd_echo) -- cgit v1.2.1