mirror of
https://github.com/zulip/zulip.git
synced 2026-06-24 21:08:25 +08:00
JsonableError has two major benefits over json_error: * It can be raised from anywhere in the codebase, rather than being a return value, which is much more convenient for refactoring, as one doesn't potentially need to change error handling style when extracting a bit of view code to a function. * It is guaranteed to contain the `code` property, which is helpful for API consistency. Various stragglers are not updated because JsonableError requires subclassing in order to specify custom data or HTTP status codes. |
||
|---|---|---|
| .. | ||
| __init__.py | ||
| cache.py | ||
| camo.py | ||
| dev_login.py | ||
| email_log.py | ||
| integrations.py | ||
| registration.py | ||