Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Commit

Permalink
Expain SynapseError and FederationError better
Browse files Browse the repository at this point in the history
Spawning from #13816 (comment)
  • Loading branch information
MadLittleMods committed Oct 15, 2022
1 parent 616dcc1 commit acea74f
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions synapse/api/errors.py
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,7 @@ def __init__(self, location: bytes, http_code: int = http.FOUND):
class SynapseError(CodeMessageException):
"""A base exception type for matrix errors which have an errcode and error
message (as well as an HTTP status code).
TODO
Attributes:
errcode: Matrix error code e.g 'M_FORBIDDEN'
Expand Down Expand Up @@ -602,6 +603,7 @@ def cs_error(msg: str, code: str = Codes.UNKNOWN, **kwargs: Any) -> "JsonDict":
class FederationError(RuntimeError):
"""This class is used to inform remote homeservers about erroneous
PDUs they sent us.
TODO
FATAL: The remote server could not interpret the source event.
(e.g., it was missing a required field)
Expand Down

0 comments on commit acea74f

Please sign in to comment.