I just found the origin of the problem but not the solution. The problem is there when the category is MotoGP, do you have any idea of the solution?
If the category is Moto2 or Moto3 there is no problem.
com.github.parsad23.motogpapi.exceptions.DataNotAvailableException: The requested session or data does not exist or is not available
at com.github.parsad23.motogpapi.reader.URLGenerator.getSessionResultsURL(URLGenerator.java:80)
at com.github.parsad23.motogpapi.reader.SessionResultsReader.getJSONObjectResults(SessionResultsReader.java:25)
at com.github.parsad23.motogpapi.reader.SessionResultsReader.getSessionResults(SessionResultsReader.java:17)
at com.github.parsad23.motogpapi.reader.MotoGPData.getSessionResults(MotoGPData.java:45)
at testsetstsetmain.main.main(main.java:19)
try{
races = JsonParser.parseString(JsonReader.readJsonFromUrl(url, referer, base_url)).getAsJsonArray();
} catch (IOException e){
throw new DataNotAvailableException("Unable to read the JSONArray containing the races: empty String returned...");
}