IBM / JSONata4Java

Open Source Java version of JSONata
Apache License 2.0
88 stars 36 forks source link

Could not deserialize ATN with UUID 59627784-3be5-417a-b9eb-8131a7286089 (expected aadb8d7e-aeef-4415-ad2b-8204d6cf042e or a legacy UUID) #274

Open vish35 opened 11 months ago

vish35 commented 11 months ago

Hi I am using JSONata4Java 1.7.9 version with Antlr-Runtime 4.5. So sometimes I am receiving Could not deserialize ATN with UUID 59627784-3be5-417a-b9eb-8131a7286089 (expected aadb8d7e-aeef-4415-ad2b-8204d6cf042e or a legacy UUID). error and sometimes works fine. What could be issue? What is recommended approach to add Antlr and Antlr-runtime dependencies? Thanks

wnm3 commented 11 months ago

JSONata4Java is build with ANTLR version 4.13.0 as shown in the pom.xml file:

4.13.0 I'm not sure why you would be trying to use a different version of ANTLR.
wnm3 commented 11 months ago

Also, we are at version 2.4.3 of JSONata4Java, perhaps you'd do better to use the current version?

vish35 commented 11 months ago

Actually our system is using JDK 8, and higher version of JSONata4Java uses greater than JDK 8. so I am using 1.7.9 version. In pom.xml file I am seeing it is using Antlr-runtime 4.9.3 version. Now I updated to 4.9.3 but still observing issue

POM file for 1.7.9 version: https://central.sonatype.com/artifact/com.ibm.jsonata4java/JSONata4Java/1.7.9

vish35 commented 11 months ago

do I need to update both Antlr4 and Antlr-runtime package version to 4.9.3?

wnm3 commented 11 months ago

Looking in the target/JSONata4java-2.4.3-jar-with-dependencies.jar it appears you only need the runtime. The other is used for generating code based on the g4 files.

wnm3 commented 11 months ago

cd target jar -tvf JSONata4Java-2.4.3-jar-with-dependencies.jar |grep -i antlr

Of course your version is 1.7.9...