PHI-base / PHI5_web_display

PHI5_web_display will allow to display PHI-Canto data
1 stars 0 forks source link

Internal server error when Advanced Search returns no results #122

Open jseager7 opened 3 months ago

jseager7 commented 3 months ago

When the Advanced Search returns zero results for a search query, the search results are not updated on the page and an error is shown in the web console:

{
    "headers": {
        "normalizedNames": {},
        "lazyUpdate": null
    },
    "status": 500,
    "statusText": "OK",
    "url": "https://phi5.phi-base.org/api/search?start=0&offset=10",
    "ok": false,
    "name": "HttpErrorResponse",
    "message": "Http failure response for https://phi5.phi-base.org/api/search?start=0&offset=10: 500 OK",
    "error": {
        "timestamp": 1714656790499,
        "status": 500,
        "error": "Internal Server Error",
        "exception": "java.lang.IllegalArgumentException",
        "message": "[size] must be greater than 0. Found [0] in [PHIG_ID]",
        "path": "/api/search"
    }
}

I can trigger this error with the following search criteria: