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

Commit

Permalink
feat: Add more details about API compatibility (#38)
Browse files Browse the repository at this point in the history
* Add more details about API compability

* Linting

---------

Co-authored-by: leoporoli <[email protected]>
  • Loading branch information
laurentluce and leoporoli authored Sep 20, 2024
1 parent 1c7d8e2 commit 1220d31
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions kontrol-service/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,8 +103,10 @@ func startServer(isDevMode bool) {
defer func() {
if r := recover(); r != nil {

msg := "The server could not handle this request. Please make sure you are using the latest Kardinal API. For the CLI, it means using the latest CLI release. You can open an issue against the Kardinal repo if you continue to get this error at https://github.com/kurtosis-tech/kardinal/issues/new"
internalServerErrorResponse := cli_api.ErrorJSONResponse{
Error: "internal server error",
Error: "Internal Server Error",
Msg: &msg,
}

// Handle the panic and return a 500 error response
Expand All @@ -118,7 +120,7 @@ func startServer(isDevMode bool) {
default:
debugMsg = "recover didn't get error msg"
}
logrus.Errorf("HTTP server handle this internal panic: %s", debugMsg)
logrus.Errorf("HTTP server handled this internal panic: %s", debugMsg)
}
}()
return next(c)
Expand Down

0 comments on commit 1220d31

Please sign in to comment.