Skip to content

Improve JsonSimple exception messages#885

Merged
nedtwigg merged 1 commit intodiffplug:mainfrom
goughy000:feature/json-format-cause
Jul 6, 2021
Merged

Improve JsonSimple exception messages#885
nedtwigg merged 1 commit intodiffplug:mainfrom
goughy000:feature/json-format-cause

Conversation

@goughy000
Copy link
Copy Markdown
Contributor

Hey, just a small PR to improve some of the exception messages when formatting fails in JsonSimple.

Previously the target exception was silently discarded, so you knew a file couldn't be formatted but was up to you to work out why. We now include the target exception as cause so it can appear in stack trace.

Also tweaked the message for the case where we can't determine if the root of the json tree is an object or array.

@goughy000 goughy000 force-pushed the feature/json-format-cause branch from 0879899 to bb80062 Compare July 6, 2021 17:51
@nedtwigg nedtwigg merged commit 7028493 into diffplug:main Jul 6, 2021
@goughy000 goughy000 deleted the feature/json-format-cause branch July 6, 2021 21:40
@nedtwigg
Copy link
Copy Markdown
Member

nedtwigg commented Jul 6, 2021

Thanks! Published in plugin-gradle 5.14.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants