mirror of
https://github.com/jlu5/PyLink.git
synced 2024-12-25 04:02:45 +01:00
Move ProtocolError to utils, and link the copy in classes to it
This commit is contained in:
parent
89699051d5
commit
d28006ae62
@ -28,12 +28,7 @@ except ImportError:
|
|||||||
from . import world, utils, structures, conf, __version__
|
from . import world, utils, structures, conf, __version__
|
||||||
from .log import *
|
from .log import *
|
||||||
from .coremods import control
|
from .coremods import control
|
||||||
|
from .utils import ProtocolError # Compatibility with PyLink 1.x
|
||||||
### Exceptions
|
|
||||||
|
|
||||||
# XXX: is this the right place to put this class?
|
|
||||||
class ProtocolError(RuntimeError):
|
|
||||||
pass
|
|
||||||
|
|
||||||
### Internal classes (users, servers, channels)
|
### Internal classes (users, servers, channels)
|
||||||
|
|
||||||
|
5
utils.py
5
utils.py
@ -33,6 +33,11 @@ class InvalidArgumentsError(TypeError):
|
|||||||
Exception raised (by IRCParser and potentially others) when a bot command is given invalid arguments.
|
Exception raised (by IRCParser and potentially others) when a bot command is given invalid arguments.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
class ProtocolError(RuntimeError):
|
||||||
|
"""
|
||||||
|
Exception raised when a network protocol violation is encountered in some way.
|
||||||
|
"""
|
||||||
|
|
||||||
class IncrementalUIDGenerator():
|
class IncrementalUIDGenerator():
|
||||||
"""
|
"""
|
||||||
Incremental UID Generator module, adapted from InspIRCd source:
|
Incremental UID Generator module, adapted from InspIRCd source:
|
||||||
|
Loading…
Reference in New Issue
Block a user