Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

all exceptions inherit from PyJwtError #340

Merged
merged 3 commits into from
Mar 29, 2018
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions jwt/exceptions.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,11 @@
class InvalidTokenError(Exception):
class PyJwtError(Exception):
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Small nitpick, can we rename this to PyJWTError? Also, we'll need to expose this in pyjwt/__init__.py.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

for you? of course

"""
Base class for all exceptions
"""
pass


class InvalidTokenError(PyJwtError):
pass


Expand Down Expand Up @@ -30,7 +37,7 @@ class ImmatureSignatureError(InvalidTokenError):
pass


class InvalidKeyError(Exception):
class InvalidKeyError(PyJwtError):
pass


Expand Down