Skip to content

return value of "java.util.List.get(int)" is nullNetwork error (500)! #593

Open
@afconlab

Description

I can't add a stop to a shape on trip pattern.
I have the error below

**INFO  2024-05-02T18:17:08.164 [qtp290910207-22] c.c.gtfs.loader.JdbcTableWriter(JdbcTableWriter.java:741) Deleted 0 pattern_stops
ERROR 2024-05-02T18:17:08.167 [qtp290910207-22] c.c.gtfs.loader.JdbcTableWriter(JdbcTableWriter.java:248) Error updating patterns entity
java.lang.NullPointerException: Cannot invoke "com.fasterxml.jackson.databind.JsonNode.isNull()" because the return value of "java.util.List.get(int)" is null
	at com.conveyal.gtfs.loader.JdbcTableWriter.updateLinkedFields(JdbcTableWriter.java:344)
	at com.conveyal.gtfs.loader.JdbcTableWriter.updateChildTable(JdbcTableWriter.java:635)
	at com.conveyal.gtfs.loader.JdbcTableWriter.update(JdbcTableWriter.java:194)
	at com.conveyal.datatools.editor.controllers.api.EditorController.update(EditorController.java:499)
	at com.conveyal.datatools.editor.controllers.api.EditorController.createOrUpdate(EditorController.java:479)
	at spark.ResponseTransformerRouteImpl$1.handle(ResponseTransformerRouteImpl.java:47)
	at spark.http.matching.Routes.execute(Routes.java:61)
	at spark.http.matching.MatcherFilter.doFilter(MatcherFilter.java:134)
	at spark.embeddedserver.jetty.JettyHandler.doHandle(JettyHandler.java:50)
	at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1598)
	at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)
	at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127)
	at org.eclipse.jetty.server.Server.handle(Server.java:516)
	at org.eclipse.jetty.server.HttpChannel.lambda$handle$1(HttpChannel.java:487)
	at org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:732)
	at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:479)
	at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:277)
	at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311)
	at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:105)
	at org.eclipse.jetty.io.ChannelEndPoint$1.run(ChannelEndPoint.java:104)
	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:338)
	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:315)
	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:173)
	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:131)
	at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:409)
	at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:883)
	at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:1034)
	at java.base/java.lang.Thread.run(Thread.java:840)
java.lang.NullPointerException: Cannot invoke "com.fasterxml.jackson.databind.JsonNode.isNull()" because the return value of "java.util.List.get(int)" is null
	at com.conveyal.gtfs.loader.JdbcTableWriter.updateLinkedFields(JdbcTableWriter.java:344)
	at com.conveyal.gtfs.loader.JdbcTableWriter.updateChildTable(JdbcTableWriter.java:635)
	at com.conveyal.gtfs.loader.JdbcTableWriter.update(JdbcTableWriter.java:194)
	at com.conveyal.datatools.editor.controllers.api.EditorController.update(EditorController.java:499)
	at com.conveyal.datatools.editor.controllers.api.EditorController.createOrUpdate(EditorController.java:479)
	at spark.ResponseTransformerRouteImpl$1.handle(ResponseTransformerRouteImpl.java:47)
	at spark.http.matching.Routes.execute(Routes.java:61)
	at spark.http.matching.MatcherFilter.doFilter(MatcherFilter.java:134)
	at spark.embeddedserver.jetty.JettyHandler.doHandle(JettyHandler.java:50)
	at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1598)
	at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)
	at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127)
	at org.eclipse.jetty.server.Server.handle(Server.java:516)
	at org.eclipse.jetty.server.HttpChannel.lambda$handle$1(HttpChannel.java:487)
	at org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:732)
	at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:479)
	at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:277)
	at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311)
	at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:105)
	at org.eclipse.jetty.io.ChannelEndPoint$1.run(ChannelEndPoint.java:104)
	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:338)
	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:315)
	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:173)
	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:131)
	at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:409)
	at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:883)
	at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:1034)
	at java.base/java.lang.Thread.run(Thread.java:840)
INFO  2024-05-02T18:17:08.174 [qtp290910207-22] c.c.d.common.utils.SparkUtils(SparkUtils.java:136) Halting with status code 500.  Error message: An error was encountered while trying to save to the database
ERROR 2024-05-02T18:17:08.174 [qtp290910207-22] c.c.d.common.utils.SparkUtils(SparkUtils.java:139) An error was encountered while trying to save to the database
WARN  2024-05-02T18:17:08.175 [qtp290910207-22] c.c.d.manager.utils.ErrorUtils(ErrorUtils.java:64) Bugsnag not configured to report errors!
INFO  2024-05-02T18:17:08.175 [qtp290910207-22] c.c.d.common.utils.SparkUtils(SparkUtils.java:243) res (500) xyz@xyz.com PUT: http://localhost:9966/api/editor/secure/pattern/1?feedId=08eb4bf1-524b-4776-99ef-ffa8ff5e1dc8&sessionId=node08kkegaxs89321q9513kv1w83e1 
{
  "result" : "ERR",
  "message" : "An error was encountered while trying to save to the database",
  "code" : 500,
  "detail" : "Cannot invoke \"com.fasterxml.jackson.databind.JsonNode.isNull()\" because the return value of \"java.util.List.get(int)\" is null"
}
INFO  2024-05-02T18:17:08.175 [qtp290910207-22] c.c.d.e.c.api.EditorController(EditorController.java:489) Update operation took 49 msec**

**

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions