You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
First of all thanks for this plugin, it seems to be really helpful!
Sadly I have some problems to get it working in my project, I always get the following error message: org.jeasy.random.ObjectCreationException: Unable to create a random instance of type class com.igdb.proto.Igdb$InvolvedCompany
I uploaded a small sample project to reproduce this error here: https://github.com/grimsi/easyrandom-protobuf-test
Simply running a mvn clean install will result in a Stack-Overflow and "Unable to create a random instance of type class XXX".
I am using the official protobuf file from IGDB and it works fine in my project: https://api.igdb.com/v4/igdbapi.proto
I am using the protoc-jar-maven-plugin to compile the .proto file to Java classes.
My project is using Java 18 (maybe that's an issue?).
If you need any further assistance just tell me and I will give my best to support you.
The text was updated successfully, but these errors were encountered:
@grimsi : sorry for the (very) late answer. Could you try with the 1.0.0 snapshot version?
I've done a internal rewrite with #170 that might resolve your issue.
murdos
changed the title
[Bug] "StackOverflowError" and "Unable to create a random instance of type class <Compiled Protobuf Class>"
"StackOverflowError" and "Unable to create a random instance of type class <Compiled Protobuf Class>"
Jul 23, 2023
With easy-random-protobuf 1.0.0-SNAPTHOT and easy-random-core 6.0.0-SNAPSHOT I get the same error as before (StackOverflow).
With easy-random-protobuf 1.0.0-SNAPSHOT and easy-random-core 5.0.0 I get the following error: Cannot invoke "org.jeasy.random.api.RandomizerProvider.getRandomizerByType(java.lang.Class, org.jeasy.random.api.RandomizerContext)" because the return value of "org.jeasy.random.EasyRandomParameters.getRandomizerProvider()" is null
Thanks. I've been able to reproduce the issue and created a minimal test case that illustrates the infinite recursion issue.
See #177.
However the fix it still doesn't work on your test case although it now behaves differently (the object generation never ends...)
To be continued...
First of all thanks for this plugin, it seems to be really helpful!
Sadly I have some problems to get it working in my project, I always get the following error message:
org.jeasy.random.ObjectCreationException: Unable to create a random instance of type class com.igdb.proto.Igdb$InvolvedCompany
I uploaded a small sample project to reproduce this error here: https://github.com/grimsi/easyrandom-protobuf-test
Simply running a
mvn clean install
will result in a Stack-Overflow and "Unable to create a random instance of type class XXX".I am using the official protobuf file from IGDB and it works fine in my project: https://api.igdb.com/v4/igdbapi.proto
I am using the
protoc-jar-maven-plugin
to compile the .proto file to Java classes.My project is using Java 18 (maybe that's an issue?).
If you need any further assistance just tell me and I will give my best to support you.
The text was updated successfully, but these errors were encountered: