|
18 | 18 |
|
19 | 19 | from wcwidth import wcswidth
|
20 | 20 |
|
21 |
| -import curtsies |
22 |
| -from curtsies import FSArray, fmtstr, FmtStr, Termmode |
23 |
| -from curtsies import fmtfuncs |
24 |
| -from curtsies import events |
25 |
| - |
26 |
| -import bpython |
27 |
| -from bpython.repl import Repl as BpythonRepl, SourceNotFound |
28 |
| -from bpython.repl import LineTypeTranslator as LineType |
| 21 | +from curtsies import ( |
| 22 | + FSArray, |
| 23 | + fmtstr, |
| 24 | + FmtStr, |
| 25 | + Termmode, |
| 26 | + fmtfuncs, |
| 27 | + events, |
| 28 | + __version__ as curtsies_version, |
| 29 | +) |
| 30 | +from curtsies.configfile_keynames import keymap as key_dispatch |
| 31 | + |
| 32 | +from bpython import __version__ |
| 33 | +from bpython.repl import ( |
| 34 | + Repl as BpythonRepl, |
| 35 | + SourceNotFound, |
| 36 | + LineTypeTranslator as LineType, |
| 37 | +) |
29 | 38 | from bpython.config import getpreferredencoding
|
30 | 39 | from bpython.formatter import BPythonFormatter
|
31 | 40 | from bpython import autocomplete
|
32 | 41 | from bpython.translations import _
|
33 | 42 | from bpython.pager import get_pager_command
|
34 | 43 |
|
35 |
| -from bpython.curtsiesfrontend import replpainter as paint |
36 |
| -from bpython.curtsiesfrontend import sitefix |
37 |
| -from bpython.curtsiesfrontend.coderunner import ( |
| 44 | +from . import events as bpythonevents, sitefix, replpainter as paint |
| 45 | +from .coderunner import ( |
38 | 46 | CodeRunner,
|
39 | 47 | FakeOutput,
|
40 | 48 | is_main_thread,
|
41 | 49 | )
|
42 |
| -from bpython.curtsiesfrontend.filewatch import ModuleChangedEventHandler |
43 |
| -from bpython.curtsiesfrontend.interaction import StatusBar |
44 |
| -from bpython.curtsiesfrontend.manual_readline import edit_keys |
45 |
| -from bpython.curtsiesfrontend import events as bpythonevents |
46 |
| -from bpython.curtsiesfrontend.parse import parse as bpythonparse |
47 |
| -from bpython.curtsiesfrontend.parse import func_for_letter, color_for_letter |
48 |
| -from bpython.curtsiesfrontend.preprocess import preprocess |
49 |
| -from bpython.curtsiesfrontend.interpreter import ( |
| 50 | +from .filewatch import ModuleChangedEventHandler |
| 51 | +from .interaction import StatusBar |
| 52 | +from .manual_readline import edit_keys |
| 53 | +from .parse import parse as bpythonparse, func_for_letter, color_for_letter |
| 54 | +from .preprocess import preprocess |
| 55 | +from .interpreter import ( |
50 | 56 | Interp,
|
51 | 57 | code_finished_will_parse,
|
52 | 58 | )
|
53 | 59 |
|
54 |
| -from curtsies.configfile_keynames import keymap as key_dispatch |
55 | 60 |
|
56 | 61 | logger = logging.getLogger(__name__)
|
57 | 62 |
|
@@ -1996,7 +2001,7 @@ def version_help_text(self):
|
1996 | 2001 | """
|
1997 | 2002 | ).format(example_config_url=EXAMPLE_CONFIG_URL, config=self.config)
|
1998 | 2003 |
|
1999 |
| - return f"bpython-curtsies version {bpython.__version__} using curtsies version {curtsies.__version__}\n{help_message}" |
| 2004 | + return f"bpython-curtsies version {__version__} using curtsies version {curtsies_version}\n{help_message}" |
2000 | 2005 |
|
2001 | 2006 | def key_help_text(self):
|
2002 | 2007 | NOT_IMPLEMENTED = (
|
|
0 commit comments