Skip to content
Open
Changes from all commits
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
8 changes: 7 additions & 1 deletion firebase_admin/exceptions.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@
Therefore it is always a good idea to have a handler specified for ``FirebaseError``, after all the
subtype error handlers.
"""
from typing import Optional
from requests import Response


#: Error code for ``InvalidArgumentError`` type.
Expand Down Expand Up @@ -95,7 +97,11 @@ class FirebaseError(Exception):
this object.
"""

def __init__(self, code, message, cause=None, http_response=None):
def __init__(self,
code: str,
message: str,
cause: Optional[Exception] = None,
http_response: Optional[Response] = None,):
Exception.__init__(self, message)
self._code = code
self._cause = cause
Expand Down