- wsInfo.setStatus(WebserviceInfo.STATE_STOPPED_SERVERERROR);\r
- allowedServerExceptions = 0;\r
- jobComplete = false;\r
-\r
- wsInfo.appendProgressText("Failed to submit the prediction.\n"\r
- +\r
- "It is most likely that there is a problem with the server.\n"\r
- + "Just close the window\n");\r
- System.err.println(\r
- "JPredWS Client: Failed to submit the prediction (Probably a server error - see below)\n" +\r
- e.toString() + "\n");\r
-\r
- jalview.bin.Jalview.log.debug("Failed Submission",e);\r
+ if (e.getMessage().indexOf("Exception")>-1) {\r
+ wsInfo.setStatus(WebserviceInfo.STATE_STOPPED_SERVERERROR);\r
+ wsInfo.setProgressText(\r
+ "Failed to submit the prediction. (Just close the window)\n"\r
+ +\r
+ "It is most likely that there is a problem with the server.\n");\r
+ System.err.println(\r
+ "JPredWS Client: Failed to submit the prediction. Quite possibly because of a server error - see below)\n" +\r
+ e.getMessage() + "\n");\r
+\r
+ jalview.bin.Cache.log.warn("Server Exception",e);\r
+ } else {\r
+ wsInfo.setStatus(WebserviceInfo.STATE_STOPPED_ERROR);\r
+ // JBPNote - this could be a popup informing the user of the problem.\r
+ wsInfo.setProgressText("Failed to submit the prediction:\n"\r
+ +e.getMessage()+\r
+ wsInfo.getProgressText());\r
+\r
+ jalview.bin.Cache.log.debug("Failed Submission",e);\r
+\r
+ }\r
+ allowedServerExceptions = -1;\r
+ jobComplete = true;\r
+\r