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

Redash returns a 500 SERVER error when it can't find a Job. #7149

Open
superwesman opened this issue Sep 10, 2024 · 0 comments
Open

Redash returns a 500 SERVER error when it can't find a Job. #7149

superwesman opened this issue Sep 10, 2024 · 0 comments

Comments

@superwesman
Copy link

Issue Summary

We have observed that Redash returns a 500 error, which according to HTTP spec is a server error whenever a user issues an /api/jobs request for a Job that does not exist. The server logs show a stack trace for a rq.exceptions.NoSuchJobError error and an HTTP 500 is returned to the client.

Steps to Reproduce

  1. Issue an /api/jobs request for a Job that does not exist
  2. Look in the logs and at the HTTP code that Redash sent you and you'll see a stack trace and a 500 error.

This HTTP response is out of line with the intent of the HTTP 5XX class of errors. A more appropriate response would be a 4XX error. The Redash server is handling this request just fine and the "issue", if any, is bad user input. Why not 404? or even 401 if this is in the category of "does not exist or you are not authorized to access it".

Technical details:

  • Redash Version: redash:10.1.0.b50633
  • Browser/OS: N/A
  • How did you install Redash: we use Docker Images derived from your base Images.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant