Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP] Error formatter #124

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

[WIP] Error formatter #124

wants to merge 2 commits into from

Conversation

Anviking
Copy link
Owner

@Anviking Anviking commented Sep 19, 2016

The implementation is hideous, but it appears to work.

object: 
 | repo: 
 |  | owner:  <<<<---- MissingKey: oops
 |  |  | id: 1
 |  |  | login: "anviking"

ATM, | characters appear in the parent nodes of the error to make it easier to locate.

This is probably ready when

  • Array error back propagation works (KeyPath needs to support array indexes) (?)
  • Implementation is less less hideous
  • Style of errors has been tweaked

@Anviking
Copy link
Owner Author

Also, out of scope for this but if operators are discarded for global functions decode(json, keys...) tracking function name, filename etc. the possibilities just become so ridiculous that I'm not even sure I want to do it ever. In debug mode each json object could have information about which decode function accessed it, which we could color code and present as a HTML representation. This would also draw attention to json keys not accessed that should be == win.

@Anviking Anviking mentioned this pull request Dec 22, 2017
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.

1 participant