fury icon indicating copy to clipboard operation
fury copied to clipboard

[Java] add support so that deserializeJavaObject will throw an exception if the encoded data is of wrong type

Open pjfanning opened this issue 5 months ago • 1 comments

Feature Request

I have an ignored test case in #2378 where Fory returns null instead of failing with an exception. The test case passes with the wrong type in the input params. If we like nulls (and I hate them), can we add a ForyBuilder option to allow users to opt out of ever getting nulls from deserializeJavaObject?

Is your feature request related to a problem? Please describe

No response

Describe the solution you'd like

No response

Describe alternatives you've considered

No response

Additional context

No response

pjfanning avatar Jul 06 '25 18:07 pjfanning

It should throw an exception instead of returning null, we need to fix it.

chaokunyang avatar Jul 07 '25 02:07 chaokunyang