amosproj / amos2021ws01-geo-data-search

Natural language and buzzword search on routing and places
MIT License
3 stars 1 forks source link

Exception is raised if no result was found #249

Closed oliviadargel closed 2 years ago

oliviadargel commented 2 years ago

Bug Description

Trace:

ERROR org.apache.catalina.core.ContainerBase.[Tomcat].[localhost].[/].[dispatcherServlet] - Servlet.service() for servlet [dispatcherServlet] in context with path [] threw exception [Request processing failed; nested exception is java.lang.NumberFormatException: For input string: "----------"] with root cause
java.lang.NumberFormatException: For input string: "----------"
at java.lang.NumberFormatException.forInputString(NumberFormatException.java:67) ~[?:?]
at java.lang.Integer.parseInt(Integer.java:668) ~[?:?]
at java.lang.Integer.parseInt(Integer.java:786) ~[?:?]
at com.example.backend.data.api.NodeInfo.getId(NodeInfo.java:62) ~[classes/:0.0.1-SNAPSHOT]
at com.example.backend.data.http.ResultResponse.toStringWithoutPolyline(ResultResponse.java:59) ~[classes/:0.0.1-SNAPSHOT]
at com.example.backend.controllers.FrontendController.handleQueryRequest(FrontendController.java:69) ~[classes/:0.0.1-SNAPSHOT]
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?]
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77) ~[?:?]
at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]

Acceptance Criteria

Definition of done