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
Handle hashids exception appropriately #5032
Comments
What needs to be specified in *The panel is used for personal use. No commerce |
Was troubleshooting what I think is a unrelated schedule problem and I'm getting what seems to be an error related to this on my installation of the panel running on docker. The panel version is 1.11.5.
|
Please visit the Discord and see the #panel-in-docker channel. This issue is not about the hashid error itself but about the error handling. |
Ah, sorry for the confusion. |
@Shandeika |
I set these variables and it started working! Thanks for the help! |
Current Behavior
When making a request to an endpoint that involves some sort of hashing (namely with the
/api/client/servers/<id>/databases?include=password
endpoint) an exception is thrown if theHASHIDS_SALT
orHASHIDS_LENGTH
environment variables are not set, thus returning a 500 internal server error response. The logs for this are also ambiguous which does not help non-experienced users with debugging the issue.Expected Behavior
While this effectively comes down to a user configuration issue, such exceptions should still be handled by the panel appropriately. Given that this is a server issue, 5xx responses would probably be best suited, but it doesn't really fit into one specific status code. Status code 424 could potentially work here but it's unclear if this exception fits under this status; resources I've found thus far mostly point to a failed
PROPPATCH
command being an example use case for the status code. Worst case scenario the panel returns 500 with a detailed error message instead of the current one.Steps to Reproduce
HASHIDS_SALT
orHASHIDS_LENGTH
environment variablesGET /api/client/servers/<id>/databases?include=password
Panel Version
>= 1.11.4
Wings Version
N/A
Games and/or Eggs Affected
N/A
Docker Image
N/A
Error Logs
Is there an existing issue for this?
The text was updated successfully, but these errors were encountered: