2024-06-14T08:16:16.494-04:00 java.lang.IllegalArgumentException: NaN is not a valid double value as per JSON specification. To override this behavior, use GsonBuilder.serializeSpecialFloatingPointValues() method.
2024-06-14T08:16:16.494-04:00 at com.google.gson.Gson.checkValidFloatingPoint(Gson.java:402)
...
2024-06-14T08:16:16.494-04:00 at com.google.gson.Gson.toJson(Gson.java:661)
2024-06-14T08:16:16.494-04:00 at io.dockstore.webservice.languages.CWLHandler.parseWithClass(CWLHandler.java:557)
2024-06-14T08:16:16.494-04:00 at io.dockstore.webservice.languages.CWLHandler.parseWorkflow(CWLHandler.java:566)
2024-06-14T08:16:16.494-04:00 at io.dockstore.webservice.languages.CWLHandler.getContent(CWLHandler.java:448)
2024-06-14T08:16:16.494-04:00 at io.dockstore.webservice.resources.WorkflowResource.getTableToolContent(WorkflowResource.java:1523)
Describe the bug During community lead, there were 500 errors in the logs when retrieving the tools JSON table for this CWL workflow https://dockstore.org/workflows/github.com/EiffL/TXPipe:master?tab=info.
The stack trace:
The primary descriptor does indeed have
NaN
values such as this line https://github.com/EiffL/TXPipe/blob/188559a2c810f6f720e27a22d33a5de7530c1faa/pipeline.cwl#L37 which causes the parsing to fail on thetoJson
call on this line https://github.com/dockstore/dockstore/blob/cb80d1884d1fec9452045025a555c761534649bf/dockstore-webservice/src/main/java/io/dockstore/webservice/languages/CWLHandler.java#L557To Reproduce Steps to reproduce the behavior:
Expected behavior It shouldn't fail with a 500
Additional context [Domain] - https://dockstore.org
Webservice - 1.15.2
UI - 2.12.2
Deploy - 1.15.0
┆Issue is synchronized with this Jira Story ┆Issue Number: DOCK-2534 ┆Sprint: Backlog ┆Issue Type: Story