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

Report which key or value caused the narrow to fail #3

Open
ssangervasi opened this issue Oct 22, 2024 · 1 comment
Open

Report which key or value caused the narrow to fail #3

ssangervasi opened this issue Oct 22, 2024 · 1 comment
Assignees
Labels
enhancement New feature or request

Comments

@ssangervasi
Copy link
Owner

It can be tricky to develop a narrow schema for a large JSON, especially one that has optional keys. It would be helpful if when narrow returns false there was a way to find out which type comparison failed. I'd mainly use this while debugging, but there may be other runtime use cases.

(Example: I've run into this a bunch while parsing RSS feeds)

@ssangervasi ssangervasi added the enhancement New feature or request label Oct 22, 2024
@ssangervasi ssangervasi self-assigned this Oct 22, 2024
@ssangervasi
Copy link
Owner Author

I have a branch where I've tried creating a whole generic traverse & object diff algorithm. A thorough nested diff would be great, but so far the complexity is maybe not worth it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant