lua-cjson icon indicating copy to clipboard operation
lua-cjson copied to clipboard

encode and decode invalid Json, throws error

Open flowdopip opened this issue 6 months ago • 7 comments

Hi all,

I just want to understand why encode invalid JSON works well without exception but decode breaks with an error.

My use case is to encode data on Redis for caching an HTTP request, and when another request matches the criteria, the value on Redis, when decoded, throws an error saying that it is not possible to decode. I´m still trying to understand what is the upstream answering with invalid json, but I need now to not store on redis when json is not valid

flowdopip avatar Jul 29 '24 12:07 flowdopip