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

APIHandler.write_error should set reason field in JSON error response. #2957

Closed
kevin-bates opened this issue Oct 19, 2017 · 0 comments · Fixed by #2958
Closed

APIHandler.write_error should set reason field in JSON error response. #2957

kevin-bates opened this issue Oct 19, 2017 · 0 comments · Fixed by #2958

Comments

@kevin-bates
Copy link
Member

When the @json_errors decorator was removed, to be replaced with APIHandler.write_error (see #2853), the establishment of the reason field was not preserved. Since @json_errors set that field and some notebook clients depend on its presence, it should be set in the compatible replacement.

Please see Issue #2942 for the meandering details of how this conclusion came about.

kevin-bates added a commit to kevin-bates/notebook that referenced this issue Oct 19, 2017
During the deprecation/removal of the `@json_errors` decorator, the
`reason` field was not carried forward into the compatible replacement
method `APIHandler.write_error`.  This broke some client (tests) that
relied on that field's presence.

Fixes jupyter#2957.
@minrk minrk added this to the Reference milestone Sep 13, 2018
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 8, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants