Rework prompt: add exception classes for errors and reload/quit
This commit is contained in:
parent
0d21b1fa2c
commit
fd6d9288f7
6 changed files with 89 additions and 19 deletions
|
|
@ -69,6 +69,8 @@ class AbstractServer(io.IOBase):
|
|||
if not hasattr(self, "_open") or self._open():
|
||||
_rlist.append(self)
|
||||
_xlist.append(self)
|
||||
return True
|
||||
return False
|
||||
|
||||
|
||||
def close(self):
|
||||
|
|
@ -82,6 +84,8 @@ class AbstractServer(io.IOBase):
|
|||
_wlist.remove(self)
|
||||
if self in _xlist:
|
||||
_xlist.remove(self)
|
||||
return True
|
||||
return False
|
||||
|
||||
|
||||
# Writes
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue