question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

GlobalIdTypeAdapter parseValueObjectId NPE

See original GitHub issue

Error reproduced when Entities have multiple nesting levels of child Entities

java.lang.NullPointerException
	at org.javers.core.json.typeadapter.commit.GlobalIdTypeAdapter.parseValueObjectId(GlobalIdTypeAdapter.java:54)
	at org.javers.core.json.typeadapter.commit.GlobalIdTypeAdapter.fromJson(GlobalIdTypeAdapter.java:42)
	at org.javers.core.json.typeadapter.commit.GlobalIdTypeAdapter.fromJson(GlobalIdTypeAdapter.java:19)
	at org.javers.core.json.JsonConverterBuilder.lambda$registerJsonTypeAdapterForType$4(JsonConverterBuilder.java:162)
	at com.google.gson.internal.bind.TreeTypeAdapter.read(TreeTypeAdapter.java:69)
	at com.google.gson.internal.bind.TypeAdapterRuntimeTypeWrapper.read(TypeAdapterRuntimeTypeWrapper.java:41)
	at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:82)
	at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:61)
	at com.google.gson.Gson.fromJson(Gson.java:932)
	at com.google.gson.Gson.fromJson(Gson.java:1003)
	at com.google.gson.internal.bind.TreeTypeAdapter$GsonContextImpl.deserialize(TreeTypeAdapter.java:162)
	at org.javers.core.json.typeadapter.commit.CdoSnapshotStateDeserializer.decodePropertyValue(CdoSnapshotStateDeserializer.java:76)
	at org.javers.core.json.typeadapter.commit.CdoSnapshotStateDeserializer.lambda$deserialize$0(CdoSnapshotStateDeserializer.java:44)

https://github.com/alabotski/javers/pull/1

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:8 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
bartoszwalacikcommented, Jan 30, 2022

Fixed in 6.6.2, @alabotski thanks for reporting

1reaction
bartoszwalacikcommented, Jan 28, 2022

sorry, must be a mistake, your report is legit now, I will take a look

Read more comments on GitHub >

github_iconTop Results From Across the Web

Release notes — JaVers Documentation
1180 Fixed NPE in GlobalIdTypeAdapter.parseValueObjectId() . 6.6.1. released on 2022-01-26. 1177 Added possibility to register JaversBuilderPlugin s ...
Read more >
GlobalIdTypeAdapter.java example - Javatips.net
This class describes the usage of GlobalIdTypeAdapter.java. ... private ValueObjectId parseValueObjectId(JsonObject jsonObject, JsonDeserializationContext ...
Read more >
NullPointerException in GlobalIdTypeAdapter #141 - GitHub
I am getting a NullPointerException in my current scenario: java.lang.NullPointerException: null at org.javers.core.json.typeadapter.commit.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found