jsony icon indicating copy to clipboard operation
jsony copied to clipboard

better exception handing

Open salva-imm opened this issue 4 years ago • 2 comments

Hey i wonder if there's way to just throw better exception , with field/type name

example:

type Entry1 = object
  username: string
  password: string

serializing this: "username":true it just tells me : e: Expected " but got t instead. At offset: 17 expected result: Wrong type: username should be string obviously I don't want to check everything manually..

salva-imm avatar Oct 10 '21 12:10 salva-imm

I would like better exception handler. But to produce nicer errors more state needs to be passed around. That will sacrifice speed though, I don't want to sacrifice speed.

treeform avatar Nov 04 '21 16:11 treeform

maybe better exceptions could only be enabled in debug mode?

SolitudeSF avatar Nov 04 '21 17:11 SolitudeSF