diff options
author | palaviv <palaviv@gmail.com> | 2016-02-12 11:00:39 +0200 |
---|---|---|
committer | palaviv <palaviv@gmail.com> | 2016-02-12 11:00:39 +0200 |
commit | 7d2d46effce37f9fbf394fac74d380aaa7c95f02 (patch) | |
tree | de896ab281c25da5a17d416a707b5e79c4bab094 /msgpack/exceptions.py | |
parent | 82b31215079bc47bd4d5a8f3c18d83ac73c8221b (diff) | |
download | msgpack-python-7d2d46effce37f9fbf394fac74d380aaa7c95f02.tar.gz |
msgpack pack and unpack throws only exception that inherit from MsgpackBaseException. cython and fallback throws same exceptions
Diffstat (limited to 'msgpack/exceptions.py')
-rw-r--r-- | msgpack/exceptions.py | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/msgpack/exceptions.py b/msgpack/exceptions.py index f7678f1..e0d5b5f 100644 --- a/msgpack/exceptions.py +++ b/msgpack/exceptions.py @@ -1,4 +1,8 @@ -class UnpackException(Exception): +class MsgpackBaseException(Exception): + pass + + +class UnpackException(MsgpackBaseException): pass @@ -22,8 +26,12 @@ class ExtraData(ValueError): def __str__(self): return "unpack(b) received extra data." -class PackException(Exception): +class PackException(MsgpackBaseException): pass class PackValueError(PackException, ValueError): pass + + +class PackOverflowError(PackValueError, OverflowError): + pass |