11# -*- coding: utf-8 -*-
22# Copyright (C) 2009-2010, 2013-2015,
3- # 2017-2018 Rocky Bernstein <rocky@gnu.org>
3+ # 2017-2018, 2020 Rocky Bernstein <rocky@gnu.org>
44#
55# This program is free software: you can redistribute it and/or modify
66# it under the terms of the GNU General Public License as published by
@@ -89,7 +89,7 @@ def close(self):
8989 return
9090
9191 def confirm (self , prompt , default ):
92- """ Called when a dangerous action is about to be done, to make
92+ """Called when a dangerous action is about to be done, to make
9393 sure it's okay. Expect a yes/no answer to `prompt' which is printed,
9494 suffixed with a question mark and the default value. The user
9595 response converted to a boolean is returned."""
@@ -114,9 +114,20 @@ def confirm(self, prompt, default):
114114 pass
115115 return default
116116
117- def errmsg (self , msg , prefix = "** " ):
118- """Common routine for reporting debugger error messages.
117+ def msg (self , msg ):
118+ """used to write to a debugger that is connected to this
119+ server; `str' written will have a newline added to it
119120 """
121+ super ().msg (msg )
122+ # from pydoc import ttypager
123+ # if hasattr(self.output, "isatty"):
124+ # ttypager(msg)
125+ # super().msg("")
126+ # else:
127+ # super().msg(msg)
128+
129+ def errmsg (self , msg , prefix = "** " ):
130+ """Common routine for reporting debugger error messages."""
120131 return self .msg ("%s%s" % (prefix , msg ))
121132
122133 def finalize (self , last_wishes = None ):
0 commit comments